Messages in this thread | | | Date | Tue, 12 Dec 2000 00:16:12 +0100 | From | Martin Mares <> | Subject | Re: pdev_enable_device no longer used ? |
| |
Hello!
> It is the bar cookies in pci dev structure that are insane, in my opinion. > > If a driver needs BARs values, it needs actual BARs values and not some > stinking cookies. What a driver can do with BAR cookies other than using > them as band-aid for dubiously designed kernel interface.
If a driver wants to know the BAR values, it can pick them up in the configuration space itself. The problem is that these values mean absolutely nothing outside the bus the device resides on. There exist zillions of translating bridges and no driver except for the driver for the particular bridge should ever assume anything about them.
The values in pci_dev->resource[] are not some random cookies, they are genuine physical addresses as seen by the CPU and as accepted by ioremap().
Have a nice fortnight -- Martin `MJ' Mares <mj@ucw.cz> <mj@suse.cz> http://atrey.karlin.mff.cuni.cz/~mj/ "People disagree with me. I just ignore them." -- Linus Torvalds - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org Please read the FAQ at http://www.tux.org/lkml/
| |