# PCMCIA-NIC not working after kernel upgrade

## schurke

Hi!

I have a Acer Travelmate 512TE (somewhat old thing) and a Surecom EP428X networking card (32bit Cardbus).

When i first tried to use it, lspci told me, it has a RTL8139 chip, so what i had in my kernel was:

```

-> Bus options (PCI, PCMCIA, EISA, MCA, ISA)  

   -> PCCARD (PCMCIA/CardBus) support  

      -> PCCard (PCMCIA/CardBus) support (PCCARD [=y])

          <*>   CardBus yenta-compatible bridge support   

-> Device Drivers

   -> Network device support  

      -> Ethernet (10 or 100Mbit)

         -> EISA, VLB, PCI and on board controllers (NET_PCI [=y])

             <*>   RealTek RTL-8129/8130/8139 PCI Fast Ethernet Adapter support

```

and it worked fine. While the kernel booted, it detected the card and the LED lit up.

The corresponding dmesg-output:

```

8139too Fast Ethernet driver 0.9.27

PCI: Enabling device 0000:02:00.0 (0000 -> 0003)

ACPI: PCI Interrupt 0000:02:00.0[A] -> Link [PILB] -> GSI 9 (level, low) -> IRQ 9

PCI: Setting latency timer of device 0000:02:00.0 to 64

eth0: RealTek RTL8139 at 0x1400, 00:02:44:b3:18:7e, IRQ 9

eth0:  Identified 8139 chip type 'RTL-8139C'

```

That was with kernel 2.6.16-gentoo-r12 (and older ones IIRC).

Today i switched to 2.6.17-gentoo-r7. I copied over .config, did "make oldconfig" (taking defaults almost everywhere).

The new kernel won't recognize the card anymore. 

I tried searching the forums, but found nothing relevant, still got some ideas i tried, like the 16bit NE2000 PCMCIA driver, 

the RealTek RTL-8139 C+ PCI driver, played around with pcmcia-cs (which i uninstalled now, since i found out it's only for 16bit),

hotplug... but nothing works. The card doesn't even show up in lspci any more.

Any ideas anyone? I would be too glad...

Greetings

Gregor

----------

## rigo

Hi,

I encountered the very same problem here. I've got an Acer Travelmate 202TEV Laptop (maybe even older than yours?!  :Smile: ) with a Cardbus card with the same chipset: Realtek 8139.

After the latest Kernel + hald update, it stopped working.

To me, the core of the problem seems that the card is not listed in the PCI device table, as it was before. That means, after you insert the card, you don't see it with the command "lspci". Loading the network card module, in fact, works only if the chip is recognized as a PCI card.

I think that if nobody answers this topic in a couple of days we could open a bug report.

----------

## schurke

 *rigo wrote:*   

> 
> 
> I think that if nobody answers this topic in a couple of days we could open a bug report.

 

Could you do that? It seems to me, that you would probably write a better bug report than me   :Smile: 

If i find a solution in the meantime, i will write it here

----------

## rigo

 *schurke wrote:*   

> 
> 
> Could you do that? It seems to me, that you would probably write a better bug report than me  
> 
> 

 

Now you can tell me if you'd have done better!  :Wink: 

https://bugs.gentoo.org/show_bug.cgi?id=147386

Please add a comment to that bug, reporting your experience.

----------

## arpunk

 *rigo wrote:*   

> Hi,
> 
> I encountered the very same problem here. I've got an Acer Travelmate 202TEV Laptop (maybe even older than yours?! ) with a Cardbus card with the same chipset: Realtek 8139.
> 
> After the latest Kernel + hald update, it stopped working.
> ...

 

Same happened to me, i have an atheros pcmcia wifi card and it works fine with the madwifi-ng drivers *but* only on 2.6.16-rN kernels. I upgraded to 2.6.17-rN kernel and althought the madwifi-ng driver compiles and runs ok, the laptop doesnt recognize it, funny thing i used the old config so i theory it should work. Ill post the message logs when i get the laptop.

----------

## rigo

 *arpunk wrote:*   

> Same happened to me, [...]
> 
> Ill post the message logs when i get the laptop.

 

Could you please post your information on the bug report, when youll'have it? It's here: https://bugs.gentoo.org/show_bug.cgi?id=147386

Thank you!

----------

## arpunk

I did already  :Smile: , if i find more info ill commit it to the bug report.

----------

## Dr. Frankenbox

Can you even run /etc/init.d/pcmcia start?  I recently upgraded a laptop to the 2.6.17-gentoo-r7 kernel, and while my PCMCIA bus shows up in lspci, when I try to run the pcmcia init script, it gives me the following error:

```
cardmgr[5461]: no pcmcia driver in /proc/devices
```

Despite this, I'm loading the appropriate driver.  I can see from dmesg that the module is finding my hardware:

```

Yenta: CardBus bridge found at 0000:00:02.0 [1014:0130]

Yenta: Using INTVAL to route CSC interrupts to PCI

Yenta: Routing CardBus interrupts to PCI

Yenta TI: socket 0000:00:02.0, mfunc 0x00001000, devctl 0x66

Yenta: ISA IRQ mask 0x0438, PCI irq 11

Socket status: 30000010

ACPI: PCI Interrupt 0000:00:02.1[B] -> Link [LNKB] -> GSI 11 (level, low) -> IRQ 11

Yenta: CardBus bridge found at 0000:00:02.1 [1014:0130]

Yenta: Using INTVAL to route CSC interrupts to PCI

Yenta: Routing CardBus interrupts to PCI

Yenta TI: socket 0000:00:02.1, mfunc 0x00001000, devctl 0x66

Yenta: ISA IRQ mask 0x0438, PCI irq 11

Socket status: 30000006

pccard: PCMCIA card inserted into slot 0

```

Like yours, my card is not showing up in lspci (though the PCMCIA bus is).  Are we having the same problem?

Edit: I'm starting to doubt it - I downgraded to kernel 2.6.15-r1, the oldest in portage, and it still doesn't work.  Still, any ideas?  It works fine in Knoppix.

----------

## rigo

 *Dr. Frankenbox wrote:*   

> Can you even run /etc/init.d/pcmcia start?  I recently upgraded a laptop to the 2.6.17-gentoo-r7 kernel, and while my PCMCIA bus shows up in lspci, when I try to run the pcmcia init script, it gives me the following error:
> 
> ```
> cardmgr[5461]: no pcmcia driver in /proc/devices
> ```
> ...

 I think this means that you're using the obsolete pcmcia-cs package. If you see its webpage: http://pcmcia-cs.sourceforge.net they say

 *pcmcia-cs website wrote:*   

> The Linux pcmcia-cs package is officially deprecated. It can only be used with 2.4 and older kernels. Current information on PCMCIA support for recent 2.6 kernels is available here

 You should use the gentoo package "pcmciautils" instead of "pcmcia-cs" (that's what I'm doing). This way, you're not going to need /etc/init.d/pcmcia any more, but you'll have to compile the PCMCIA support inside the kernel, or you'll have to load the modules at startup (see the information displayed when you emerge pcmciautils).

 *Dr. Frankenbox wrote:*   

> Like yours, my card is not showing up in lspci (though the PCMCIA bus is).  Are we having the same problem?

 I'm not sure, I think we probably do...   :Rolling Eyes: 

 *Quote:*   

> Edit: I'm starting to doubt it - I downgraded to kernel 2.6.15-r1, the oldest in portage, and it still doesn't work.  Still, any ideas?  It works fine in Knoppix.

 In this case, I'd double-check the kernel configuration (make xconfig & co.).

----------

## arpunk

 *rigo wrote:*   

> You should use the gentoo package "pcmciautils" instead of "pcmcia-cs" (that's what I'm doing). This way, you're not going to need /etc/init.d/pcmcia any more, but you'll have to compile the PCMCIA support inside the kernel, or you'll have to load the modules at startup (see the information displayed when you emerge pcmciautils). 

 

Yes, probably the gentoo handbook needs to change the pcmcia-cs installation for the pcmciautils?

----------

## Dr. Frankenbox

Yes.  I had no clue pcmcia-cs was deprecated, and the Gentoo docs really don't help.  They should put a disclaimer in the ebuild or something.

So anyway, I'm using pcmciautils now (I was already building the driver modules in my kernel, so it wasn't a big change), but my card still isn't working.  I tried to follow the mini HOWTO at http://kernel.org/pub/linux/utils/kernel/pcmcia/howto.html, but I'm not having any luck with either the 2.6.17 kernel or the 2.6.15 kernel.

Loading yenta_socket goes something like this:

```

Yenta: CardBus bridge found at 0000:00:02.1 [1014:0130]

Yenta: Using INTVAL to route CSC interrupts to PCI

Yenta: Routing CardBus interrupts to PCI

Yenta TI: socket 0000:00:02.1, mfunc 0x00001000, devctl 0x66

Yenta: ISA IRQ mask 0x0438, PCI irq 11

Socket status: 30000006

pccard: PCMCIA card inserted into slot 0

cs: unable to map card memory!

cs: unable to map card memory!

```

No attempts to load orinoco or hermes yield any result (they load, but they don't do anything), and nothing shows up in /sys/bus/pcmcia/devices.  The card isn't removable, so I can't try unplugging it and plugging it back in.  Any idea what's the matter?

----------

## rigo

 *Dr. Frankenbox wrote:*   

> Yes.  I had no clue pcmcia-cs was deprecated, and the Gentoo docs really don't help.  They should put a disclaimer in the ebuild or something.

 I think so too... I learned about the new system because every time I started the pcmcia-cs' daemon I had big warnings in the system log.

 *Quote:*   

> So anyway, I'm using pcmciautils now (I was already building the driver modules in my kernel, so it wasn't a big change), but my card still isn't working.  I tried to follow the mini HOWTO at [...]

 Sorry, I can't help you with that. 

 *Quote:*   

> 
> 
> ```
> Yenta: CardBus bridge found at 0000:00:02.1 [1014:0130]
> 
> ...

 I'm not having those error messages about the memory mapping... maybe they're important for understanding your case...   :Confused: 

 *Quote:*   

> No attempts to load orinoco or hermes yield any result (they load, but they don't do anything), and nothing shows up in /sys/bus/pcmcia/devices.  The card isn't removable, so I can't try unplugging it and plugging it back in. 

 When you run "pccardctl ls" your card isn't listed? That would seem strange to me... and you should be able to eject it using "pccardctl eject". Have you already tried it? *Quote:*   

> Any idea what's the matter?

 Sorry, no clue.   :Sad:   Perhaps, it could be useful if you repeat all this on the bug report...

----------

## rigo

I've found this on the Linux kernel's Bugzilla: http://bugzilla.kernel.org/show_bug.cgi?id=6725

Can anybody try the proposed solution there (comment #10) and tell us here and on our bug report if it helps? (and check out the kernel patch too...)

My laptop is currently busy, re-compiling half of its software because of the latest incompatible openssl update...   :Mad: 

----------

## arpunk

 *rigo wrote:*   

> I've found this on the Linux kernel's Bugzilla: http://bugzilla.kernel.org/show_bug.cgi?id=6725
> 
> Can anybody try the proposed solution there (comment #10) and tell us here and on our bug report if it helps? (and check out the kernel patch too...)
> 
> My laptop is currently busy, re-compiling half of its software because of the latest incompatible openssl update...  

 

So i tried it as soon as i readed your reply and my wifi PCMCIA card got recognized. Ive tried the pci=conf1 parameter at boot and it worked, now im posting this from the laptop  :Razz: , im gonna put a comment also in the bug report.

EDIT: Comment posted on the bug report.

----------

## rigo

 *arpunk wrote:*   

> So i tried it as soon as i readed your reply and my wifi PCMCIA card got recognized. Ive tried the pci=conf1 parameter at boot and it worked, now im posting this from the laptop , im gonna put a comment also in the bug report.

 

Great!!  :Very Happy:  I'm still compiling, so I'll check as soon as I can.

EDIT: it works for me too, with the pci=conf1 parameter!!   :Very Happy: 

----------

## Dr. Frankenbox

 *rigo wrote:*   

> When you run "pccardctl ls" your card isn't listed? That would seem strange to me... and you should be able to eject it using "pccardctl eject". Have you already tried it?

 

That is correct.  Even after I run pccardctl eject 0 and pccardctl insert 0 (and do the same with 1), I still get this:

```
PRODID_1=""

PRODID_2=""

PRODID_3=""

PRODID_4=""

MANFID=0000,0000

FUNCID=255

PRODID_1=""

PRODID_2=""

PRODID_3=""

PRODID_4=""

MANFID=0000,0000

FUNCID=255

```

----------

## rigo

 *Dr. Frankenbox wrote:*   

> Even after I run pccardctl eject 0 and pccardctl insert 0 (and do the same with 1), I still get this:
> 
> ```
> PRODID_1=""
> 
> ...

 You're supposed to get this after you've ejected the card, but not when the card has been just _physically_ inserted and you've issued the command "pccardctl insert".

Your problem seems quite different than ours...   :Confused: 

Please try the boot parameter "pci=conf1" and see if it helps!

----------

## Dr. Frankenbox

How do I use this boot parameter you speak of?  I can't just add "pci=conf1" to lilo.conf; it freaks out.

----------

## rigo

 *Dr. Frankenbox wrote:*   

> How do I use this boot parameter you speak of?  I can't just add "pci=conf1" to lilo.conf; it freaks out.

 What do you mean "it freaks out"?

By the way, it's some years I've not been using LILO, so all I can tell you is RTFM. Sorry  :Sad: 

```
man lilo.conf
```

----------

## Dr. Frankenbox

Well, when I enter "pci=conf1", lilo can't parse the config file.  Now, if I use it as a kernel parameter, ala 'append="pci=conf1"', then it doesn't change anything: after I reboot, my system behaves exactly the same as it did without any parameters.

----------

## rigo

 *Dr. Frankenbox wrote:*   

> Now, if I use it as a kernel parameter, ala 'append="pci=conf1"'

 That's what you're supposed to do. *Quote:*   

> then it doesn't change anything: after I reboot, my system behaves exactly the same as it did without any parameters.

 In this case, I don't know what you could do to solve your problem. Sorry.  :Sad: 

----------

