[UBUNTU] QEMU toleration patch to ensure cpu detection in a nested KVM

Bug #1830704 reported by bugproxy on 2019-05-28
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu on IBM z Systems
High
Canonical Server Team
qemu (Ubuntu)
Status tracked in Eoan
Bionic
Undecided
Unassigned
Cosmic
Undecided
Unassigned
Disco
Undecided
Unassigned
Eoan
Undecided
Skipper Bug Screeners

Bug Description

[Impact]

 * The kernel detects CPU types and enables/disables some features based
   on that. With future HW this detection is broken as the csske facility
   is no more available.

 * This is fixed upstream and here backported, the csske is ignored when
   expanding the cpu model for the guest and thereby the issue avoided.

[Test Case]

 * Start a kvm guest on s390x
 * While doing so qemu/kvm will try to detect the host model
 * Check what CPU it detects the model
 * Note: this will work (regression check) on all s390x HW, but to prove
   the fix and trigger the issue one would need experimental (not GA yet)
   HW or a similator. Hence we are relying on the bug reporter for
   verification.
 * For the functionality of this check the initial commit adding the
   core feature [1] which shows how the filtering works.

[1]: https://github.com/qemu/qemu/commit/30e82de70

[Regression Potential]

 * If there would be a detection that depends on csske being available or
   not that would be affected. But there is none that this is important
   for. All existing machines still have csske, for those the issue never
   existed and nothing should change. The behavior on new machines will
   "change", but not regress. And in addition those new HW was never sold
   yet, so even if that would be considered a regression it wouldn't
   happen in the field.

[Other Info]

 * n/a

---

A nested KVM hypervisor has problems to detect the cpu type as z10..z14 with no csske facility available. Instead it will fall back to z9.

We need a backport of

commit eaf6f642abf1d4d24791b70728d4068428fc4658
Author: Christian Borntraeger <email address hidden>
AuthorDate: Mon Apr 29 05:02:43 2019 -0400
Commit: Cornelia Huck <email address hidden>
CommitDate: Tue May 21 16:59:16 2019 +0200

    s390x/cpumodel: ignore csske for expansion

    ...

    Signed-off-by: Christian Borntraeger <email address hidden>
    Cc: <email address hidden>
    Reviewed-by: David Hildenbrand <email address hidden>
    Message-Id: <email address hidden>
    Signed-off-by: Cornelia Huck <email address hidden>

diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c
index e5afa15512..b4bb5de635 100644
--- a/target/s390x/cpu_models.c
+++ b/target/s390x/cpu_models.c
@@ -1322,6 +1322,8 @@ static void init_ignored_base_feat(void)
          S390_FEAT_KM_TDEA_192,
          S390_FEAT_KIMD_SHA_1,
          S390_FEAT_KLMD_SHA_1,
+ /* CSSKE is deprecated on newer generations */
+ S390_FEAT_CONDITIONAL_SSKE,
     };
     int i;

This patch is also needed for Ubuntu 18.04 and 19.04.
18.10 will be out of service in July.....

bugproxy (bugproxy) on 2019-05-28
tags: added: architecture-s39064 bugnameltc-177881 severity-high targetmilestone-inin1910
Changed in ubuntu:
assignee: nobody → Skipper Bug Screeners (skipper-screen-team)
affects: ubuntu → qemu (Ubuntu)
summary: - QEMU toleration patch to ensure cpu detection in a nested KVM
+ [UBUNTU] QEMU toleration patch to ensure cpu detection in a nested KVM
Changed in qemu (Ubuntu Bionic):
status: New → Triaged
Changed in qemu (Ubuntu Cosmic):
status: New → Triaged
Changed in qemu (Ubuntu Disco):
status: New → Triaged
Changed in qemu (Ubuntu Eoan):
status: New → Triaged
Changed in ubuntu-z-systems:
status: New → Triaged
importance: Undecided → High
assignee: nobody → Canonical Server Team (canonical-server)

Tested the PPA for general regressions which seems ok. The actual change needs special HW which for now we can only ask IBM to test or ack.

Uploaded to Eoan and (as it will need a while there) also already to B/C/D -unapproved.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qemu - 1:3.1+dfsg-2ubuntu5

---------------
qemu (1:3.1+dfsg-2ubuntu5) eoan; urgency=medium

  * d/p/ubuntu/define-ubuntu-machine-types.patch: fix wily machine type being
    broken since 2.11 due to 2.3/2.4 version mismatch in its definition to
    fix migrations from old machines (LP: #1829868).
  * d/p/ubuntu/lp-1830704-s390x-cpumodel-ignore-csske-for-expansion.patch
    toleration for future machines (LP: #1830704

 -- Christian Ehrhardt <email address hidden> Tue, 28 May 2019 11:30:42 +0200

Changed in qemu (Ubuntu Eoan):
status: Triaged → Fix Released
Changed in ubuntu-z-systems:
status: Triaged → In Progress
Łukasz Zemczak (sil2100) wrote :

Can we get the SRU information on this bug? Would be great to get a test case and regression potential analysis here.

Thanks for the ping sil2100, I have forgotten to move the thoughts I had into a proper SRU template.

description: updated

Hello bugproxy, or anyone else affected,

Accepted qemu into disco-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/qemu/1:3.1+dfsg-2ubuntu3.2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-disco to verification-done-disco. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-disco. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in qemu (Ubuntu Disco):
status: Triaged → Fix Committed
tags: added: verification-needed verification-needed-disco
Changed in qemu (Ubuntu Cosmic):
status: Triaged → Fix Committed
tags: added: verification-needed-cosmic
Timo Aaltonen (tjaalton) wrote :

Hello bugproxy, or anyone else affected,

Accepted qemu into cosmic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/qemu/1:2.12+dfsg-3ubuntu8.9 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-cosmic to verification-done-cosmic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-cosmic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in qemu (Ubuntu Bionic):
status: Triaged → Fix Committed
tags: added: verification-needed-bionic
Timo Aaltonen (tjaalton) wrote :

Hello bugproxy, or anyone else affected,

Accepted qemu into bionic-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/qemu/1:2.11+dfsg-1ubuntu7.15 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested and change the tag from verification-needed-bionic to verification-done-bionic. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-bionic. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in ubuntu-z-systems:
status: In Progress → Fix Committed
Frank Heimes (frank-heimes) wrote :

Running 'qemu-system-s390x -cpu help' with the packages from proposed for disco, cosmic and bionic look fine (from what I can see) - hence so far at least no regression.

@IBM please test Bionic/Cosmic/Disco on your internal machines to verify this.

------- Comment From <email address hidden> 2019-06-24 06:39 EDT-------
verified on bionic-proposed (2.11+dfsg-1ubuntu7.15)

------- Comment From <email address hidden> 2019-06-24 06:51 EDT-------
successfully verified on cosmic-proposed (2.12+dfsg-3ubuntu8.9)

------- Comment From <email address hidden> 2019-06-24 06:59 EDT-------
Also verified on disco-proposed (3.1+dfsg-2ubuntu3.2)

tags: added: verification-done verification-done-bionic verification-done-cosmic verification-done-disco
removed: verification-needed verification-needed-bionic verification-needed-cosmic verification-needed-disco
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qemu - 1:2.11+dfsg-1ubuntu7.15

---------------
qemu (1:2.11+dfsg-1ubuntu7.15) bionic; urgency=medium

  * d/p/ubuntu/define-ubuntu-machine-types.patch: fix wily machine type being
    broken since 2.11 due to 2.3/2.4 version mismatch in its definition to
    fix migrations from old machines (LP: #1829868).
  * d/p/ubuntu/lp-1830704-s390x-cpumodel-ignore-csske-for-expansion.patch
    toleration for future machines (LP: #1830704

 -- Christian Ehrhardt <email address hidden> Wed, 22 May 2019 13:14:15 +0200

Changed in qemu (Ubuntu Bionic):
status: Fix Committed → Fix Released

The verification of the Stable Release Update for qemu has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qemu - 1:2.12+dfsg-3ubuntu8.9

---------------
qemu (1:2.12+dfsg-3ubuntu8.9) cosmic; urgency=medium

  * d/p/ubuntu/define-ubuntu-machine-types.patch: fix wily machine type being
    broken since 2.11 due to 2.3/2.4 version mismatch in its definition to
    fix migrations from old machines (LP: #1829868).
  * d/p/ubuntu/lp-1830704-s390x-cpumodel-ignore-csske-for-expansion.patch
    toleration for future machines (LP: #1830704

 -- Christian Ehrhardt <email address hidden> Tue, 28 May 2019 10:49:09 +0200

Changed in qemu (Ubuntu Cosmic):
status: Fix Committed → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qemu - 1:3.1+dfsg-2ubuntu3.2

---------------
qemu (1:3.1+dfsg-2ubuntu3.2) disco; urgency=medium

  * d/p/ubuntu/define-ubuntu-machine-types.patch: fix wily machine type being
    broken since 2.11 due to 2.3/2.4 version mismatch in its definition to
    fix migrations from old machines (LP: #1829868).
  * d/p/ubuntu/lp-1830704-s390x-cpumodel-ignore-csske-for-expansion.patch
    toleration for future machines (LP: #1830704
  * d/control-in, d/control: add versioned dependencies to libseccomp 2.4 as
    any rebuild against 2.4 as it is in proposed right now will otherwise
    crash (LP: #1830859).

 -- Christian Ehrhardt <email address hidden> Tue, 28 May 2019 10:52:47 +0200

Changed in qemu (Ubuntu Disco):
status: Fix Committed → Fix Released
Changed in ubuntu-z-systems:
status: Fix Committed → Fix Released

------- Comment From <email address hidden> 2019-06-25 01:50 EDT-------
IBM bugzilla status -> closed, Fix Released for all requested distros.

bugproxy (bugproxy) wrote :

------- Comment From <email address hidden> 2019-06-25 03:39 EDT-------
*** Bug 177874 has been marked as a duplicate of this bug. ***

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

Other bug subscribers