# D-Link wireless card: no connection

## somebody422

HI!

I recently installed Gentoo on an old desktop I have. However, I am having problems connecting to LAN using a wireless card.

I have included all of the relevant drivers in the kernel using menuconfig, but still 'ifconfig' shows no interface, and 'lspci -k' does not mark the card with 'driver in use'

Any help at all is appreciated!

The relevant line from lspci -k :

 *Quote:*   

> 03:08.0 Ethernet controller: Qualcomm Atheros AR5212/AR5213 Wireless Network Adapter (rev 01)
> 
>               Subsystem: D-Link System Inc AR5212/AR5213 Wireless Network Adapter

 

----------

## khayyam

 *somebody422 wrote:*   

> 
> 
> ```
> 03:08.0 Ethernet controller: Qualcomm Atheros AR5212/AR5213 Wireless Network Adapter (rev 01)
> 
> ...

 

somebody422 ... the driver is ath5k, check its enabled in the kernel and the module(s) loaded:

```
# awk '/(_ATH5K|WEXT|(MAC|CFG|NL)80211)/' /usr/src/linux/.config

CONFIG_WEXT_CORE=y

CONFIG_WEXT_PROC=y

CONFIG_CFG80211=m

# CONFIG_NL80211_TESTMODE is not set

# CONFIG_CFG80211_DEVELOPER_WARNINGS is not set

# CONFIG_CFG80211_REG_DEBUG is not set

CONFIG_CFG80211_DEFAULT_PS=y

# CONFIG_CFG80211_INTERNAL_REGDB is not set

CONFIG_CFG80211_WEXT=y

CONFIG_MAC80211=m

CONFIG_MAC80211_HAS_RC=y

CONFIG_MAC80211_RC_MINSTREL=y

CONFIG_MAC80211_RC_MINSTREL_HT=y

CONFIG_MAC80211_RC_DEFAULT_MINSTREL=y

CONFIG_MAC80211_RC_DEFAULT="minstrel_ht"

# CONFIG_MAC80211_MESH is not set

CONFIG_MAC80211_LEDS=y

# CONFIG_MAC80211_MESSAGE_TRACING is not set

# CONFIG_MAC80211_DEBUG_MENU is not set

# CONFIG_MAC80211_HWSIM is not set

CONFIG_ATH5K=m

# CONFIG_ATH5K_DEBUG is not set

CONFIG_ATH5K_PCI=y
```

HTH & best ... khay

----------

## somebody422

The result gave me this:

```

CONFIG_WEXT_CORE=y

CONFIG_WEXT_PROC=y

CONFIG_CFG80211=y

# CONFIG_NL80211_TESTMODE is not set

# CONFIG_CFG80211_DEVELOPER_WARNINGS is not set

# CONFIG_CFG80211_REG_DEBUG is not set

CONFIG_CFG80211_DEFAULT_PS=y

# CONFIG_CFG80211_DEBUGFS is not set

# CONFIG_CFG80211_INTERNAL_REGDB is not set

CONFIG_CFG80211_CRDA_SUPPORT=y

CONFIG_CFG80211_WEXT=y

CONFIG_MAC80211=y

CONFIG_MAC80211_HAS_RC=y

CONFIG_MAC80211_RC_MINSTREL=y

CONFIG_MAC80211_RC_MINSTREL_HT=y

# CONFIG_MAC80211_RC_MINSTREL_VHT is not set

CONFIG_MAC80211_RC_DEFAULT_MINSTREL=y

CONFIG_MAC80211_RC_DEFAULT="minstrel_ht"

# CONFIG_MAC80211_MESH is not set

CONFIG_MAC80211_LEDS=y

# CONFIG_MAC80211_DEBUGFS is not set

# CONFIG_MAC80211_MESSAGE_TRACING is not set

# CONFIG_MAC80211_DEBUG_MENU is not set

CONFIG_MAC80211_STA_HASH_MAX_SIZE=0

# CONFIG_MAC80211_HWSIM is not set

CONFIG_ATH5K=m

CONFIG_ATH5K_DEBUG=y

CONFIG_ATH5K_TRACER=y

CONFIG_ATH5K_PCI=y

```

All looks well

I then run 'make', 'make modules_install', and 'make_install' to compile and install the modules and new kernel. However I am still having the same problem as before.   :Sad: 

----------

## khayyam

 *somebody422 wrote:*   

> I then run 'make', 'make modules_install', and 'make_install' to compile and install the modules and new kernel. However I am still having the same problem as before.  :(

 

somebody422 ... there isn't a 'make_install', and should you run 'make install', and have /boot as a seperate partition (which isn't mounted at the time), then you will not be installing, and so booting, that particular kernel. Please check that you are actually booting this rebuilt kernel. If you are, then check that the module is loaded (via 'lsmod'), and that 'ip a' shows the interface being available.

best ... khay

----------

## somebody422

*facepalm* I wasn't mounting to /boot. Well I did that this time and rebuild/installed the kernel but with the same result. Also i did use 'make install' not 'make_install' that was a typo in my post.

'lsmod' listed no modules at all. 'ip a' output:

```

1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default

link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00

    inet 127.0.0.1/8 brd 127.255.255.255 scope host lo

       valid_lft forever preferred_lft forever

    inet6 ::1/128 scope host

       valid_lft forever preferred_lft forever

2: enp3s8: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast state DOWN group default qlen 1000

    link/ether 00:13:20:ea:c3:7c brd ff:ff:ff:ff:ff:ff

3: sit0@NONE: <NOARP> mtu 1480 qdisc noop state DOWN group default

    link/sit 0.0.0.0 brd 0.0.0.0

```

How can I confirm I am booting the new kernel?

----------

## khayyam

 *somebody422 wrote:*   

> 'lsmod' listed no modules at all.

 

somebody422 ... that isn't typical, unless your .config is all =y. Are you sure you ran 'make modules_install', and have 'modules' in the 'boot' runlevel?

```
# ls -ld /lib/modules/$(uname -r)

drwxr-xr-x 3 root root 4096 2016-05-30 17:06 /lib/modules/3.12.60-ck/

# rc-status boot | tr -s ' ' | grep modules

modules [ started ]
```

... also make sure that 'eselect kernel list' shows linux-$(uname -r) as selected (denoted by '*').

 *somebody422 wrote:*   

> How can I confirm I am booting the new kernel?

 

```
# uname -a

Linux aporia 3.12.60-ck #1 SMP PREEMPT Mon May 30 17:05:32 CEST 2016 i686 Genuine Intel(R) CPU T2500 @ 2.00GHz GenuineIntel GNU/Linux

# cat /usr/src/linux-$(uname -r)/.version

1
```

The '#{n}' and '.version' should correspond.

best ... khay

----------

## somebody422

'uname -r' gives me

```
4.1.15-gentoo-r1
```

while my selected kernel in eselect is 4.4.6. Also, my /usr/src/linux directory which I am building from is 4.4.6. Could this be the problem?

----------

## khayyam

 *somebody422 wrote:*   

> 'uname -r' gives me 4.1.15-gentoo-r1 while my selected kernel in eselect is 4.4.6. Also, my /usr/src/linux directory which I am building from is 4.4.6. Could this be the problem?

 

somebody422 ... undoubtedly ... you are booting a different kernel to the one in which you're enabling the module(s).

best ... khay

----------

## somebody422

I added the kernel by updating the config file using 'grub2-mkconfig' and now I can boot the new kernel! Thank you so much for your help!!

----------

