# Trying to get WiFi work on Thinkpad T520



## skunk (Apr 22, 2022)

I am having a hard time trying to get WLAN work on the Thinkpad T520 with its Centrino 6300 wifi card using 13.0-RELEASE-p8.

```
# pciconf -lv
<snip>
iwn0@pci0:3:0:0:        class=0x028000 rev=0x3e hdr=0x00 vendor=0x8086 device=0x4238 subvendor=0x8086 subdevice=0x1111
    vendor     = 'Intel Corporation'
device     = 'Centrino Ultimate-N 6300'
class      = network
<snip>
# sysctl net.wlan.devices
net.wlan.devices: iwn0
#
```

/boot/loader.conf :

```
if_iwn_load="YES"
iwnfw_load="YES"
iwn6000fw_load="YES"
#wlan_wep_load="YES"
#wlan_ccmp_load="YES"
#wlan_tkip_load="YES"
```

/etc/rc.conf :

```
wlans_iwn0="wlan0"
ifconfig_wlan0="WPA SYNCDHCP"
create_args_wlan0="country DE"
wpa_supplicant_enable="YES"
```

/etc/wpa_supplicant.conf :

```
country=DE

network={
#       priority=1
#       proto=WPA
ssid="mywifi"
psk="password"
}
```

Whatever I try, _wlan0_ does not appear when looking at `ifconfig`.
On another computer with the Intel 8265 this exact configuration (except for iwm8265fw_load="YES") works just fine.
I suspect there is some firmware problem. With _iwmfw_load_ or specifying particular firmwares, like in the config shown above, I had no success.
(Edit: I tried the 6000, 6000g2a, 6000g2b and 6050 firmwares to no avail. Could it be that the 6300 firmware is missing?)
(Edit 2: How I hate the default vt newcons setting! The font was microscopically small, so I misread "iwn" for "iwm", as it was shown on the 8265, and, thanks to good old sc console on the other computer, readable without microscope. After changing the "iwm" settings to "iwn", the wlan gets associated, but traffic does not work yet.)

Any idea?


----------



## RobvW (Jun 3, 2022)

Unfortunately same problem for me. After upgrading from 13.0 -Release to 13.1-Release my wifi shows these characteristics:

- at home-network, with ssid and WPS-WPA2 identification, functions haphazardly, but if connection and ip via dhcp established after attempting several `doas service netif restart` then ok.
- at work-network which allows connection by MAC address only, ssid, but no password. Can connect and get ip via dhcp, but no nameserver functionality.

This occurred at two laptops after upgrading 13.0 to 13.1. The only difference with the OP is that most of /boot/loader.conf is in /etc/rc.conf, and I use a lagg interface setup to switch between cable/wifi.

SInce everything functionned flawlessly before, the firmware suggestion of the OP might be a realistic one. Any suggestions?


----------



## skunk (Jun 3, 2022)

RobvW said:


> Any suggestions?


Last week I pulled the laptop from the shelf to try again getting it work, continuing from the point where I gave up.
To my big surprise, when I started it up and checked `ifconfig`, `ping google.com` and `firefox`, all worked just fine.

It had the 6050 firmware loading configured( `iwn6050fw_load="YES"` ).
So my feeling is that possibly it might be necessary to do hard power down/up before attempting to load/run different firmwares, not just `reboot`ing.
But right now, this is just a guess.


----------



## grahamperrin@ (Jun 5, 2022)

skunk said:


> … `reboot`ing. …



reboot(8), yes?


vt(4)​


skunk said:


> … newcons setting! The font …



From my loader.conf(5):


```
# <https://old.reddit.com/r/freebsd/comments/m4w2fs/-/gqxf3gn/>
# 12x24 is slightly oversized in normal mode
# screen.font="10x20"
screen.font="8x16"
efi_max_resolution="1600x900"
```

`8x16` suits my current system, YMMV.


----------



## vermaden (Jun 5, 2022)

skunk said:


> I am having a hard time trying to get WLAN work on the Thinkpad T520 with its Centrino 6300 wifi card using 13.0-RELEASE-p8.
> (...)



This may help you:

- https://pbpiece.com/freebsd-cant-find-wifi-hotspot/


----------



## sidetone (Jun 5, 2022)

Are there netmask errors in dmesg or they may only be only visible on the 1st terminal console, CTRL-ALT-F1? Also, see if the problem is only for IPv4. I had this problem, while IPv6 continued to work, which explained why I was able to continue accessing forums.Freebsd.org.

Try setting the IP manually with a netmask, to see if it works, instead of DHCP. Disabling devd could cause DHCPD to stop working. devd should only be disabled for temporary purposes. It was dbus which is the one that people consider disabling on FreeBSD.


----------

