tPCIDev PCI_GetDevice(Uint16 vendor, Uint16 device, int idx)\r
{\r
int i, j=0;\r
- for(i=0;i<giPCI_DeviceCount;i++)\r
+ for( i = 0; i < giPCI_DeviceCount; i ++ )\r
{\r
if(gPCI_Devices[i].vendor != vendor) continue;\r
if(gPCI_Devices[i].device != device) continue;\r
return 0;\r
\r
info->ConfigCache[0] = vendor_dev;\r
- for( i = 1; i < 256/4; i ++, addr += 4 )\r
+ for( i = 1, addr += 4; i < 256/4; i ++, addr += 4 )\r
{\r
info->ConfigCache[i] = PCI_CfgReadDWord(addr);\r
} \r
info->revision = tmp & 0xFFFF;\r
info->oc = tmp >> 16;\r
\r
- //#if LIST_DEVICES\r
- //Log("BAR0 0x%08x BAR1 0x%08x BAR2 0x%08x", info->ConfigCache[4], info->ConfigCache[5], info->ConfigCache[6]);\r
- //Log("BAR3 0x%08x BAR4 0x%08x BAR5 0x%08x", info->ConfigCache[7], info->ConfigCache[8], info->ConfigCache[9]);\r
- //Log("Class: 0x%04x", info->oc);\r
- //#endif\r
+// #if LIST_DEVICES\r
+// Log("BAR0 0x%08x BAR1 0x%08x BAR2 0x%08x", info->ConfigCache[4], info->ConfigCache[5], info->ConfigCache[6]);\r
+// Log("BAR3 0x%08x BAR4 0x%08x BAR5 0x%08x", info->ConfigCache[7], info->ConfigCache[8], info->ConfigCache[9]);\r
+// Log("Class: 0x%04x", info->oc);\r
+// #endif\r
\r
// Make node name\r
info->Name[0] = '0' + bus/10;\r