# [EDITED] IPW3945bg (Kernel 2.6.23-r3)-Need Help Please

## bebobero

I am a beginner to Gentoo LInux and i have a problem with my wireless adapter on my laptop which is ipw3945bg

I read many solutions before and i tried lots of things and now i cleaned my system recompiled my kernel and emerged gnome.

I need you all to guide me step by step to install my driver and configure it please!

Best regards,

BeboberoLast edited by bebobero on Tue Jan 08, 2008 2:33 pm; edited 1 time in total

----------

## cyrius

Allright, i'm using the iwl4965 one. It should be quietly the same procedure.

First, you have to know that the drivers for your card are under development from intel. The last snapshot is not integrated in your kernel.

Anyway, to make it run :

 In your kernel configuration, for modules :

```

CONFIG_MODULES=y

CONFIG_MODULE_UNLOAD=y

CONFIG_MODULE_FORCE_UNLOAD=y

# CONFIG_MODVERSIONS is not set

# CONFIG_MODULE_SRCVERSION_ALL is not set

```

  In your kernel configuration, for network wireless :

```

#

# Wireless

#

CONFIG_CFG80211=y

CONFIG_WIRELESS_EXT=y

CONFIG_MAC80211=m

# CONFIG_MAC80211_DEBUG is not set

# CONFIG_IEEE80211 is not set

CONFIG_RFKILL=y

CONFIG_RFKILL_INPUT=y

# CONFIG_NET_9P is not set

```

   in your kernel configuration, for device drivers :

```

# Wireless LAN

#

# CONFIG_WLAN_PRE80211 is not set

CONFIG_WLAN_80211=y

# CONFIG_IPW2100 is not set

# CONFIG_IPW2200 is not set

# CONFIG_LIBERTAS is not set

# CONFIG_AIRO is not set

# CONFIG_HERMES is not set

# CONFIG_ATMEL is not set

# CONFIG_PRISM54 is not set

# CONFIG_USB_ZD1201 is not sethttp://www.intellinuxwireless.org/?p=iwlwifi

# CONFIG_RTL8187 is not set

# CONFIG_HOSTAP is not set

CONFIG_IWLWIFI=y

# CONFIG_IWLWIFI_DEBUG is not set

# CONFIG_IWL4965 is not set

# CONFIG_IWL3945 is not set

```

  You compile and reinstall your kernel.

  You emerge wireless-tools package.

 You go to the iwlwifi project : http://www.intellinuxwireless.org/?p=iwlwifi

  You download the last snapshot for mac80211 and ipw3945 : http://ipw3945.sourceforge.net/downloads.php

   With root user, you decompress all in /root.

   In /root/mac80211/, you do : make clean, make, make install.

   In /root/ipw3945, you do : make clean, make, make install.

   You can try for both : make patch_kernel 

   I think it's not longer supported (as it's not for my driver anymore).

    Anyway, when done, try : modprobe ipw3945

    Execute dmesg to see if your wireless card is ok.

    If it is, you can set up it in your /etc/conf.d/net file.

And Finally, have a look to this post : https://forums.gentoo.org/viewtopic-t-434817-highlight-.html for more detailed informations on your installation[/post]

Let me know if you are stuck.  :Very Happy: 

----------

## bebobero

If you could explain a little bit in a simpler way i would really appreciate it!

Regards,

Bebobero

----------

## cyrius

More simple way....?

What do you not understand ?

----------

## bebobero

Ok here is what i did i edited the file /usr/src/linux/.config and modified the lines you mentioned but when compiling i got an error about assigning something non existent as in iwlwifi line i ignored them and i am running make, make modules_install, make install.

Is this correct? If so then shall i emerge wireless tools next?

I downloaded ipw3945-1.2.0.tgz from the first link

on the second link there are lots of stuff i need help on what to download exactly please?  :Question: 

Best regards,

BeboBero

----------

## JeliJami

 *bebobero wrote:*   

> Ok here is what i did i edited the file /usr/src/linux/.config and modified the lines you mentioned but when compiling i got an error about assigning something non existent as in iwlwifi line i ignored them and i am running make, make modules_install, make install.
> 
> Is this correct?

 

You should not edit that .config file; use the following command, in the /usr/src/linux directory:

```
make menuconfig
```

http://www.gentoo.org/doc/en/kernel-upgrade.xml

 *Quote:*   

>  If so then shall i emerge wireless tools next?
> 
> I downloaded ipw3945-1.2.0.tgz from the first link
> 
> on the second link there are lots of stuff i need help on what to download exactly please? 
> ...

 

There are ebuilds for both ipw3945 and iwlwifi. They may support your card.

http://gentoo-wiki.com/HARDWARE_ipw3945

ipw3945 alternative: Intel's iwlwifi (experimental)

----------

## bebobero

Ok i already recompiled my kernel after editing the .confg file so DO i have to redo it again or what?

I thought that the lines in the post above is in the config file and it was there!

Also 

```
CONFIG_IWLWIFI=y

# CONFIG_IWLWIFI_DEBUG is not set

# CONFIG_IWL4965 is not set

# CONFIG_IWL3945 is not set 
```

 does not exist here

Please advice.

Best regards,

BeboBero

----------

## JeliJami

 *bebobero wrote:*   

> Ok i already recompiled my kernel after editing the .confg file so DO i have to redo it again or what?

 

I guess it would be OK.

 *Quote:*   

> 
> 
> I thought that the lines in the post above is in the config file and it was there!
> 
> Also 
> ...

 

My config file does not have any CONFIG_IWL* entry. 

Try the links I provided in my previous post.

----------

## bebobero

OK Now I have two problems

1- When compiling my kernel i got errors because the following things does not exist here in my kernel configuration:

```
CONFIG_IWLWIFI=y

# CONFIG_IWLWIFI_DEBUG is not set

# CONFIG_IWL4965 is not set

# CONFIG_IWL3945 is not set 
```

2- I downloaded the following Packages, so what shall i install?

ipw3945-1.2.0.tgz

iwlwifi-1.2.23.tgz

iwlwifi-3945-ucode-2.14.1.5.tgz

mac80211-10.0.4.tgz

I appreciate your fast help and reply.

Best Regards

BeboBero

----------

## cyrius

First, you have to use the command "make menuconfig" to configure your kernel.

You won't find iwlwifi and that's normal cause you didn't patch your kernel.

To do so, under root in the /root repertory :

```

gunzip ./mac80211-10.0.3.tgz

tar xvf ./mac80211-10.0.3.tar

cd mac80211-10.0.3

make clean

make

make patch_kernel

```

Then in your /usr/src/linux repertory, you do "make menuconfig".

You go in : "Enable loadable module support --->" and you set the modules according the description i gave you.

Go back.

You go in : "Networking->Wireless" and you set the modules according the description i gave you.

go back

You go in : "Device drivers-->Network device support-->Wireless Lan" and here you should be able to set up iwlwifi.

You compile your kernel, install it and reboot.

For ipw3945.tgz, you apply the same procedure.

Appart the last instruction which will be make install instead of make patch_kernel.

For, the microcode (iwlwifi-3945-ucode-2.14.1.5.tgz), you just decompress it into /lib/firmware repertory (if doesn't exist, you can create it with the root user : mkdir /lib/firmware

When done, try modprobe ipw3945

That's simple to do.

Anyway, you should read the wiki first. I was not aware it existed. And come back to my post. it will be more clear for you.

----------

## bebobero

I get a problem with mac80211

```
+ Applying: pending/0033-mac80211-fix-a-msdu-header.patch

 

-----patch failure output-----

patching file net/mac80211/ieee80211.c

Hunk #1 FAILED at 2817.

Hunk #2 FAILED at 2838.

Hunk #3 FAILED at 2890.

Hunk #4 FAILED at 2975.

Hunk #5 FAILED at 2990.

Hunk #6 FAILED at 3003.

Hunk #7 FAILED at 3019.

7 out of 7 hunks FAILED -- saving rejects to file net/mac80211/ieee80211.c.rej

pending/0033-mac80211-fix-a-msdu-header.patch failed. Terminating.

If patch or script failed, check pre/ and post/ for current stage.

make: *** [modified] Error 1

```

----------

## cyrius

What is the version of your kernel ?

To know it : 

Can you post the result of this command  

```

emerge --info

```

----------

## cyrius

Ooups, sorry, an error of mine :

 Don't use ipw3945 as it is deprecated.

 Use iwlwifi (Just replace what i said on ipw3945 with iwlwifi).

You should use the last version of gentoo-sources (2.6.23-r5).

----------

## cyrius

I have a question for JeliJami just to have an opinion.

Do you understand why there is a iwlwifi ebuild and no mac80211 one ?

Cause, i always saw in my module list : mac80211 and iwl4965.

I never saw iwlwifi module in lsmod or in /lib/module   :Shocked: 

I suppose, then, that the iwlwifi ebuild is not enough.

What is your opinion on it ?

----------

## JeliJami

 *cyrius wrote:*   

> Do you understand why there is a iwlwifi ebuild and no mac80211 one ?

 

The mac80211 code of the kernel is used, I guess.

 *cyrius wrote:*   

> Cause, i always saw in my module list : mac80211 and iwl4965.
> 
> I never saw iwlwifi module in lsmod or in /lib/module  
> 
> 

 

You can still build mac80211 as a module.

The iwlwifi ebuild can build the iwl3945 and the iwl4965 modules. On my system:

```
$ /sbin/lsmod | grep "iwl\|80211"

iwl3945                80436  0 

firmware_class          9024  1 iwl3945

mac80211              137796  1 iwl3945

cfg80211                6800  1 mac80211

```

Use USE flags to only build one of the two:

```
$ emerge -pv iwlwifi

[ebuild   R   ] net-wireless/iwlwifi-1.1.21-r1  USE="ipw3945 -ipw4965" 318 kB

```

 *cyrius wrote:*   

> I suppose, then, that the iwlwifi ebuild is not enough.
> 
> What is your opinion on it ?

 

Just my opinion  :Smile: 

----------

## bebobero

It worked I recompiled my kernel with support and IEEE and the switch Led flashed and when doing iwconfig it found eth1as a wireless device and it worked

i installed network manager as i have gnome but i have the following problem:

The NM-applet in the tray only appears after plugging the ethernet port, also If i remove the Ethernet cable the Small icon on the tray disappears and i can't associate with WIFI access point

Best regards,

BeboBero

----------

## cyrius

I'm happy you successed.

I'm afraid i could not help you anymore cause i'm using KDE which is more stable, only from my point of view, than gnome.

----------

## bebobero

ok how to use wireless-tools  i use wep key 10 digits hex on key index1 what settings do i need to do

----------

## cyrius

have a look to : http://gentoo-wiki.com/Special:Search?search=wireless&go=Go  :Very Happy: 

----------

## bebobero

Ok now i have Installed WPA_Supplicant successfuly and When running wpa_cli i get Associated to XXXXXX Network.

The problem is i don't get an IP and even static Ip doesnot work!

All i find on ifconfig is 169.254.x.x Any help?

Best Regards,

BeboBero

----------

## cyrius

This range is automatically associated when no static ip address is configurated for your interface and no dhcp exists. 

In KDE, that's simple to manage via the configuration center. Good luck with gnome, i'm not enough familiar with it.

This is the low level procedure ( as you should read more about gnome and configure it to support wireless with use flags):

You have a problem in your /etc/init.d/ or in your /etc/conf.d/net file.

if it doesn't exist copy the /etc/conf.d/net.example on /etc/conf.d/net

Have look in /etc/init.d to find your net.eth0 or net.wlan0 (net.yyy where yyy is the interface found in ifconfig -a)

if it doesn't exist, copy /etc/init.d/net.lo on /etc/init.d/net.yyy (see the means of yyy just before)

To configure wireless, use the /etc/conf.d/net file. Not anymore wireless.example. But you still can have look to this one to take the parameters you want in your /etc/conf.d/net file.

You must have a normal configuration for your wireless related to your interface : 

```

config_wlan0=( "dhcp" ) 
```

             or 

```

config_wlan0=("192.168.1.21 broadcast 192.168.1.255 netmask 255.255.255.0")

route_wlan0=( "default via 192.168.1.10" )
```

And you must have a configuration related your essid too (Which i suppose it's already done)

After that, as it's mentionned in the installation documentation of gentoo, configure your resolv.conf

Hope it helps.

----------

