On 7/13/20 7:59 PM, Philippe Mathieu-Daudé wrote: > On 7/13/20 4:57 PM, Cédric Le Goater wrote: >> On 7/9/20 2:36 AM, Havard Skinnemoen wrote: >>> This allows these NPCM7xx-based boards to boot from a flash image, e.g. >>> one built with OpenBMC. For example like this: >>> >>> IMAGE=${OPENBMC}/build/tmp/deploy/images/gsj/image-bmc >>> qemu-system-arm -machine quanta-gsj -nographic \ >>> -bios ~/qemu/bootrom/npcm7xx_bootrom.bin \ >>> -drive file=${IMAGE},if=mtd,bus=0,unit=0,format=raw,snapshot=on >>> >>> Reviewed-by: Tyrone Ting <kft...@nuvoton.com> >>> Signed-off-by: Havard Skinnemoen <hskinnem...@google.com> >> >> May be we don't need to create the flash object if dinfo is NULL. > > Well, this is not wrong since m25p80_realize() check for the 'drive' > property, but I'd rather avoid using fake block, and instead force > users wanting an empty flash to use '-drive driver=null-co,...'. > > So I prefer Cédric suggestion too.
Ah I see the model is fixed, is this SPI flash soldered on the board? > >> Reviewed-by: Cédric Le Goater <c...@kaod.org> >> Tested-by: Cédric Le Goater <c...@kaod.org> >> >> Nice ! >> >> We need a SPI controller model and a network device model now. >> >> npcm7xx_bootrom.bin is a bit of a pain. Could we include it in >> the QEMU roms ? > > Ah, this is what I asked on patch #6 ;) >