[Ubuntu 21.04] IBM Z go binary crashes under Qemu
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ubuntu on IBM z Systems |
Fix Released
|
High
|
Skipper Bug Screeners | ||
qemu (Ubuntu) |
Fix Released
|
Undecided
|
Canonical Server | ||
Focal |
Invalid
|
Undecided
|
Unassigned | ||
Groovy |
Won't Fix
|
Undecided
|
Unassigned | ||
Hirsute |
Fix Released
|
Undecided
|
Canonical Server |
Bug Description
Running the IBM Z go binary under qemu segfaults.
---uname output---
Linux 97f388a80d88 5.8.0-45-generic #51-Ubuntu SMP Fri Feb 19 13:24:51 UTC 2021 s390x s390x s390x GNU/Linux
---Steps to Reproduce---
qemu-s390x-static -E LD_LIBRARY_PATH=./ ./go
Userspace tool common name: qemu
Userspace rpm: qemu-s390x version 5.0.0 (Debian 1:5.0-5ubuntu9.6)
The userspace tool has the following bit modes: 64
Userspace tool obtained from project website: na
Patch by IBM has been accepted upstream already. The patch has been tested on Qemu stable branch (v 5.0) as well and found to fix the problem.
https:/
focal (20.04LTS) 1:4.2-3ubuntu6.14 [security]: amd64
focal-updates 1:4.2-3ubuntu6.14
groovy (20.10) 1:5.0-5ubuntu9.6 [security]: amd64
groovy-updates 1:5.0-5ubuntu9.6
hirsute (metapackages)
The patch also fits onto Qemu 4.2 as in 20.04. However, problem couldn't be reproduced with a Qemu 4.2 build.
Related branches
- Paride Legovini (community): Approve
- Canonical Server: Pending requested
- git-ubuntu developers: Pending requested
-
Diff: 78 lines (+56/-0)3 files modifieddebian/changelog (+7/-0)
debian/patches/series (+1/-0)
debian/patches/ubuntu/lp-1922010-linux-user-s390x-Use-the-guest-pointer-for-the-sigre.patch (+48/-0)
tags: | added: architecture-s39064 bugnameltc-192246 severity-critical targetmilestone-inin2104 |
Changed in ubuntu: | |
assignee: | nobody → Skipper Bug Screeners (skipper-screen-team) |
affects: | ubuntu → qemu (Ubuntu) |
Changed in ubuntu-z-systems: | |
assignee: | nobody → Skipper Bug Screeners (skipper-screen-team) |
Changed in qemu (Ubuntu): | |
assignee: | Skipper Bug Screeners (skipper-screen-team) → Canonical Server Team (canonical-server) |
Changed in ubuntu-z-systems: | |
importance: | Undecided → High |
status: | New → Triaged |
Thanks for the Report!
That is:
commit 23fff7a17f47420 797ac6480147941 612152a9ad
Author: Andreas Krebbel <email address hidden>
Date: Wed Mar 24 19:51:28 2021 +0100
linux- user/s390x: Use the guest pointer for the sigreturn stub
When setting up the pointer for the sigreturn stub in the return
address register (r14) we currently use the host frame address instead
of the guest frame address.
Note: This only caused problems if Qemu has been built with
--disable-pie (as it is in distros nowadays). Otherwise guest_base
defaults to 0 hiding the actual problem.
Signed-off-by: Andreas Krebbel <email address hidden>
Reviewed-by: Laurent Vivier <email address hidden>
Reviewed-by: Richard Henderson <email address hidden>
Message-Id: <email address hidden>
Signed-off-by: Laurent Vivier <email address hidden>
$ git tag --contains 23fff7a17f47420 797ac6480147941 612152a9ad
v6.0.0-rc1
There are currently a bunch of qemu SRUs in flight which have to "clear the queue" first.
If until then you found that it also affects Focal we can fix that as well - let us know in this case.