qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Gerd Hoffmann <kraxel@redhat.com>
To: Kevin O'Connor <kevin@koconnor.net>
Cc: Chris Wright <chrisw@redhat.com>,
	"Michael S. Tsirkin" <mst@redhat.com>,
	glommer@redhat.com, seabios@seabios.org, qemu-devel@nongnu.org,
	Alexander Graf <agraf@suse.de>,
	Sebastian Herbszt <herbszt@gmx.de>
Subject: Re: Proper support for PCI-based option rom loading (was Re:	[Qemu-devel] Re: qdev property bug?)
Date: Thu, 17 Dec 2009 10:45:45 +0100	[thread overview]
Message-ID: <4B29FDC9.4080109@redhat.com> (raw)
In-Reply-To: <20091217012434.GB11279@morn.localdomain>

On 12/17/09 02:24, Kevin O'Connor wrote:
> On Wed, Dec 16, 2009 at 05:22:41PM +0100, Gerd Hoffmann wrote:
> The current "CBFS" mechanism looks for named "files" of the following
> form:
>
> - pciVVVV,DDDD.rom - a rom associated with a PCI device with the given
>    vendor and device id.

Might be useful for backward compatibility with older qemu versions as 
adding a rom bar to the pci devices is a guest-visible change in pci 
config space.

> - vgaroms/* - any "file" starting with the "vgaroms/" prefix is
>    treated as a vga option rom not associated with any specific pci
>    device.

obvious place for vgabios.

> - genroms/* - any "file" starting with the "genroms/" prefix is
>    treated as a generic option rom not associated with any specific pci
>    device.

and this for the non-pci roms like extboot &

> Associating a name to the fw_cfg entries and using the naming
> convention above would allow SeaBIOS to reuse its existing code.

Ok.

>> I'd tend to have one fw_cfg entry which returns structed data, like this:
>>
>> struct fw_files {
>>    u32 filecount;
>>    struct fw_file {
>>      u32  type;        /* vga, option, other? */
>>      u32  size;        /* file size */
>>      u32  select;      /* write this to 0x510 to read it */
>>      u32  reserved;    /* you never know ;) */
>>      char name[16];    /* maybe: filename */
>>    };
>> };
>>
>> What do you think?
>
> It works for me.  The name would need to be larger (64 bytes?).

I'd size name so it pads the struct to 32 or 64 bytes total.  32bit 
size, 16bit select, 16bit reserved, leaves 24 bytes for the name with 32 
bytes.  Hmm, better to go for a 64 byte struct, leaving 56 bytes for the 
name, which should be enougth.

I'll have patches ready later today.

cheers,
   Gerd

  reply	other threads:[~2009-12-17  9:46 UTC|newest]

Thread overview: 101+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <20091213200259.GB25615@redhat.com>
     [not found] ` <4B260683.8000506@redhat.com>
     [not found]   ` <20091214093414.GA30459@redhat.com>
     [not found]     ` <4B26090B.8010707@redhat.com>
     [not found]       ` <20091214094406.GB32140@redhat.com>
     [not found]         ` <4B261082.4030806@redhat.com>
2009-12-14 10:59           ` [Qemu-devel] Re: qdev property bug? Michael S. Tsirkin
2009-12-14 11:55             ` Alexander Graf
2009-12-14 13:24               ` Michael S. Tsirkin
2009-12-14 13:35                 ` Alexander Graf
2009-12-14 14:01                   ` Michael S. Tsirkin
2009-12-14 17:00                     ` Glauber Costa
2009-12-14 14:11                   ` Anthony Liguori
2009-12-14 14:11                     ` Michael S. Tsirkin
2009-12-14 14:13                       ` Michael S. Tsirkin
2009-12-14 14:25                         ` Anthony Liguori
2009-12-14 16:20                           ` Michael S. Tsirkin
2009-12-14 19:12                           ` Sebastian Herbszt
2009-12-14 19:20                             ` Michael S. Tsirkin
2009-12-14 19:38                               ` Sebastian Herbszt
2009-12-14 19:33                             ` Anthony Liguori
2009-12-14 19:42                               ` Michael S. Tsirkin
2009-12-14 19:59                                 ` Anthony Liguori
2009-12-14 20:20                                   ` Michael S. Tsirkin
2009-12-14 20:32                                     ` Gerd Hoffmann
2009-12-14 20:34                                       ` Michael S. Tsirkin
2009-12-14 20:36                                         ` Michael S. Tsirkin
2009-12-14 20:44                                           ` Anthony Liguori
2009-12-14 20:51                                             ` Michael S. Tsirkin
2009-12-15  2:37                                               ` Proper support for PCI-based option rom loading (was Re: [Qemu-devel] Re: qdev property bug?) Anthony Liguori
2009-12-15  3:55                                                 ` Kevin O'Connor
2009-12-15  4:34                                                 ` Kevin O'Connor
2009-12-15 13:15                                                   ` Anthony Liguori
2009-12-15 14:20                                                     ` Anthony Liguori
2009-12-15 14:33                                                       ` [SeaBIOS] " Avi Kivity
2009-12-15 17:35                                                         ` Anthony Liguori
2009-12-15 23:54                                                           ` Kevin OConnor
2009-12-16  0:41                                                             ` Anthony Liguori
2009-12-16  4:20                                                               ` Kevin O'Connor
2009-12-15  9:17                                                 ` Gerd Hoffmann
2009-12-15 10:14                                                   ` Gerd Hoffmann
2009-12-15 19:10                                                     ` Anthony Liguori
2009-12-16 12:03                                                       ` Gerd Hoffmann
2009-12-16 12:39                                                         ` Michael S. Tsirkin
2009-12-16 13:42                                                           ` Gerd Hoffmann
2009-12-16 13:52                                                             ` Michael S. Tsirkin
2009-12-16 14:12                                                               ` Kevin O'Connor
2009-12-16 14:14                                                                 ` Michael S. Tsirkin
2009-12-16 14:17                                                                 ` Gleb Natapov
2009-12-16 14:15                                                                   ` Michael S. Tsirkin
2009-12-16 14:18                                                                     ` Gleb Natapov
2009-12-16 14:24                                                                       ` Michael S. Tsirkin
2009-12-16 14:28                                                                         ` Gleb Natapov
2009-12-16 14:28                                                                           ` Michael S. Tsirkin
2009-12-15 19:35                                                     ` Anthony Liguori
2009-12-15 21:17                                                       ` Michael S. Tsirkin
2009-12-15 21:41                                                         ` Anthony Liguori
2009-12-16  0:33                                                           ` Chris Wright
2009-12-16  1:32                                                             ` Anthony Liguori
2009-12-16  4:57                                                           ` Kevin O'Connor
2009-12-16 12:31                                                             ` Gerd Hoffmann
2009-12-16 16:22                                                             ` Gerd Hoffmann
2009-12-17  1:24                                                               ` Kevin O'Connor
2009-12-17  9:45                                                                 ` Gerd Hoffmann [this message]
2009-12-17  9:50                                                                   ` Michael S. Tsirkin
2009-12-17 10:40                                                                     ` Gerd Hoffmann
2009-12-16 14:41                                                           ` Gerd Hoffmann
2009-12-16 14:41                                                             ` Michael S. Tsirkin
2009-12-16 14:50                                                               ` [SeaBIOS] " Gleb Natapov
2009-12-15 13:16                                                   ` Anthony Liguori
2009-12-15 21:24                                                     ` Sebastian Herbszt
2009-12-15 21:31                                                       ` Anthony Liguori
2009-12-15 21:38                                                         ` Sebastian Herbszt
2009-12-15 22:00                                                           ` Anthony Liguori
2009-12-17 21:14                                                             ` Sebastian Herbszt
2009-12-16  4:29                                                       ` Kevin O'Connor
2009-12-16 12:01                                                         ` Gerd Hoffmann
2009-12-15 19:21                                                   ` Anthony Liguori
2009-12-15 21:19                                                     ` Michael S. Tsirkin
2009-12-15 21:45                                                       ` Anthony Liguori
2009-12-15 21:52                                                         ` Michael S. Tsirkin
2009-12-15 21:57                                                           ` Anthony Liguori
2009-12-15 21:59                                                             ` Michael S. Tsirkin
2009-12-15 22:26                                                               ` Anthony Liguori
2009-12-15 22:51                                                                 ` Sebastian Herbszt
2009-12-16 14:49                                                                   ` Gerd Hoffmann
2009-12-17 20:33                                                                     ` Sebastian Herbszt
2009-12-15 10:51                                                 ` Michael S. Tsirkin
2009-12-15 19:05                                                   ` Anthony Liguori
2009-12-15 19:06                                                     ` Anthony Liguori
2009-12-14 20:43                                         ` [Qemu-devel] Re: qdev property bug? Anthony Liguori
2009-12-14 20:50                                           ` Michael S. Tsirkin
2009-12-14 21:05                                             ` Anthony Liguori
2009-12-14 21:36                                               ` Sebastian Herbszt
2009-12-14 21:52                                                 ` Anthony Liguori
2009-12-14 22:14                                                   ` Sebastian Herbszt
2009-12-15  4:23                                               ` Kevin O'Connor
2009-12-14 20:47                                         ` Sebastian Herbszt
2009-12-14 20:56                                           ` Anthony Liguori
2009-12-14 20:38                                       ` Sebastian Herbszt
2009-12-14 19:51                               ` Sebastian Herbszt
2009-12-14 14:22                       ` Anthony Liguori
2009-12-14 17:03                         ` Glauber Costa
2009-12-14 17:01                       ` Glauber Costa
2009-12-14 14:10               ` Anthony Liguori
2009-12-14 14:52                 ` Gerd Hoffmann
2009-12-14 14:54                   ` Anthony Liguori

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4B29FDC9.4080109@redhat.com \
    --to=kraxel@redhat.com \
    --cc=agraf@suse.de \
    --cc=chrisw@redhat.com \
    --cc=glommer@redhat.com \
    --cc=herbszt@gmx.de \
    --cc=kevin@koconnor.net \
    --cc=mst@redhat.com \
    --cc=qemu-devel@nongnu.org \
    --cc=seabios@seabios.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).