qemu-ppc
[Top][All Lists]
Advanced

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

Re: qemu/powernv: coreboot support?


From: Marty E. Plummer
Subject: Re: qemu/powernv: coreboot support?
Date: Sat, 19 Oct 2019 07:28:01 -0500

On Sat, Oct 19, 2019 at 10:15:19PM +1100, David Gibson wrote:
> On Fri, Oct 18, 2019 at 12:28:29PM -0500, Marty E. Plummer wrote:
> > Hello,
> > 
> > First off, thank you for the work you've done on the ppc64 support, it
> > has been very useful. I'm currently working on a coreboot port for the
> > talos ii line of systems (which means more ppc64 support, support
> > specifically for the power9 sforza chip, and specific mainboard support.
> > My plate is very full lol) and have been using qemu to debug the
> > bootblock.
> 
> Ok.  I'm assuming that's with the powernv machine type?
> 
Assuming you mean the hardware, yes, the kernel for it is configured
with the powernv_defconfig.

Assuming that you mean how I call qemu, yes, also powernv: my full
command is:

qemu-system-ppc64 -cpu power9 -M powernv -m 4G -s -S \
-chardev socket,id=qemu-monitor,host=localhost,port=7777,server,nowait,telnet \
-mon qemu-monitor,mode=readline -nographic -bios 
build/cbfs/fallback/bootblock.bin
> > It has been very useful for that, but I'm now at the point where I need
> > to jump to romstage, and that's where it gets tricky. qemu parses the rom
> > image and looks for a ffs header, locates skiboot on it, and jumps straight
> > to that. Not exactly ideal for debugging something not produced from
> > op-build.
> 
> Um.. I'm not sure what code you're talking about.  AFAICT the pnv code
> just starts the cpus at address 0x10.
> 
If I pass it the full coreboot.rom file via
`-drive file=./build/coreboot.rom,format=raw,if=mtd` it returns this error:
'qemu-system-ppc64: Initialization of device pnv-pnor failed: bad header'
which arises in hw/ppc/pnv_pnor.c:136-140 using legoater's powernv-4.2
branch.

Ah, so I wasn't going crazy and it was skipping the first four instructions,
how odd. Any particular reason the first four instruction are skipped?
On hostboot that's setting up the msr; on skiboot that seems to be the
fdt_entry branch to boot_entry.
> > Do you think it would be within your wheelhouse to provide a generic, 
> > non-ffs
> > pnor interface for loading arbitary rom images? It would be of great help if
> > you could. (This would still hopefully have the bmc support code as
> > well, as I'm still needing to support a system using one).
> 
> Uh.. and I'm not really sure what you're asking for here.
> 
Basically not have to have a pnor-style image for mtd devices, and not
immidiatly jump to skiboot.
> -- 
> David Gibson                  | I'll have my music baroque, and my code
> david AT gibson.dropbear.id.au        | minimalist, thank you.  NOT _the_ 
> _other_
>                               | _way_ _around_!
> http://www.ozlabs.org/~dgibson





reply via email to

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