[SeaBIOS] S3 resume is broken on QEMU

Kevin O'Connor kevin at koconnor.net
Fri Jan 20 14:40:09 CET 2012


On Fri, Jan 20, 2012 at 12:08:39PM +0100, Gerd Hoffmann wrote:
>   Hi,
> 
> > I do think moving from compile time options to runtime options is
> > important.  If you need a quick fix to get your build working, the
> > patch to seabios is below.  I do think we should try to figure out how
> > we can get options passed into SeaBIOS effectively.
> 
> Current runtime option is easy to handle on the qemu side, see attached
> patch.
[...]
> +/* see romfile_loadint() in src/paravirt.c in seabios */
> +void fw_cfg_romfile_storeint(FWCfgState *s, const char *fn, uint64_t val)
> +{
> +    uint64_t *st = g_malloc(sizeof(*st));
> +    *st = val;
> +    fw_cfg_add_file(s, fn, (void *)st, sizeof(*st));

Be sure to store the value in little-endian format.

-Kevin



More information about the SeaBIOS mailing list