# wireless cluestick

## pangloss

maybe someone can give me the beat-down with the wireless cluestick?

i have a fujitsu p2110 laptop that has a built-in 802.11b (intersil prism2 mini pci). once upon a time i had the linux-wlan-ng drivers clumsily working (long since wiped). since then, i had heard that included with kernel 2.4.19 was a new and better orinoco driver that works great with prism2 cards. i've tried so many things, but i think it's time to ask for help.

could someone look over my process and tell me where i've gone terribly wrong?

- recompile kernel 2.4.19-gentoo-sources with

```
CONFIG_PCMCIA=m

CONFIG_CARDBUS=y

CONFIG_NET_RADIO=m

CONFIG_HERMES=m

CONFIG_PLX_HERMES=m

CONFIG_PCMCIA_HERMES=m

CONFIG_NET_PCMCIA=y

CONFIG_NET_PCMCIA_RADIO=y
```

- unmerge & merge pcmcia-cs

- patch /etc/init.d/pcmcia and /etc/conf.d/pcmcia using files from https://bugs.gentoo.org/show_bug.cgi?id=6838 (in /etc/conf.d/pcmcia I have PCIC="yenta_socket"

- update-modules and add pcmcia to default runlevel.

- reboot

dmesg shows:

```
Linux Kernel Card Services 3.1.22

  options:  [pci] [cardbus] [pm]

PCI: Found IRQ 9 for device 00:0c.0

Yenta IRQ list 0cf8, PCI irq9

Socket status: 30000006

cs: IO port probe 0x0c00-0x0cff: clean.

cs: IO port probe 0x0800-0x08ff: clean.

cs: IO port probe 0x0100-0x04ff: excluding 0x408-0x40f 0x480-0x48f 0x4d0-0x4d7

cs: IO port probe 0x0a00-0x0aff: clean.
```

lsmod includes:

```
ds                      6304   1 

yenta_socket            8544   1 

pcmcia_core            37440   0  [ds yenta_socket]

8139too                12896   1 

mii                     1056   0  [8139too]
```

I had thought one of the orinoco drivers would have been loaded automagically, but that wasn't the case.

```
# modprobe orinoco_plx

/lib/modules/2.4.19-gentoo-r7/kernel/drivers/net/wireless/orinoco_plx.o: init_module: No such device

Hint: insmod errors can be caused by incorrect module parameters, including invalid IO or IRQ parameters.

      You may find more information in syslog or the output from dmesg

/lib/modules/2.4.19-gentoo-r7/kernel/drivers/net/wireless/orinoco_plx.o: insmod /lib/modules/2.4.19-gentoo-r7/kernel/drivers/net/wireless/orinoco_plx.o failed

/lib/modules/2.4.19-gentoo-r7/kernel/drivers/net/wireless/orinoco_plx.o: insmod orinoco_plx failed
```

But modprobe orinico_cs seems to work, with lsmod now including:

orinoco_cs              4200   0  (unused)

orinoco                30432   0  [orinoco_cs]

However, ifconfig -a only shows eth0 and lo. Shouldn't it be showing an eth1 or wlan0 or something?

also:

```
# iwconfig

# cardctl ident

Socket 0:

  no product info available

# cat /proc/net/wireless 

Inter-| sta-|   Quality        |   Discarded packets               | Missed

 face | tus | link level noise |  nwid  crypt   frag  retry   misc | beacon

#
```

let the cluestick beating begin  :Wink: 

----------

## pangloss

so i just saw someone else's (non-gentoo) kernel config. his had:

CONFIG_HERMES=y

# CONFIG_PLX_HERMES is not set

CONFIG_PCI_HERMES=y

# CONFIG_PCMCIA_HERMES is not set

# CONFIG_AIRO_CS is not set

CONFIG_NET_WIRELESS=y

there is no orinoco_pci driver in my /usr/src/linux/drivers/net/wireless! so it's not even an option when doing make menuconfig. is this something that was deliberately nixed from 2.4.19-gentoo-sources, and if so, why?

----------

## pangloss

such bad form to reply to myself twice  :Razz: 

anyway, i've been toiling away and have made some progress. hopefully this will be of use to someone else too.

gentoo-sources 2.4.19-r7 includes orinoco-0.09b which does *not* include the orinoco_pci driver. however, later releases of the orinoco drivers (namely 0.11x and 0.12x) do. 

here's what i don't quite get: i noticed when you emerge pcmcia-cs, one of the files that gets downloaded is orinoco-0.12b.tar.gz. but for whatever reason, it doesn't install orinoco_pci into /lib/modules/2.4.19-gentoo-r7/pcmcia even though orinoco and orinoco_cs do. (and i'd recompiled my kernel without pcmcia/cardbus support now, so as to use the pcmcia-cs modules). so i downloaded a new copy of orinoco-0.12b from ozlabs and built orinoco_pci.o which i then copied into /lib/modules/2.4.19-gentoo-r7/pcmcia.

so now, on reboot, lsmod includes:

```
ds                      6560   1 

i82365                 22928   1 

pcmcia_core            48096   0  [ds i82365]
```

is there a way to get the orinoco_pci module loaded automagically the way the other pcmcia stuff does? i had to do a manual "modprobe orinoco_pci", which then added

```
orinoco_pci             2368   1 

orinoco                31392   0  [orinoco_pci]

hermes                  5408   0  [orinoco_pci orinoco]
```

now ifconfig shows an eth1! =) which is great, but it doesn't have an ip assigned. how do i get it so that it also automagically uses dhcp to get its address? i tried dhcpcd eth1 just to see if i could get it working manually but that didn't work....

argh. i feel like this is the home stretch. thanks in advance for any help.

----------

## rac

Apologies if this is unrelated, but have you seen https://forums.gentoo.org/faq.php#11?

----------

## pangloss

hi rac  :Smile: 

no i hadn't seen it--and while it didn't deal with the other horrid problems i've been dealing with, it gave me enough of a clue to get some other issues worked out, so thank-you!

ok, here's a summary howto. there are still some issues that would be great to work out, but not tonight  :Wink: 

- build kernel

```
# CONFIG_PCMCIA is not set

CONFIG_NET_RADIO=y

CONFIG_NET_WIRELESS=y
```

- emerge pcmcia-cs

- download orinico-0.12b, unpack, make (don't make install) and copy orinoco_pci.o to /lib/modules/kernelxxx/pcmcia/

- patch /etc/init.d/pcmcia and /etc/conf.d/pcmcia using patches and suggestions from https://bugs.gentoo.org/show_bug.cgi?id=6838 (in /etc/conf.d/pcmcia I have PCIC="i82365"

- add hermes, orinoco, and orinoco_pci to modules.autoload

- update-modules

- copy /etc/init.d/net.eth0 to /etc/init.d/net.eth1. before the interface gets brought up, add a line like "/usr/sbin/iwconfig ${IFACE} essid MY_SSID"

- if you like add some dhcp timeouts to /etc/conf.d/net: dhcpcd_eth0="-t 20" and dhcpcd_eth1="-t 20"

- add pcmcia and net.eth1 to default runlevel.

- reboot 

- cross fingers  :Wink: 

so here's what's not so great and remember, you get extra points for audience participation   :Very Happy: 

- seems like you shouldn't have to hardcode in an essid in net.eth1. like you should be able to use the schemes defined in /etc/pcmcia/wireless.opts or set to find any avail access point sorta like windows xp can

- if one of the interfaces isn't available on boot, well, a) you have to wait for dhcp to timeout and worse, services like CUPS and NETMOUNT bitch that "Problem starting needed services" and don't start, even though *one* of the two interfaces did come up, so in fact your network is up and running.

----------

