qemu-devel
[Top][All Lists]
Advanced

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

Re: [PATCH] pc-bios/s390x: Pack ResetInfo struct


From: Jason J. Herne
Subject: Re: [PATCH] pc-bios/s390x: Pack ResetInfo struct
Date: Tue, 1 Sep 2020 09:02:28 -0400
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.1.0

On 8/27/20 6:07 AM, Thomas Huth wrote:
On 07/02/2020 15.02, Jason J. Herne wrote:
On 2/7/20 6:28 AM, Christian Borntraeger wrote:
Jason,

can you run objdump -Sdr on jump2ipl.o on a broken variant?


To keep the volume lower, I've only pasted the output that I think
you're interested in. If you want to see the entire thing just let me know.

static void jump_to_IPL_2(void)
{
  1d0:    eb bf f0 58 00 24     stmg    %r11,%r15,88(%r15)
  1d6:    a7 fb ff 50           aghi    %r15,-176
  1da:    b9 04 00 bf           lgr    %r11,%r15
     ResetInfo *current = 0;
  1de:    a7 19 00 00           lghi    %r1,0
  1e2:    e3 10 b0 a8 00 24     stg    %r1,168(%r11)

     void (*ipl)(void) = (void *) (uint64_t) current->ipl_continue;
  1e8:    e3 10 b0 a8 00 04     lg    %r1,168(%r11)
  1ee:    58 10 10 08           l    %r1,8(%r1)
  1f2:    b9 16 00 11           llgfr    %r1,%r1
  1f6:    e3 10 b0 a0 00 24     stg    %r1,160(%r11)
     *current = save;
  1fc:    e3 10 b0 a8 00 04     lg    %r1,168(%r11)
  202:    c0 20 00 00 00 00     larl    %r2,202 <jump_to_IPL_2+0x32>
             204: R_390_PC32DBL    .bss+0x2
  208:    eb 23 20 00 00 04     lmg    %r2,%r3,0(%r2)
  20e:    eb 23 10 00 00 24     stmg    %r2,%r3,0(%r1)
     ipl(); /* should not return */
  214:    e3 10 b0 a0 00 04     lg    %r1,160(%r11)
  21a:    0d e1                 basr    %r14,%r1
}
  21c:    18 00                 lr    %r0,%r0
  21e:    eb bf b1 08 00 04     lmg    %r11,%r15,264(%r11)
  224:    07 fe                 br    %r14
  226:    07 07                 nopr    %r7

I'm currently looking through the past s390-ccw bios patches that still
might need attention ... was there ever a follow up on this discussion?
Do we need to clear the registers before jumping to the OS?
And looking at the disassembly, should we declar the ipl function
pointer with __attribute__((noreturn)) ?


Janosch has done some cleanup work that has not hit master yet. This work, if accepted, would fix this problem and eliminate the need for this patch. So I think we should wait to see how that plays out before we revisit this.

--
-- Jason J. Herne (jjherne@linux.ibm.com)



reply via email to

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