# Anyone having luck with 2.6.0, PCMCIA and WiFi?

## Tronic

All important stuff compiled in, no errors in kernel log, but the hardware stays dead and I cannot figure any way to access it. As far as I know, nobody else has got it working either.

Using the pcmcia-cs might be OK too, at least if no hacks are required to get it compile on 2.6.0. However, kernel's internal stuff is naturally preferred..

So, please share whatever you know about running these on 2.6.0 kernels, thanks.

----------

## devilfish

I'm running a 2.6.0-test4 kernel on a compaq 1720us laptop with an Orinoco silver card, using the kernel's own pcmcia and wireless code.  I use the wireless-tools-27_pre2 package and the tools only (no modules) from pcmcia-cs-3.2.4. So far, everything is living happily together.

In /etc/conf.d/pcmcia, I had to use PCIC="yenta_socket", but that was also the case when I was using a 2.4 kernel.

After editing wireless.opts and network.opts in /etc/pcmcia/ to reflect your setup, running the script "/etc/init.d/pcmcia start" should start cardmgr, detect the card, and bring up the network interface.

Relevant lines from my kernel .config:

CONFIG_NET_RADIO=y

CONFIG_PCMCIA=m

CONFIG_YENTA=m

CONFIG_CARDBUS=y

# CONFIG_I82092 is not set

# CONFIG_I82365 is not set

# CONFIG_TCIC is not set

CONFIG_PCMCIA_PROBE=y

CONFIG_HERMES=m

CONFIG_PCMCIA_HERMES=m

CONFIG_NET_WIRELESS=y

Good luck!

----------

## Tronic

emerge pcmcia-cs-tools

```

Kernel configuration options:

    Kernel-tree PCMCIA support is disabled.

    Symmetric multiprocessing support is disabled.

    Preemptive kernel support is enabled.

    High memory support is disabled.

    PCI BIOS support is enabled.

    Power management (APM) support is disabled.

    SCSI support is enabled.

    IEEE 1394 (FireWire) support is disabled.

    Networking support is enabled.

     Radio network interface support is enabled.

     Token Ring device support is disabled.

     Fast switching is disabled.

     Frame Diverter is disabled.

    Module version checking is enabled.

    Kernel debugging support is enabled.

     Memory leak detection support is disabled.

     Spinlock debugging is disabled.

    Preemptive kernel patch is enabled.

    /proc filesystem support is enabled.

    PAE support is disabled.

 

2.5.0 and later kernels require that PCMCIA be configured in the

    kernel source tree.  To fix, reconfigure and rebuild your

    kernel with PCMCIA enabled.

 

Configuration failed.

```

It apparently misdetects the PCMCIA support (yes, I have it enabled in my kernel). It also misdetects many other things (FireWire, Network support etc).

----------

## ronmon

Make sure you have ISA support enabled in your kernel config. I recently switched to a 2.6 kernel and missed that. It took a bit of googling to figure that out.

----------

## Tronic

Yeah, that is enabled too.

Other suggestions?

----------

## thundersteele

kompile it against an 2.4.xx kernel  :Smile: 

I don't know yet if that works, I am just trying this.

edit: It seems to work, don't have card to test this

----------

## Gandalf_Grey_

My builtin wireless card is working great in linux.

----------

## Gandalf_Grey_

ugh, sorry it is amazing how little I thought about that post.

I meant to say, my orinoco card is working well witht he 2.6 test 5 mmsources. I just have the kernel stuff, and only wireless tools

----------

## devilfish

Yes, as thundersteele says, compiling pcmcia-cs against 2.4 kernel sources should work; I was also able to compile it against 2.6.0-test4 sources after editing include/scsi/scsi.h in the kernel sources and changing every occurrence of the (undefined!) "u8" type to "__u8" (see this discussion on the linux-kernel list).  Probably using the "unsigned char" type instead of "u8" would work, too...

----------

## Tronic

 *devilfish wrote:*   

> Yes, as thundersteele says, compiling pcmcia-cs against 2.4 kernel sources should work; I was also able to compile it against 2.6.0-test4 sources after editing include/scsi/scsi.h in the kernel sources and changing every occurrence of the (undefined!) "u8" type to "__u8" (see this discussion on the linux-kernel list).  Probably using the "unsigned char" type instead of "u8" would work, too...

 

I don't see what SCSI header of a kernel that is not actually even required for building (the tools only) has to do with this.

However, I managed to get the tools built and after removing some broken checks done in pcmcia-cs Configure script. Just commenting out all (the problematic) fail clauses in the script fixed it. Here are some of the problems:

-Apparently cannot read my kernel's .config and uses some random defaults (didn't care to analyze further, because disabling the check did the trick)

-Wants modutils version greater than 2.something. But the new version (module-init-tools) stupidly "downgraded" the version number to 0.9.something (smaller number, more recent version!).

When trying to manually build it, it did, however, get the kernel config right. emerge pcmcia-cs-tools got it randomly.

Now I'm only looking for a simple way to get the Gentoo package installed. I cannot think of a way to edit the Configure script used by it.

----------

## FlipFlop

Anyone got the linux-hotplug script that comes with the atmel_cs driver to work ?

I installed the script and firmwares with "make install-hotplug" but it didnt load the firmware..

I then tried the other approach that uses a custom firmware loader and that worked ..

All-in-all it took me a few hours to get my previous external pcmcia-cs with external atmelwlandriver setup converted to 2.6.0 pcmcia in kernel with kernel driver..

My 3Com 3CRSHPW_96 Wireless LAN PC Card now seems to work in linux-2.6.0-test5-mm3

With linux you are never bored  :Smile: 

----------

## devilfish

 *Tronic wrote:*   

> 
> 
> I don't see what SCSI header of a kernel that is not actually even required for building (the tools only) has to do with this
> 
> 

 

There is a utility called "scsi_info" that is part of the pcmcia-cs package, and it needs scsi.h in order to be compiled.  I'm sure neither of us needs it, however.  :Smile: 

 *Tronic wrote:*   

> 
> 
> When trying to manually build it, it did, however, get the kernel config right. emerge pcmcia-cs-tools got it randomly.
> 
> 

 

Yeah, just for fun, I tried to emerge pcmcia-cs-tools, and I had the same problem with its buggy configure script.  Have you tried to emerge pcmcia-cs instead of pcmcia-cs-tools?  I know you don't need the modules, but the pcmcia-cs configure script seems to correctly detect that I already have the 2.6 kernel pcmcia modules, and therefore does not build its own.  It just builds and installs the pcmcia tools, which is what you want, right?

----------

## Tronic

Yeah, tried with it too - it correctly detects my kernel  stuff, but the two other problems still exist:

-Compains about missing modversions.h; touching the file was enough to fool the script that I have one, so this one is solved too.

-Complains about module-init-tools' version (0.9.12) is too old for it, because it wants at least (modutils) 2.1.85.

I think somebody really should fix this. If the pcmcia-cs developers won't do it then maybe some of the all-friendly Gentoo developers would :)

----------

## Kenadin

Tronic, pcmcia-cs 3.2.5 fix the modutils requiring 2.1.85.  However it isn't in portage yet.  What I did was (as root)

```

cd /usr/portage/sys-apps/pcmcia-cs/

cp pcmcia-cs-3.2.4.ebuild pcmcia-cs-3.2.5.ebuild

```

Then i edited pcmcia-cs-3.2.5.ebuild and made these changes:

From

```

SRC_URI="mirror://sourceforge/pcmcia-cs/${P}.tar.gz

        http://airsnort.shmoo.com/${P}-orinoco-patch.diff"

```

To

```

SRC_URI="mirror://sourceforge/pcmcia-cs/${P}.tar.gz"

```

And From

```

        cd ${S}

        epatch ${DISTDIR}/${P}-orinoco-patch.diff

```

To

```

#        cd ${S}

#        epatch ${DISTDIR}/${P}-orinoco-patch.diff

```

Then i did emerge pcmcia-cs-3.2.5.ebuild and it compiled and works fine.

EDIT - fixed typo

----------

## d3vlin

this method indeed seems to work like a charm!  :Smile: 

In the veign of gentoo; I think it's best to move the script to the local portage overlay dir (see PORTAGE_OVERLAY in /etc/make.conf) :

```

cd /usr/portage/sys-apps/pcmcia-cs/

<do the modifications as described in post above>

mkdir /usr/local/portage/sys-apps/pcmcia-cs/

mv pcmcia-cs-3.2.5.ebuild /usr/local/portage/sys-apps/pcmia-cs/

ebuild pcmcia-cs-3.2.5.ebuild digest

emerge pcmcia-cs-3.2.5.ebuild

```

this way the ebuild doesn't get removed when syncing portage.

----------

## watersb

 *Tronic wrote:*   

> emerge pcmcia-cs-tools
> 
> It apparently misdetects the PCMCIA support (yes, I have it enabled in my kernel). It also misdetects many other things (FireWire, Network support etc).

 

This is an old, old bug.

Just compile the kernel with the kernel support, and with kernel modules.

Then emerge pcmcia-cs -- that is NOT the "-tools" version, but the "whole" version of the package. It should detect kernel support and kernel drivers, and only build the userspace tools.

----------

## ClausH

 *FlipFlop wrote:*   

> 
> 
> I then tried the other approach that uses a custom firmware loader and that worked ..
> 
> 

 

I can not get this to work, i get a

```

atmel_fwl: eth1 is not an Atmel interface.

```

this i no matter what interface i use it on (it should be eth1), so i guess there is something there isn't loaded.

I have compiled the atmel driver (atmel_cs), into the kernel, modprobed it, but still nothing...

i hope someone can help

Mvh Claus Holmgaard

----------

## FlipFlop

Did you load the atmel_cs module first ?

----------

## pi-cubic

 *devilfish wrote:*   

> Yes, as thundersteele says, compiling pcmcia-cs against 2.4 kernel sources should work; I was also able to compile it against 2.6.0-test4 sources after editing include/scsi/scsi.h in the kernel sources and changing every occurrence of the (undefined!) "u8" type to "__u8" (see this discussion on the linux-kernel list).  Probably using the "unsigned char" type instead of "u8" would work, too...

 

i have exactly the same problem with the scsi.h! somewhere in lines 215 of this file, i could find the u8 type. because i don't know what i am doing, i wanted you to ask if you could help me a lil' bit, my question: do i only have to change the type "u8" into "__u8" in only one line? or do i have to do this with every line of the function?

----------

## ClausH

 *FlipFlop wrote:*   

> Did you load the atmel_cs module first ?

 

Yup! same result   :Sad: 

Mvh Claus Holmgaard

----------

## Tronic

 *pi-cubiq wrote:*   

> i have exactly the same problem with the scsi.h! somewhere in lines 215 of this file, i could find the u8 type. because i don't know what i am doing, i wanted you to ask if you could help me a lil' bit, my question: do i only have to change the type "u8" into "__u8" in only one line? or do i have to do this with every line of the function?

 

Two options:

-Search & replace in the entire file

-Add a line to the beginning: typedef __u8 u8;

The result should be the same.

----------

## FlipFlop

 *ClausH wrote:*   

> Yup! same result   

 

I put the line in wireless.opts in the pcmcia directory .. that will run it at the right time.. when do you run it ?

----------

## ClausH

 *FlipFlop wrote:*   

> I put the line in wireless.opts in the pcmcia directory .. that will run it at the right time.. when do you run it ?

 

hmm, i just modprobe atmel_cs, and then run it. I supposed it would work. I believe pcmcia-cs-tools were already started when i did this!

Mvh Claus Holmgaard

----------

## pi-cubic

ok, now i can compile pcmcia-cs, but it's not buildung any driver modules. i think they should be configured in the kernel... i used to take the orinoco_cs module for my card. since the 2.6.x cardmgr searches for a prism2_cs module which i don't have. what's the deal with that?

----------

## shiftzero

 *FlipFlop wrote:*   

>  *ClausH wrote:*   Yup! same result    
> 
> I put the line in wireless.opts in the pcmcia directory .. that will run it at the right time.. when do you run it ?

 

I have the same problem.   Do you mean you modprobe manually or let pcmcia do it?   What was the procedure you used?  thnx in advance

----------

## ClausH

 *frostshade wrote:*   

> I have the same problem.   Do you mean you modprobe manually or let pcmcia do it?   What was the procedure you used?  thnx in advance

 

I start the computer, pcmcia-cs-tools start with it, i then modprobe atmel_cs, and finally i do the firmware thing. I have tried a few other things, but none work.

Mvh Claus Holmgaard

----------

