Libvirt patches for launching VMs with 'ppc64le' architecture.

Bug #1396070 reported by bugproxy
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
libvirt (Ubuntu)
Fix Released
High
Unassigned

Bug Description

Problem Description
=======================
Patches needed to enable LE architecture support for libvirt

---uname output---
3.16

Machine Type = POWER8

Steps to Reproduce
============================
 This lists the patches needed to enable libvirt to launch VMs with 'ppc64le' architecture on Ubuntu 14.10.

Userspace tool common name: libvirt
The userspace tool has the following bit modes: 64 bit
Userspace rpm: libvirt

== Comment: #1 - PRERNA SAXENA <email address hidden> - ==
UPSTREAM:
-----------------
commit 3bc6dda6c55ed2ebc8604b9dc0410639eaede8cb
Author: Cole Robinson <email address hidden>
Date: Tue Sep 23 11:35:57 2014 -0400

    qemu_command: Split qemuBuildCpuArgStr

    Move the CPU mode/model handling to its own function. This is just
    code movement and re-indentation.

== Comment: #2 - PRERNA SAXENA <email address hidden> - ==
UPSTREAM:
----------------
commit 445a09bdc96ca6e434bfdcca75752ee316289bbe
Author: Cole Robinson <email address hidden>
Date: Tue Sep 23 13:07:09 2014 -0400

    qemu: Don't compare CPU against host for TCG

    Right now when building the qemu command line, we try to do various
    unconditional validations of the guest CPU against the host CPU. However
    this checks are overly applied. The only time we should use the checks
    are:

== Comment: #3 - PRERNA SAXENA <email address hidden> - ==
UPSTREAM:
-----------------
commit da636d83dc6b1d070a705786b4daef8644eaca13
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 22:51:26 2014 +0530

    Cpu: Add support for Power LE Architecture.

    This adds support for PowerPC Little Endian architecture.,
    and allows libvirt to spawn VMs based on 'ppc64le' architecture.

== Comment: #4 - PRERNA SAXENA <email address hidden> - ==
UPSTREAM:
commit addce06c9221f948072cd222b56ea9c3f70ec066
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 22:52:44 2014 +0530

    PowerPC : Add support for launching VM in 'compat' mode.

    PowerISA allows processors to run VMs in binary compatibility ("compat")
    mode supporting an older version of ISA. QEMU has recently added support to
    explicitly denote a VM running in compatibility mode through commit 6d9412ea
    & 8dfa3a5e85. Now, a "compat" mode VM can be run by invoking this qemu
    commandline on a POWER8 host: -cpu host,compat=power7.

== Comment: #5 - PRERNA SAXENA <email address hidden> - ==
UPSTREAM:
----------------

commit 1e911742287d964055f33ab76d53e673a9b4477f
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 22:58:33 2014 +0530

    PowerPC:Improve PVR handling to fall back to cpu generation.

    IBM Power processors differ uniquely across generations (such as power6,
    power7, power8). Each generation signifies a new PowerISA version
    that exhibits features unique to that generation.
    The higher 16 bits of PVR for IBM Power processors encode the CPU
    generation, while the CPU chip (sub)version is encoded in lower 16 bits.

== Comment: #6 - PRERNA SAXENA <email address hidden> - ==
UPSTREAM:

commit 9265fd19b68d787e478f5e490524da794965a5f1
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 23:00:36 2014 +0530

    docs: Add documentation for compat mode.

    Add documentation to explain how compat-mode can be invoked with libvirt
    running on PowerPC architecture.
    It also mentions that this change is available libvirt 1.2.11 onwards.

    Signed-off-by: Prerna Saxena <email address hidden>
    Reviewed-by: Michal Privoznik <email address hidden>

== Comment: #7 - PRERNA SAXENA <email address hidden> - ==
UPSTREAM:

commit 12c381114ce362e49cadb730b5faabbc150a8878
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 23:02:15 2014 +0530

    Test: Add a testcase for PowerPC compat mode cpu specification.

    This introduces a testcase for PowerPC compat mode cpu specification.

    Signed-off-by: Prerna Saxena <email address hidden>
    Reviewed-by: Michal Privoznik <email address hidden>

== Comment: #8 - PRERNA SAXENA <email address hidden> - ==
These patches have been tested -- they build fine against the libvirt 1.2.8 sources that are packaged with Ubuntu 14.10.
I have included a reference to the upstream commit in each case.

Revision history for this message
bugproxy (bugproxy) wrote : 0001-qemu_command-Split-qemuBuildCpuArgStr.patch

Default Comment by Bridge

tags: added: architecture-ppc64le bugnameltc-119156 severity-medium targetmilestone-inin1410
Revision history for this message
bugproxy (bugproxy) wrote : 0002-qemu-Don-t-compare-CPU-against-host-for-TCG.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0003-Cpu-Add-support-for-Power-LE-Architecture.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0004-PowerPC-Add-support-for-launching-VM-in-compat-mode.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0005-PowerPC-Improve-PVR-handling-to-fall-back-to-cpu-gen.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0006-docs-Add-documentation-for-compat-mode.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0007-Test-Add-a-testcase-for-PowerPC-compat-mode-cpu-spec.patch

Default Comment by Bridge

Revision history for this message
Ubuntu Foundations Team Bug Bot (crichton) wrote :

Thank you for taking the time to report this bug and helping to make Ubuntu better. It seems that your bug report is not filed about a specific source package though, rather it is just filed against Ubuntu in general. It is important that bug reports be filed about source packages so that people interested in the package can find the bugs about it. You can find some hints about determining what package your bug might be about at https://wiki.ubuntu.com/Bugs/FindRightPackage. You might also ask for help in the #ubuntu-bugs irc channel on Freenode.

To change the source package that this bug is filed about visit https://bugs.launchpad.net/ubuntu/+bug/1396070/+editstatus and add the package name in the text box next to the word Package.

[This is an automated message. I apologize if it reached you inappropriately; please just reply to this message indicating so.]

tags: added: bot-comment
affects: ubuntu → libvirt (Ubuntu)
Changed in libvirt (Ubuntu):
status: New → Confirmed
importance: Undecided → High
Stefan Bader (smb)
Changed in libvirt (Ubuntu):
assignee: nobody → Stefan Bader (smb)
Revision history for this message
Stefan Bader (smb) wrote :

Now too late but I had noticed that the provided patch #3 missed two changes from the upstream patch. Not sure how important those would be:

diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index 1b8efb1..21309b0 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -10043,7 +10043,7 @@ virDomainVideoDefaultType(const virDomainDef *def)
             (STREQ(def->os.type, "xen") ||
              STREQ(def->os.type, "linux")))
             return VIR_DOMAIN_VIDEO_TYPE_XEN;
- else if (def->os.arch == VIR_ARCH_PPC64)
+ else if ARCH_IS_PPC64(def->os.arch)
             return VIR_DOMAIN_VIDEO_TYPE_VGA;
         else
             return VIR_DOMAIN_VIDEO_TYPE_CIRRUS;
diff --git a/src/cpu/cpu_powerpc.c b/src/cpu/cpu_powerpc.c
index 67cb9ff..d591c18 100644
--- a/src/cpu/cpu_powerpc.c
+++ b/src/cpu/cpu_powerpc.c
@@ -38,7 +38,7 @@

 VIR_LOG_INIT("cpu.cpu_powerpc");

-static const virArch archs[] = { VIR_ARCH_PPC64 };
+static const virArch archs[] = { VIR_ARCH_PPC64, VIR_ARCH_PPC64LE };

 struct ppc_vendor {
     char *name;

Changed in libvirt (Ubuntu):
assignee: Stefan Bader (smb) → nobody
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package libvirt - 1.2.8-0ubuntu16

---------------
libvirt (1.2.8-0ubuntu16) vivid; urgency=medium

  * debian/patches/add-ppc64le-support.patch: Added patches needed
    for ppc64le support. (LP: #1396070)
 -- Chuck Short <email address hidden> Thu, 27 Nov 2014 08:57:35 -0500

Changed in libvirt (Ubuntu):
status: Confirmed → Fix Released
Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2014-11-28 05:29 EDT-------
(In reply to comment #14)
> Now too late but I had noticed that the provided patch #3 missed two changes
> from the upstream patch. Not sure how important those would be:
>
> diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
> index 1b8efb1..21309b0 100644
> --- a/src/conf/domain_conf.c
> +++ b/src/conf/domain_conf.c
> @@ -10043,7 +10043,7 @@ virDomainVideoDefaultType(const virDomainDef *def)
> (STREQ(def->os.type, "xen") ||
> STREQ(def->os.type, "linux")))
> return VIR_DOMAIN_VIDEO_TYPE_XEN;
> - else if (def->os.arch == VIR_ARCH_PPC64)
> + else if ARCH_IS_PPC64(def->os.arch)
> return VIR_DOMAIN_VIDEO_TYPE_VGA;
> else
> return VIR_DOMAIN_VIDEO_TYPE_CIRRUS;
> diff --git a/src/cpu/cpu_powerpc.c b/src/cpu/cpu_powerpc.c
> index 67cb9ff..d591c18 100644
> --- a/src/cpu/cpu_powerpc.c
> +++ b/src/cpu/cpu_powerpc.c
> @@ -38,7 +38,7 @@
>
> VIR_LOG_INIT("cpu.cpu_powerpc");
>
> -static const virArch archs[] = { VIR_ARCH_PPC64 };
> +static const virArch archs[] = { VIR_ARCH_PPC64, VIR_ARCH_PPC64LE };
>
> struct ppc_vendor {
> char *name;
>
> This bug was fixed in the package libvirt - 1.2.8-0ubuntu16
>
> ---------------
> libvirt (1.2.8-0ubuntu16) vivid; urgency=medium
>
> * debian/patches/add-ppc64le-support.patch: Added patches needed
> for ppc64le support. (LP: #1396070)
> -- Chuck Short <email address hidden> Thu, 27 Nov 2014 08:57:35 -0500

Yes, these are needed. Wonder how this didnt get flagged in the build test.
In fact the upstream tree 1.2.10+ has these patches in. Is there a chance the upcoming 1.2.11 release could be packaged for Ubuntu ?

Revision history for this message
bugproxy (bugproxy) wrote : Patch needed to apply next patch (CPU LE arch support) correctly

------- Comment on attachment From <email address hidden> 2014-11-28 10:06 EDT-------

Needed for cleanly applying patch '003B', which I will upload next.

This is upstream commit :
commit 44e30277d847f1d2e28531b0020f6a5ad8835542
Author: Eric Blake <email address hidden>
Date: Wed Sep 3 13:32:36 2014 -0600

    maint: use consistent if-else braces in qemu

    I'm about to add a syntax check that enforces our documented
    HACKING style of always using matching {} on if-else statements.

    This commit focuses on the qemu driver.

    * src/qemu/qemu_command.c (qemuParseISCSIString)
    (qemuParseCommandLineDisk, qemuParseCommandLine)
    (qemuBuildSmpArgStr, qemuBuildCommandLine)
    (qemuParseCommandLineDisk, qemuParseCommandLineSmp): Correct use
    of {}.
    * src/qemu/qemu_capabilities.c (virQEMUCapsProbeCPUModels):
    Likewise.
    * src/qemu/qemu_driver.c (qemuDomainCoreDumpWithFormat)
    (qemuDomainRestoreFlags, qemuDomainGetInfo)
    (qemuDomainMergeBlkioDevice): Likewise.
    * src/qemu/qemu_hotplug.c (qemuDomainAttachNetDevice): Likewise.
    * src/qemu/qemu_monitor_text.c (qemuMonitorTextCreateSnapshot)

Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2014-11-28 10:16 EDT-------
I have obsoleted the previous patch for adding LE arch support to libvirt CPU driver ("0003-Cpu-Add-support-for-Power-LE-Architecture.patch")

In its place, I have uploaded a fresh version of the patch that includes all changes from upstream.
I have also added another trivial upstream patch that is required for my updated patch to apply.

The series file for libvirt patches now looks like this:

0001-qemu_command-Split-qemuBuildCpuArgStr.patch
0002-qemu-Don-t-compare-CPU-against-host-for-TCG.patch
0003-maint-use-consistent-if-else-braces-in-qemu.patch [Newly added, for 0004 to apply cleanly]
0004-CPU-Add-support-for-Power-LE-Architecture.patch [Updated patch for LE support]
0005-PowerPC-Add-support-for-launching-VM-in-compat-mode.patch
0006-PowerPC-Improve-PVR-handling-to-fall-back-to-cpu-gen.patch
0007-docs-Add-documentation-for-compat-mode.patch
0008-Test-Add-a-testcase-for-PowerPC-compat-mode-cpu-spec.patch

All other patches are unchanged.

Revision history for this message
bugproxy (bugproxy) wrote : Updated patch for Adding LE architecture support to CPU

------- Comment on attachment From <email address hidden> 2014-11-28 10:12 EDT-------

(NOTE: This patch needs to be applied after " maint: use consistent if-else braces in qemu " )

This is updated patch for adding PPC64LE arch support to libvirt CPU driver.
This obsoletes "0003-Cpu-Add-support-for-Power-LE-Architecture.patch"

Upstream commit :
commit da636d83dc6b1d070a705786b4daef8644eaca13
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 22:51:26 2014 +0530

    Cpu: Add support for Power LE Architecture.

    This adds support for PowerPC Little Endian architecture.,
    and allows libvirt to spawn VMs based on 'ppc64le' architecture.

    Signed-off-by: Pradipta Kr. Banerjee <email address hidden>
    Signed-off-by: Prerna Saxena <email address hidden>
    Reviewed-by: Michal Privoznik <email address hidden>

Revision history for this message
Serge Hallyn (serge-hallyn) wrote : Re: [Bug 1396070] Re: Libvirt patches for launching VMs with 'ppc64le' architecture.

Hm, seems like tha tmight make this not work on ppc64le. Could someone
with the hardware please test and confirm?

Quoting Stefan Bader (<email address hidden>):
> Now too late but I had noticed that the provided patch #3 missed two
> changes from the upstream patch. Not sure how important those would be:
>
> diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
> index 1b8efb1..21309b0 100644
> --- a/src/conf/domain_conf.c
> +++ b/src/conf/domain_conf.c
> @@ -10043,7 +10043,7 @@ virDomainVideoDefaultType(const virDomainDef *def)
> (STREQ(def->os.type, "xen") ||
> STREQ(def->os.type, "linux")))
> return VIR_DOMAIN_VIDEO_TYPE_XEN;
> - else if (def->os.arch == VIR_ARCH_PPC64)
> + else if ARCH_IS_PPC64(def->os.arch)
> return VIR_DOMAIN_VIDEO_TYPE_VGA;
> else
> return VIR_DOMAIN_VIDEO_TYPE_CIRRUS;
> diff --git a/src/cpu/cpu_powerpc.c b/src/cpu/cpu_powerpc.c
> index 67cb9ff..d591c18 100644
> --- a/src/cpu/cpu_powerpc.c
> +++ b/src/cpu/cpu_powerpc.c
> @@ -38,7 +38,7 @@
>
> VIR_LOG_INIT("cpu.cpu_powerpc");
>
> -static const virArch archs[] = { VIR_ARCH_PPC64 };
> +static const virArch archs[] = { VIR_ARCH_PPC64, VIR_ARCH_PPC64LE };
>
> struct ppc_vendor {
> char *name;

bugproxy (bugproxy)
tags: added: targetmilestone-inin1504
removed: targetmilestone-inin1410
Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2015-02-08 11:54 EDT-------
(In reply to comment #24)
> Hm, seems like that might make this not work on ppc64le. Could someone
> with the hardware please test and confirm?
>
> Quoting Stefan Bader (<email address hidden>):
> > Now too late but I had noticed that the provided patch #3 missed two
> > changes from the upstream patch. Not sure how important those would be:
> >
> > diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
> > index 1b8efb1..21309b0 100644
> > --- a/src/conf/domain_conf.c
> > +++ b/src/conf/domain_conf.c
> > @@ -10043,7 +10043,7 @@ virDomainVideoDefaultType(const virDomainDef *def)
> > (STREQ(def->os.type, "xen") ||
> > STREQ(def->os.type, "linux")))
> > return VIR_DOMAIN_VIDEO_TYPE_XEN;
> > - else if (def->os.arch == VIR_ARCH_PPC64)
> > + else if ARCH_IS_PPC64(def->os.arch)
> > return VIR_DOMAIN_VIDEO_TYPE_VGA;
> > else
> > return VIR_DOMAIN_VIDEO_TYPE_CIRRUS;
> > diff --git a/src/cpu/cpu_powerpc.c b/src/cpu/cpu_powerpc.c
> > index 67cb9ff..d591c18 100644
> > --- a/src/cpu/cpu_powerpc.c
> > +++ b/src/cpu/cpu_powerpc.c
> > @@ -38,7 +38,7 @@
> >
> > VIR_LOG_INIT("cpu.cpu_powerpc");
> >
> > -static const virArch archs[] = { VIR_ARCH_PPC64 };
> > +static const virArch archs[] = { VIR_ARCH_PPC64, VIR_ARCH_PPC64LE };
> >
> > struct ppc_vendor {
> > char *name;

Yes, these two changes are indeed essential. I verified that:
1) These have not been included in the libvirt package shipped with ubuntu 15.04.
2) These are essential to launching guest VMs on ppc64 little endian arch.

In fact, I had uploaded a modified patch too at the time, but it seems that got missed.
Can these changes be included now ?

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

It looks to me like tha tis in fact present in 1.2.12. Could you please look at 1.2.12-0ubuntu2 and let us know whichi if any patches are still missing?

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

Ping - can you please confirm that the patches are missing, and, if so, point to the exact patches still needed?

Revision history for this message
bugproxy (bugproxy) wrote : 0001-qemu_command-Split-qemuBuildCpuArgStr.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0002-qemu-Don-t-compare-CPU-against-host-for-TCG.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0003-Cpu-Add-support-for-Power-LE-Architecture.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0004-PowerPC-Add-support-for-launching-VM-in-compat-mode.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0005-PowerPC-Improve-PVR-handling-to-fall-back-to-cpu-gen.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0006-docs-Add-documentation-for-compat-mode.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0007-Test-Add-a-testcase-for-PowerPC-compat-mode-cpu-spec.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : Patch needed to apply next patch (CPU LE arch support) correctly

------- Comment on attachment From <email address hidden> 2014-11-28 10:06 EDT-------

Needed for cleanly applying patch '003B', which I will upload next.

This is upstream commit :
commit 44e30277d847f1d2e28531b0020f6a5ad8835542
Author: Eric Blake <email address hidden>
Date: Wed Sep 3 13:32:36 2014 -0600

    maint: use consistent if-else braces in qemu

    I'm about to add a syntax check that enforces our documented
    HACKING style of always using matching {} on if-else statements.

    This commit focuses on the qemu driver.

    * src/qemu/qemu_command.c (qemuParseISCSIString)
    (qemuParseCommandLineDisk, qemuParseCommandLine)
    (qemuBuildSmpArgStr, qemuBuildCommandLine)
    (qemuParseCommandLineDisk, qemuParseCommandLineSmp): Correct use
    of {}.
    * src/qemu/qemu_capabilities.c (virQEMUCapsProbeCPUModels):
    Likewise.
    * src/qemu/qemu_driver.c (qemuDomainCoreDumpWithFormat)
    (qemuDomainRestoreFlags, qemuDomainGetInfo)
    (qemuDomainMergeBlkioDevice): Likewise.
    * src/qemu/qemu_hotplug.c (qemuDomainAttachNetDevice): Likewise.
    * src/qemu/qemu_monitor_text.c (qemuMonitorTextCreateSnapshot)

Revision history for this message
bugproxy (bugproxy) wrote : Updated patch for Adding LE architecture support to CPU

------- Comment on attachment From <email address hidden> 2014-11-28 10:12 EDT-------

(NOTE: This patch needs to be applied after " maint: use consistent if-else braces in qemu " )

This is updated patch for adding PPC64LE arch support to libvirt CPU driver.
This obsoletes "0003-Cpu-Add-support-for-Power-LE-Architecture.patch"

Upstream commit :
commit da636d83dc6b1d070a705786b4daef8644eaca13
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 22:51:26 2014 +0530

    Cpu: Add support for Power LE Architecture.

    This adds support for PowerPC Little Endian architecture.,
    and allows libvirt to spawn VMs based on 'ppc64le' architecture.

    Signed-off-by: Pradipta Kr. Banerjee <email address hidden>
    Signed-off-by: Prerna Saxena <email address hidden>
    Reviewed-by: Michal Privoznik <email address hidden>

Revision history for this message
Serge Hallyn (serge-hallyn) wrote :

These patches (at least the one in comment #27) are in the vivid package (1.2.12-0ubuntu12).

Revision history for this message
bugproxy (bugproxy) wrote : 0001-qemu_command-Split-qemuBuildCpuArgStr.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0002-qemu-Don-t-compare-CPU-against-host-for-TCG.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0003-Cpu-Add-support-for-Power-LE-Architecture.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0004-PowerPC-Add-support-for-launching-VM-in-compat-mode.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0005-PowerPC-Improve-PVR-handling-to-fall-back-to-cpu-gen.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0006-docs-Add-documentation-for-compat-mode.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0007-Test-Add-a-testcase-for-PowerPC-compat-mode-cpu-spec.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : Patch needed to apply next patch (CPU LE arch support) correctly

------- Comment on attachment From <email address hidden> 2014-11-28 10:06 EDT-------

Needed for cleanly applying patch '003B', which I will upload next.

This is upstream commit :
commit 44e30277d847f1d2e28531b0020f6a5ad8835542
Author: Eric Blake <email address hidden>
Date: Wed Sep 3 13:32:36 2014 -0600

    maint: use consistent if-else braces in qemu

    I'm about to add a syntax check that enforces our documented
    HACKING style of always using matching {} on if-else statements.

    This commit focuses on the qemu driver.

    * src/qemu/qemu_command.c (qemuParseISCSIString)
    (qemuParseCommandLineDisk, qemuParseCommandLine)
    (qemuBuildSmpArgStr, qemuBuildCommandLine)
    (qemuParseCommandLineDisk, qemuParseCommandLineSmp): Correct use
    of {}.
    * src/qemu/qemu_capabilities.c (virQEMUCapsProbeCPUModels):
    Likewise.
    * src/qemu/qemu_driver.c (qemuDomainCoreDumpWithFormat)
    (qemuDomainRestoreFlags, qemuDomainGetInfo)
    (qemuDomainMergeBlkioDevice): Likewise.
    * src/qemu/qemu_hotplug.c (qemuDomainAttachNetDevice): Likewise.
    * src/qemu/qemu_monitor_text.c (qemuMonitorTextCreateSnapshot)

Revision history for this message
bugproxy (bugproxy) wrote : Updated patch for Adding LE architecture support to CPU

------- Comment on attachment From <email address hidden> 2014-11-28 10:12 EDT-------

(NOTE: This patch needs to be applied after " maint: use consistent if-else braces in qemu " )

This is updated patch for adding PPC64LE arch support to libvirt CPU driver.
This obsoletes "0003-Cpu-Add-support-for-Power-LE-Architecture.patch"

Upstream commit :
commit da636d83dc6b1d070a705786b4daef8644eaca13
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 22:51:26 2014 +0530

    Cpu: Add support for Power LE Architecture.

    This adds support for PowerPC Little Endian architecture.,
    and allows libvirt to spawn VMs based on 'ppc64le' architecture.

    Signed-off-by: Pradipta Kr. Banerjee <email address hidden>
    Signed-off-by: Prerna Saxena <email address hidden>
    Reviewed-by: Michal Privoznik <email address hidden>

Revision history for this message
Breno Leitão (breno-leitao) wrote :

I confirmed that the patches were included in vivid. Thanks!

Revision history for this message
bugproxy (bugproxy) wrote : 0001-qemu_command-Split-qemuBuildCpuArgStr.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0002-qemu-Don-t-compare-CPU-against-host-for-TCG.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0003-Cpu-Add-support-for-Power-LE-Architecture.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0004-PowerPC-Add-support-for-launching-VM-in-compat-mode.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0005-PowerPC-Improve-PVR-handling-to-fall-back-to-cpu-gen.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0006-docs-Add-documentation-for-compat-mode.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : 0007-Test-Add-a-testcase-for-PowerPC-compat-mode-cpu-spec.patch

Default Comment by Bridge

Revision history for this message
bugproxy (bugproxy) wrote : Patch needed to apply next patch (CPU LE arch support) correctly

------- Comment on attachment From <email address hidden> 2014-11-28 10:06 EDT-------

Needed for cleanly applying patch '003B', which I will upload next.

This is upstream commit :
commit 44e30277d847f1d2e28531b0020f6a5ad8835542
Author: Eric Blake <email address hidden>
Date: Wed Sep 3 13:32:36 2014 -0600

    maint: use consistent if-else braces in qemu

    I'm about to add a syntax check that enforces our documented
    HACKING style of always using matching {} on if-else statements.

    This commit focuses on the qemu driver.

    * src/qemu/qemu_command.c (qemuParseISCSIString)
    (qemuParseCommandLineDisk, qemuParseCommandLine)
    (qemuBuildSmpArgStr, qemuBuildCommandLine)
    (qemuParseCommandLineDisk, qemuParseCommandLineSmp): Correct use
    of {}.
    * src/qemu/qemu_capabilities.c (virQEMUCapsProbeCPUModels):
    Likewise.
    * src/qemu/qemu_driver.c (qemuDomainCoreDumpWithFormat)
    (qemuDomainRestoreFlags, qemuDomainGetInfo)
    (qemuDomainMergeBlkioDevice): Likewise.
    * src/qemu/qemu_hotplug.c (qemuDomainAttachNetDevice): Likewise.
    * src/qemu/qemu_monitor_text.c (qemuMonitorTextCreateSnapshot)

Revision history for this message
bugproxy (bugproxy) wrote : Updated patch for Adding LE architecture support to CPU

------- Comment on attachment From <email address hidden> 2014-11-28 10:12 EDT-------

(NOTE: This patch needs to be applied after " maint: use consistent if-else braces in qemu " )

This is updated patch for adding PPC64LE arch support to libvirt CPU driver.
This obsoletes "0003-Cpu-Add-support-for-Power-LE-Architecture.patch"

Upstream commit :
commit da636d83dc6b1d070a705786b4daef8644eaca13
Author: Prerna Saxena <email address hidden>
Date: Tue Nov 4 22:51:26 2014 +0530

    Cpu: Add support for Power LE Architecture.

    This adds support for PowerPC Little Endian architecture.,
    and allows libvirt to spawn VMs based on 'ppc64le' architecture.

    Signed-off-by: Pradipta Kr. Banerjee <email address hidden>
    Signed-off-by: Prerna Saxena <email address hidden>
    Reviewed-by: Michal Privoznik <email address hidden>

Revision history for this message
bugproxy (bugproxy) wrote : Comment bridged from LTC Bugzilla

------- Comment From <email address hidden> 2016-02-11 01:04 EDT-------
Closing this bug as the fix has been released.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.