lkml.org 
[lkml]   [1999]   [Sep]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [patch] pci probing
Hello,

> There are 16 resource structures in a pci_dev now. This wasn't due to
> Martin, though: much of the expansion is because pci_dev is now
> supposed to handle the union of PCI and PnP device needs. And because
> of (imho) wrong-headed things like putting human-readable device
> descriptions in the pci_dev struct.

I always was against putting any such device naming tables to the kernel,
but (as you can see from the lots of mail exchanged between me and Linus
and CC'ed to linux-kernel) Linus insisted on them and even refused to make
them a compile-time option.

> The new PCI code did make CardBus support somewhat more complicated.
> The code needed for initializing a new PCI device has gotten larger.
> I have mixed feelings about this: I do think the linux device model
> needed work, however, I've also grown to appreciate the philosophy of
> keeping kernel interfaces simple. The current CardBus code fills in
> enough fields to make things work, but with the latest kernel, that
> means I'm leaving the majority of fields uninitialized.

Isn't it possible to use the generic PCI code to scan the bus behind
the CardBus bridge and then just fix the differences? It would require
a bit of ifdeffing around in pci.c to avoid __initfunc'ing the bus
scan functions if CardBus support is enabled, but we'll need it for
hot-pluggable PCI anyway. If you want to go this way, I'll gladly
make these modifications.

> The old interfaces did not make CardBus and hot plug stuff especially
> difficult. The resource management changes also didn't really make
> things any easier. The new resource code does distinguish between
> reserving resources, and associating them with a device driver, and
> that is useful. I can't use it for PCMCIA, however, because the
> kernel can only pre-enumerate PCI resources for now.

Yes, but you can add enumeration of other device types (from PNP
BIOS or ACPI tables) in a simple and straightforward way. I'm not sure
about Linus accepting such a thing, but if it will be tied to a configure
option, it should not be a problem. Also, if done this way, other drivers
will be able to benifit from the detailed resource maps, not only PCMCIA.

Have a nice fortnight
--
Martin `MJ' Mares <mj@ucw.cz> http://atrey.karlin.mff.cuni.cz/~mj/
Faculty of Math and Physics, Charles University, Prague, Czech Rep., Earth
"Whoa...I did a 'cp /vmlinuz >/dev/audio' and I think I heard God..."

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:53    [W:0.040 / U:23.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site