Re: 2.3 wish: integrate pcmcia into mainstream kernel

David Hinds (dhinds@lahmed.stanford.edu)
Tue, 1 Jun 1999 15:30:41 -0700


Linus Torvalds wrote:
>> Pavel Machek <pavel@bug.ucw.cz> wrote:
>>
>> `subj` is my 2.3 wish. Having pcmcia support outside of standard
>> kernel makes pcmcia drivers second-class citizens, which only work
>> sometimes.

As an aside, I'd question the assertion that having PCMCIA outside the
kernel causes it to "only work sometimes". I'm not aware of any major
PCMCIA problems that have been caused by kernel version skew, and all
such minor problems have been quickly fixed. I don't think PCMCIA has
had more such problems than other types of drivers that *are* in the
kernel: when there have been major changes in kernel interfaces, it
has not been uncommon for drivers to break.

There are certainly plenty of PCMCIA problems, but they are mostly
associated with resource allocation issues, PCI configuration issues,
inadequate vendor documentation, etc.

> Indeed. I would wish to have at least cardbus support in the default
> kernel, and eventually it will have to be written - the external pcmcia
> support indeed relegates it to second-class citizen support. And
> cardbus is much better done and defined than the original pcmcia anyway,
> and is what all modern laptops use.
>
> However, I'm not going to just use the pcmcia code as-is, as David Hinds
> has never been very excited about putting the support in the kernel.
> And I do believe that for the old-style pcmcia stuff the current
> approach is the right one anyway due to the ugly details. But if
> somebody were to start up a cardbus driver system, I wouldn't be unhappy...

I think this is the first time I've ever heard you express interest in
kernel support for dynamically configured devices. I'm somewhat
unhappy that it sounds like you're encouraging someone else to do it
differently.

"never been very excited" is a pretty accurate description of my
feelings about putting the PCMCIA package in the kernel. I think some
of the arguments for it have been weak. Having it out of the kernel
makes my life easier in some ways, and that's a non-trivial
consideration for me. I'm not dead-set against putting PCMCIA in the
kernel, and anyone who felt strongly enough about it is free to just
do it, though I'd prefer them to do it in a way that would make it
easy to propagate updates from my tree to the kernel tree.

In some sense, PCMCIA and CardBus are second-class citizens because
the Linux kernel is missing some key components that would make
dynamic device management convenient and reliable. One of those is
kernel support for Plug&Play BIOS calls, without which, resource
allocation for hot-plug devices will always be a shot in the dark.
ACPI will supercede this at some point, but my impression is that
Linux ACPI support is still a long way from being comprehensive enough
to handle this.

There are certainly things that would make CardBus support easier that
would be very nice to have in the kernel: for instance, the current
CardBus code has its own PCI device configurator because the kernel
doesn't provide this functionality. Hot swap PCI will need to do the
same stuff, so it should really be in the PCI subsystem. All the
current CardBus drivers are just regular kernel PCI drivers, so
CardBus is mostly already "in" the kernel source tree, in that sense.

-- Dave Hinds

-
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/