[Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-11-21 Thread Michael S. Tsirkin
On Tue, Oct 19, 2010 at 11:08:21PM +0200, Stefan Weil wrote: PCI devices with different vendor or device ids sometimes share the same rom code. Only the ids and the checksum differs in a boot rom for such devices. The i825xx ethernet controller family is a typical example which is

[Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-20 Thread Gerd Hoffmann
Hi, The i825xx ethernet controller family is a typical example which is implemented in hw/eepro100.c. It uses at least 3 different device ids, so normally 3 boot roms would be needed. Does this actually work now with the etherboot roms? cheers, Gerd

[Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-20 Thread Stefan Weil
Am 20.10.2010 09:19, schrieb Gerd Hoffmann: Hi, The i825xx ethernet controller family is a typical example which is implemented in hw/eepro100.c. It uses at least 3 different device ids, so normally 3 boot roms would be needed. Does this actually work now with the etherboot roms? cheers,

Re: [Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-19 Thread Gerd Hoffmann
On 10/18/10 21:36, Stefan Weil wrote: There is already some kind of error feedback: the rom will not work. For etherboot roms, booting from network won't work. VGA works, after hacking the vgabios to not have the PCI ID hardcoded elsewhere. Nevertheless /me gets the feeling that we better

[Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-18 Thread Michael S. Tsirkin
On Mon, Oct 18, 2010 at 07:55:11PM +0200, Stefan Weil wrote: PCI devices with different vendor or device ids sometimes share the same rom code. Only the ids and the checksum differs in a boot rom for such devices. The i825xx ethernet controller family is a typical example which is

Re: [Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-18 Thread Anthony Liguori
On 10/18/2010 12:58 PM, Michael S. Tsirkin wrote: On Mon, Oct 18, 2010 at 07:55:11PM +0200, Stefan Weil wrote: PCI devices with different vendor or device ids sometimes share the same rom code. Only the ids and the checksum differs in a boot rom for such devices. The i825xx ethernet

Re: [Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-18 Thread Michael S. Tsirkin
On Mon, Oct 18, 2010 at 01:42:06PM -0500, Anthony Liguori wrote: +/* Patch the PCI vendor and device ids in a PCI rom image if necessary. + This is needed for an option rom which is used for more than one device. */ +static void pci_patch_ids(PCIDevice *pdev, uint8_t *ptr, int size) let's

Re: [Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-18 Thread Stefan Weil
Am 18.10.2010 21:03, schrieb Michael S. Tsirkin: On Mon, Oct 18, 2010 at 01:42:06PM -0500, Anthony Liguori wrote: +/* Patch the PCI vendor and device ids in a PCI rom image if necessary. + This is needed for an option rom which is used for more than one device. */ +static void

Re: [Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-18 Thread Anthony Liguori
On 10/18/2010 02:03 PM, Michael S. Tsirkin wrote: On Mon, Oct 18, 2010 at 01:42:06PM -0500, Anthony Liguori wrote: +/* Patch the PCI vendor and device ids in a PCI rom image if necessary. + This is needed for an option rom which is used for more than one device. */ +static void

Re: [Qemu-devel] Re: [PATCH 1/2] pci: Automatically patch PCI vendor id and device id in PCI ROM

2010-10-18 Thread Anthony Liguori
On 10/18/2010 02:36 PM, Stefan Weil wrote: Maybe a more perfect solution would only patch the preconfigured rom files but not user configured files, but I don't think we need this degree of perfection. Generally speaking, patching third-party code is not something that we should get in the