RE: [RFC v2 25/39] pcmcia: add HAS_IOPORT dependencies

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Arnd Bergmann
> Sent: 04 May 2022 11:33
> 
> On Wed, May 4, 2022 at 1:38 AM Bjorn Helgaas <helgaas@xxxxxxxxxx> wrote:
> > On Fri, Apr 29, 2022 at 03:50:41PM +0200, Niklas Schnelle wrote:
> > > In a future patch HAS_IOPORT=n will result in inb()/outb() and friends
> > > not being declared. PCMCIA devices are either LEGACY_PCI devices
> > > which implies HAS_IOPORT or require HAS_IOPORT.
> > >
> > > Acked-by: Dominik Brodowski <linux@xxxxxxxxxxxxxxxxxxxx>
> > > Co-developed-by: Arnd Bergmann <arnd@xxxxxxxxxx>
> > > Signed-off-by: Niklas Schnelle <schnelle@xxxxxxxxxxxxx>
> > > ---
> > >  drivers/pcmcia/Kconfig | 2 +-
> > >  1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/pcmcia/Kconfig b/drivers/pcmcia/Kconfig
> > > index 2ce261cfff8e..32b5cd324c58 100644
> > > --- a/drivers/pcmcia/Kconfig
> > > +++ b/drivers/pcmcia/Kconfig
> > > @@ -5,7 +5,7 @@
> > >
> > >  menuconfig PCCARD
> > >       tristate "PCCard (PCMCIA/CardBus) support"
> > > -     depends on !UML
> > > +     depends on HAS_IOPORT
> >
> > I don't know much about PC Card.  Is there a requirement that these
> > devices must use I/O port space?  If so, can you include a spec
> > reference in the commit log?
> 
> I think for PCMCIA devices, the dependency makes sense because
> all device drivers for PCMCIA devices need I/O ports.

ISTR some PCMCIA linear non-volatile memory cards that only
supported memory accesses.
I'm pretty sure some didn't even decode config space properly.
(I bet none of them still work after 25 years though.)

I've used I/O addresses on pcmcia cards from sparc and ARM cpu.

> For cardbus, we can go either way, I don't see any reference to
> I/O ports in yenta_socket.c or the pccard core, so it would build
> fine with or without I/O ports.

cardbus is basically PCI.
I think you can find cardbus cards that have a pci bridge and a cable
link to an expansion chassis into which you can insert standard PCI cards.
If you are really lucky the initial enumeration allocates the
'high field' bus numbers, io addresses and plenty of memory
space to the bridge - otherwise you lose.

	David

-
Registered Address Lakeside, Bramley Road, Mount Farm, Milton Keynes, MK1 1PT, UK
Registration No: 1397386 (Wales)




[Index of Archives]     [Linux Kernel]     [Kernel Newbies]     [x86 Platform Driver]     [Netdev]     [Linux Wireless]     [Netfilter]     [Bugtraq]     [Linux Filesystems]     [Yosemite Discussion]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]

  Powered by Linux