Bug 226365 - ppc64: pseries: Loader: Unable to load two kernels in a row.
Summary: ppc64: pseries: Loader: Unable to load two kernels in a row.
Status: New
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: CURRENT
Hardware: powerpc Any
: --- Affects Only Me
Assignee: freebsd-ppc mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-05 12:58 UTC by Breno Leitao
Modified: 2018-03-06 07:17 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Breno Leitao 2018-03-05 12:58:59 UTC
I am not able to load two kernels in the loader. If I want to load a newer kernel, I need to unload the first one, otherwise it gets in the OFW trap. Example:


>> FreeBSD/powerpc Open Firmware boot block
   Boot path:   /vdevice/v-scsi@2000/disk@8000000000000000
   Boot loader: /boot/loader
   Boot volume:   /vdevice/v-scsi@2000/disk@8000000000000000:2
Consoles: Open Firmware console  

FreeBSD/powerpc64 Open Firmware loader, Revision 0.1
(Sun Feb 18 22:29:36 CET 2018 root@free8)
Memory: 8388608KB
Booted from: /vdevice/v-scsi@2000/disk@8000000000000000

Loading /boot/defaults/loader.conf
/boot/kernel/kernel data=0x129ebb0+0x4ccf90 syms=[0x8+0x16d370+0x8+0x1698ac]
/boot/entropy size=0x1000

Hit [Enter] to boot immediately, or any other key for command prompt.


Type '?' for a list of commands, 'help' for more detailed help.
OK load /boot/kernel.old/kernel
/boot/kernel.old/kernel data=0x129db60+0x4ccf60  

( 700 ) Program Exception [ 0 ]


    R0 .. R7           R8 .. R15         R16 .. R23         R24 .. R31
0000000032fc6a70   0000000002c04000   0000000000000000   000000005f690000   
0000000002c46a70   00000000000001b4   0000000000000000   0000000000008000   
0000000000000000   000000000344bca4   0000000002c46ad8   0000000002c72080   
000000000000005c   0000000002c442dc   0000000002c46adc   0000000000000000   
ffffffffffffffef   0000000000fd0000   0000000000000000   0000000000fd0000   
0000000000000000   0000000000000000   0000000000007fff   0000000002c69fc0   
00000000000001fa   0000000000000000   0000000002c46b1c   0000000000000000   
0000000002c46a88   0000000000000000   0000000002c46adc   00000000000001fa   

    CR / XER           LR / CTR          SRR0 / SRR1        DAR / DSISR
        88020028   0000000002c3b20c   0000000002c02328   0000000000000000   
0000000000000000   0000000002c2f160   0000000000083000           00000000   


Since the loader is claiming a specific memory area from the OFW, it does not fit both kernel. We should, either, ask for more memory for the newer kernel, or, reuse the same memory as used in the first kernel.