I'm using linux kernel 3.3 (I cannot upgrade my kernel, sorry!) and am trying to use the
utility to monitor the status of my WiFi connection. I'm using an Edimax WiFi dongle to connect to a wireless access point.
I expect to see something like this:
# wpa_cli status
Selected interface 'wlan0'
Or the same thing but with
, depending upon my connection status.
Parsing the this text output allows me to see if my wireless connection is active or scanning. However, I have noticed that after powering off my access point
is still being returned. Using the command:
# iwlist wlan0 scanning
Forces a scan and
will occasionally be correct, but usually (99%) not.
Here is my
After some investigation, I believe something weird is happening causing the kernel to return a cached version of the AP list. I am using the
driver. I've already looked at this issue
, and it is not the same as mine.
My belief is that the issue may be somewhere in the kernel. In the file
, at line 214 in function
, I see a
of my AP appear (when AP has power) and get put via
). At this point, it is returned in scan results and
layer in the kernel to authenticate and connect with that AP. However, after disconnecting AP power, I never see the
layer relinquish it's
hold on that
. This causes the
to never to unlinked in the function
at the end of a scan (
), in file
, line 205 (here
Specifically, I would like to know why the atomic used to "hold" a
is not decremented on power removal from the AP - causing linux to miss sufficient beacons for a disconnect? Or, is there some configuration with wpa_supplicant I need to add to have the
kernel layer decrement it's hold on the
, or is this clearly a kernel bug?
I've already tried:
# wpa_cli bss_expire_age 10
# wpa_cli bss_expire_count 2
and have not resolved my issue.