qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH v3 4/4] pc-bios/s390x: Fix reset psw mask


From: Thomas Huth
Subject: Re: [PATCH v3 4/4] pc-bios/s390x: Fix reset psw mask
Date: Tue, 17 Dec 2019 13:36:29 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0

On 13/12/2019 13.06, Cornelia Huck wrote:
> On Thu, 5 Dec 2019 11:12:39 +0100
> Cornelia Huck <address@hidden> wrote:
> 
>> On Tue,  3 Dec 2019 08:28:13 -0500
>> Janosch Frank <address@hidden> wrote:
>>
>>> We need to set the short psw indication bit in the reset psw, as it is
>>> a short psw.
>>>
>>> fixes: 9629823290 ("pc-bios/s390-ccw: do a subsystem reset before running 
>>> the guest")
>>> Signed-off-by: Janosch Frank <address@hidden>
>>> ---
>>>  pc-bios/s390-ccw/jump2ipl.c | 12 +++++++-----
>>>  1 file changed, 7 insertions(+), 5 deletions(-)  
>>
>> Thanks, applied (together with a rebuild of the bios images.)
> 
> This unfortunately breaks 'make check-qtest-s390x':
> 
>    TEST    check-qtest-s390x: tests/boot-serial-test
>    TEST    check-qtest-s390x: tests/pxe-test
> ERROR - too few tests run (expected 1, got 0)
> 
> When I revert this, the rebuild, and "s390x: Properly fetch and test
> the short psw on diag308 subc 0/1" (as it exposes the bug this commit
> tried to fix), everything passes again. No idea what is wrong, though :(
> 
> For now, I've dropped the three patches mentioned above from the
> s390-next branch (I plan to send a pull request later). Let's fix this
> on top once we figured out whatever went wrong, no need to rush here.

I think I might have found the problem. You now need this patch on top
to get it working again:

diff a/pc-bios/s390-ccw/jump2ipl.c b/pc-bios/s390-ccw/jump2ipl.c
--- a/pc-bios/s390-ccw/jump2ipl.c
+++ b/pc-bios/s390-ccw/jump2ipl.c
@@ -18,7 +18,7 @@
 typedef struct ResetInfo {
     uint64_t ipl_psw;
     uint32_t ipl_continue;
-} ResetInfo;
+} __attribute__((packed)) ResetInfo;

 static ResetInfo save;

Without this patch, there is now a 32-bit padding in the struct. Not
sure why it then fails (I had a quick look at the disassembly of
jump2ipl.o and could not spot anything that was obviously wrong), but if
I mark the struct as "packed" to get the old size again, then the
pxe-test is working fine for me again.

 Thomas




reply via email to

[Prev in Thread] Current Thread [Next in Thread]