2013-09-15 08:20:16

by Olivier Reuland

[permalink] [raw]
Subject: Re: RTL8192CU continually reconnecting

Hi,

I'm facing the same issue with a slightly different device: "ID 0b05:17ab
ASUSTek Computer, Inc. USB-N13 802.11n Network Adapter (rev. B1) [Realtek
RTL8192CU]". I'm also using Ubuntu, Saucy: "Linux desktop 3.11.0-7-generic
#13-Ubuntu SMP Tue Sep 10 20:55:38 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux".

Sep 15 19:59:07 desktop NetworkManager[791]: <info> Config: added 'ssid'
value 'MyWiFi'
Sep 15 19:59:07 desktop NetworkManager[791]: <info> Config: added
'scan_ssid' value '1'
Sep 15 19:59:07 desktop NetworkManager[791]: <info> Config: added 'key_mgmt'
value 'WPA-PSK'
Sep 15 19:59:07 desktop NetworkManager[791]: <info> Config: added 'psk'
value '<omitted>'


Disconnect/reconnect cycle every 20-30 seconds.
Disconnect to fail every few minutes.

Sep 15 20:07:18 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:07:19 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> completed
Sep 15 20:07:50 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: completed -> disconnected
Sep 15 20:07:50 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:07:50 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:07:50 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> associating
Sep 15 20:07:51 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associating -> associated
Sep 15 20:07:51 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:07:52 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> completed
Sep 15 20:08:02 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: completed -> disconnected
Sep 15 20:08:02 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:08:02 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:08:03 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> disconnected
Sep 15 20:08:03 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:08:04 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:08:04 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> associating
Sep 15 20:08:04 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associating -> associated
Sep 15 20:08:04 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:08:16 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> disconnected
Sep 15 20:08:16 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> inactive
[FAILED JUST HERE]
Sep 15 20:08:29 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: inactive -> scanning
Sep 15 20:08:29 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:08:30 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> associating
Sep 15 20:08:30 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associating -> associated
Sep 15 20:08:30 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:08:30 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> completed
Sep 15 20:09:06 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: completed -> disconnected
Sep 15 20:09:06 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:09:07 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:09:07 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> associating
Sep 15 20:09:07 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associating -> associated
Sep 15 20:09:07 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:09:07 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> completed
Sep 15 20:09:26 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: completed -> disconnected
Sep 15 20:09:26 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:09:27 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:09:27 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> disconnected
Sep 15 20:09:27 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:09:28 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:09:28 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> disconnected
Sep 15 20:09:28 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:09:35 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:09:35 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> associating
Sep 15 20:09:35 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associating -> associated
Sep 15 20:09:35 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:09:35 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> completed
Sep 15 20:09:42 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: completed -> disconnected
Sep 15 20:09:42 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:09:43 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:09:43 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> disconnected
Sep 15 20:09:43 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:09:44 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:09:44 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> associating
Sep 15 20:09:44 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associating -> associated
Sep 15 20:09:44 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:09:44 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> completed
Sep 15 20:09:58 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: completed -> disconnected
Sep 15 20:09:58 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:09:59 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:09:59 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> disconnected
Sep 15 20:09:59 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:10:00 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:10:00 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> associating
Sep 15 20:10:00 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associating -> associated
Sep 15 20:10:00 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:10:00 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> completed
Sep 15 20:10:16 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: completed -> disconnected
Sep 15 20:10:16 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:10:17 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:10:17 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> disconnected
Sep 15 20:10:17 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> scanning
Sep 15 20:10:24 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: scanning -> authenticating
Sep 15 20:10:24 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: authenticating -> associating
Sep 15 20:10:24 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associating -> associated
Sep 15 20:10:24 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: associated -> 4-way handshake
Sep 15 20:10:30 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> disconnected
Sep 15 20:10:30 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: disconnected -> inactive
[FAILS AGAIN HERE]


The interesting part is probably:
Sep 15 20:10:30 desktop kernel: [ 4778.434695] wlan0: Connection to AP
9c:c7:a6:1c:dc:a5 lost
Sep 15 20:10:30 desktop wpa_supplicant[6415]: wlan0: WPA: 4-Way Handshake
failed - pre-shared key may be incorrect
Sep 15 20:10:30 desktop wpa_supplicant[6415]: wlan0: CTRL-EVENT-DISCONNECTED
bssid=9c:c7:a6:1c:dc:a5 reason=4
Sep 15 20:10:30 desktop kernel: [ 4778.454580] cfg80211: Calling CRDA to
update world regulatory domain
Sep 15 20:10:30 desktop NetworkManager[791]: <info> (wlan0): supplicant
interface state: 4-way handshake -> disconnected
Sep 15 20:10:30 desktop NetworkManager[791]: <info> Activation
(wlan0/wireless): disconnected during association, asking for new key.
Sep 15 20:10:30 desktop NetworkManager[791]: <info> (wlan0): device state
change: activated -> need-auth (reason 'supplicant-disconnect') [100 60 8]




Let me know if there is anything I can do to help

Olivier







2013-09-15 20:26:38

by Larry Finger

[permalink] [raw]
Subject: Re: RTL8192CU continually reconnecting

On 09/15/2013 12:48 PM, Mark Cave-Ayland wrote:
> On 15/09/13 14:50, Larry Finger wrote:
>
>> There is a known problem with the dynamic power management code for this
>> chip. Unfortunately, the problem does not affect my system. At the
>> moment, my device that uses rtl8192cu has been connected for 12 hours
>> with no disconnects. The only evidence of a bug here is poor performance.
>
> Did my email to the list yesterday provide any further clues at all? I know that
> you're looking at re-working the power code, but if there is any chance of a
> stop-gap fix for 3.12 then I know it would be greatly appreciated :)

Yes, you provided some clues, but as I have no knowledge of the internal
workings of the chips, I dare not set parameters willy-nilly as that might cause
chips to burn out and fail.

The vendor driver provides better performance for my device than does rtl8192cu.
I would provide the patches needed to compile it on a modern kernel; however, it
causes a kernel panic whenever you try to unload it. I have no time nor
inclination to debug that. Thus no one should use it unless you want to fix that
problem.

I am trying to change the in-kernel dm code to match the vendor driver. That is
difficult as nearly every variable is renamed.

Any patches will be pushed when they are ready, and not before. I will, however,
provide them for testing. It remains to be seen if any such patches will be
suitable for 3.12 and backporting to 3.11.

Larry



2013-09-15 13:50:56

by Larry Finger

[permalink] [raw]
Subject: Re: RTL8192CU continually reconnecting

On 09/15/2013 03:17 AM, Olivier Reuland wrote:
> Hi,
>
> I'm facing the same issue with a slightly different device: "ID 0b05:17ab
> ASUSTek Computer, Inc. USB-N13 802.11n Network Adapter (rev. B1) [Realtek
> RTL8192CU]". I'm also using Ubuntu, Saucy: "Linux desktop 3.11.0-7-generic
> #13-Ubuntu SMP Tue Sep 10 20:55:38 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux".

--snip--

>
> Let me know if there is anything I can do to help

There is a known problem with the dynamic power management code for this chip.
Unfortunately, the problem does not affect my system. At the moment, my device
that uses rtl8192cu has been connected for 12 hours with no disconnects. The
only evidence of a bug here is poor performance.

Please describe your setup. What AP are you using? Is it an 802.11n or an
802.11g connection? How far is your station from the AP? Are there any obstacles
such as walls in the way? What is the signal strength as shown by iwconfig?

Larry


2013-09-15 17:49:04

by Mark Cave-Ayland

[permalink] [raw]
Subject: Re: RTL8192CU continually reconnecting

On 15/09/13 14:50, Larry Finger wrote:

> There is a known problem with the dynamic power management code for this
> chip. Unfortunately, the problem does not affect my system. At the
> moment, my device that uses rtl8192cu has been connected for 12 hours
> with no disconnects. The only evidence of a bug here is poor performance.

Did my email to the list yesterday provide any further clues at all? I
know that you're looking at re-working the power code, but if there is
any chance of a stop-gap fix for 3.12 then I know it would be greatly
appreciated :)


ATB,

Mark.