Hi,
attached is a fixed version of my patch. So far only for v3, because I ran into another problem with v2 that needs to be fixed first.
Am Donnerstag, den 13.09.2007, 03:27 +0200 schrieb Uwe Hermann:
Index: src/devices/pci_device.c
--- src/devices/pci_device.c (revision 2770) +++ src/devices/pci_device.c (working copy) @@ -972,7 +972,34 @@ /* Read the rest of the pci configuration information */ hdr_type = pci_read_config8(dev, PCI_HEADER_TYPE); class = pci_read_config32(dev, PCI_CLASS_REVISION);
- u16 status = pci_read_config16(dev, PCI_STATUS);
- dev->status = status;
Is there a reaons why this wouldn't work?
dev->status = pci_read_config16(dev, PCI_STATUS); (much shorter)
No, there used to be a reason for this, but not anymore. Changed it to the shorter version.
/* Store the interesting information in the device structure */ dev->vendor = id & 0xffff; dev->device = (id >> 16) & 0xffff; Index: src/include/device/device.h =================================================================== --- src/include/device/device.h (revision 2770) +++ src/include/device/device.h (working copy) @@ -68,9 +68,19 @@ device_t sibling; /* next device on this bus */ device_t next; /* chain of all devices */
- char dtsname[64];
struct device_path path; unsigned vendor; unsigned device;
- u16 status;
Use TABs for indentation as per coding guidelines, please.
Done.
The patch looks good to me otherwise, but someone with more OFW knowledge should probably look over it, too.
I think Stefan already looked at it. (?)
Jens