|
Lines 201-206
Link Here
|
| 201 |
fn = devfn & 0x7; |
201 |
fn = devfn & 0x7; |
| 202 |
if (tag == pciTag(bus,dev,fn)) { |
202 |
if (tag == pciTag(bus,dev,fn)) { |
| 203 |
/* ok now look through all the BAR values of this device */ |
203 |
/* ok now look through all the BAR values of this device */ |
|
|
204 |
pciConfigPtr pDev = xf86GetPciConfigFromTag(tag); |
| 205 |
|
| 204 |
for (ndx=0; ndx<7; ndx++) { |
206 |
for (ndx=0; ndx<7; ndx++) { |
| 205 |
unsigned long savePtr; |
207 |
unsigned long savePtr; |
| 206 |
/* |
208 |
/* |
|
Lines 208-218
Link Here
|
| 208 |
* memory attributes |
210 |
* memory attributes |
| 209 |
*/ |
211 |
*/ |
| 210 |
if (ndx == 6) |
212 |
if (ndx == 6) |
| 211 |
savePtr = (0xFFFFFFF0) & |
213 |
savePtr = PCIGETROM(pDev->pci_baserom); |
| 212 |
pciReadLong(tag, PCI_CMD_BIOS_REG); |
|
|
| 213 |
else /* this the ROM bar */ |
214 |
else /* this the ROM bar */ |
| 214 |
savePtr = (0xFFFFFFF0) & |
215 |
savePtr = (0xFFFFFFF0) & (&pDev->pci_base0)[ndx]; |
| 215 |
pciReadLong(tag, PCI_CMD_BASE_REG + (0x4 * ndx)); |
|
|
| 216 |
|
216 |
|
| 217 |
/* find the index of the incoming base */ |
217 |
/* find the index of the incoming base */ |
| 218 |
if (base >= savePtr && base <= (savePtr + size[ndx])) { |
218 |
if (base >= savePtr && base <= (savePtr + size[ndx])) { |