Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Realtek rtl8192 wifi adapter problems
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware
View previous topic :: View next topic  
Author Message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Fri Dec 06, 2013 6:39 pm    Post subject: Realtek rtl8192 wifi adapter problems Reply with quote

My old wifi adapter broke so I needed to get a new one, so I opened up menuconfig and looked at all of the wifi drivers and then went to newegg to purchase a new wifi adapter that was supported by in kernel drivers....

This is the adapter that I chose for it's feature set. Thinking that it was fully supported... It has a realtek 8192cu chipset...
http://www.newegg.com/Product/Product.aspx?Item=N82E16833180079

So I get the adapter home and get it all set up in the kernel and then as it turns out that particular chipset driver requires a firmware to be built with the kernel. No big deal I already do it with the radeon drivers for r600g. So I get the firmware and get that all set up. Long story short it gets near 100% packet loss. It's so bad that most times it won't even connect to the router. Next thing I did was get on google to find a solution for this packet loss problem/ Well, as it turns out I'm not the only one having this problem with this chipset. I've read dozens of forum threads from all across the internet where people that have wifi adapters that use this chipset are reporting exactly the same packet loss problem.

Not once did I find a single person that claimed the in kernel driver was working for them. In every case I found it was the exact same problem.

However I found out that realtek has their own manufacturer driver that is not related at all to the in kernel driver, AND it's even licensed GPLv2. Heres a git repo that has been updated to work with the latest kernels and has some additional bug fixes as well.
https://github.com/dz0ny/rt8192cu

Unfortunately this driver seems to be setting the hardware into a semi-nonfunctional state. Let me try to explain....

Initially it was working flawlessly. Everything was doing exactly what it was supposed to do, but then after a few hours of use it slowed down to a crawl and ping times to my router at 192.168.1.1 was taking over 1000ms each. packet loss was still 0% but it was just so slow that it was unusable. I tried everything I could think of. I rebooted, reloaded the driver, recompiled it. I spent hours trying to figure out what was going wrong. But it came to a point when it was time to just give up on it and reboot back to windows. A few days later I rebooted back to my gentoo install to get some files I needed and to my surprise the wifi was working flawlessly again. But then a few hours later the same slow bandwidth and high ping times returned. Thinking about the problem a bit further I decided to boot back up into windows and then immediately reboot back into gentoo. It worked the wifi was again working as it should... A few hours later it was back to the slow crawl....

It seems the only solution to this problem is to boot into windows and then to reboot into linux, but that's only temporary. Within a few hours it's back to being really slow.

I'm stumped and I really hope I've been able to explain this problem in a way that makes sense. I have no idea what's going on or even how to troubleshoot it. Please HELP!

Thanks in advance guys. Any information you need like logs or whatever just let me know and I'll cooporate in every way I can.

EDIT: The adapter was worth that price even just for the 2 5dbi antennas.
Back to top
View user's profile Send private message
Logicien
Veteran
Veteran


Joined: 16 Sep 2005
Posts: 1555
Location: Montréal

PostPosted: Fri Dec 06, 2013 7:19 pm    Post subject: Reply with quote

It have been interesting to read, not because I like to see people with wireless problems, but because it ask me a question, is free software have some quality criteria? That should be the theme of a post.

A lot of rtl wireless drivers are in the staging branch, written by Larry Finger, but not rtl8192cu.

If you have to reboot from Windows to make wireless work on Linux, it may be because the firmware in use in the flash memory is the one of the Windows driver. You may not use the /lib/firmware/rtlwifi/rtl8192cufw.bin file. So in this case, the Ndiswrapper could be the way to go.

You can try to communicate with Larry Finger at Larry.Finger@lwfinger.net .
_________________
Paul
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Fri Dec 06, 2013 7:38 pm    Post subject: Reply with quote

Thank you for your quick response. The driver that is in the kernel does require a firmware called rtl8192cufw.bin. It's available in the linux-firmware package. But the realtek driver that is from the manufacturer does not need any firmware. It's just the driver...

But I think you'r right that there must be some kind of register or eeprom that is being changed in a way that doesnt work. The windows driver must be resetting the hardware back to a workable configuration I think, which is somehow or another persistent across boots?

I really have no idea. I'm just guessing in the wind right now.

I've never written a single line of code in my life, I don't know anything about programming. Also the manufacturer driver that I am using now was not written by Larry Finger, would it still be wise to contact him directly? Should I file a bug report on kernel.org even though I'm not using the in kernel driver?

EDIT: I'm just not sure what would be appropriate since I'm using the realtek manufacturer driver.
Back to top
View user's profile Send private message
Aiken
Apprentice
Apprentice


Joined: 22 Jan 2003
Posts: 239
Location: Toowoomba/Australia

PostPosted: Fri Dec 06, 2013 9:31 pm    Post subject: Reply with quote

How are you finding the realtek driver? Have a few usb wifi rtl8192cu adaptors. When they work I am happy enough with their performance. The problem is keeping them working. All I have used so far is the kernel driver.

I thought the kernel driver was slowing being fixed. Last time I tried was with a 3.12 kernel. While a bit better than previous kernels it was still not useful long term. Sometimes the rtl8192cu seemed to go for hours and other days the wireless connection would be dead within minutes. No windows on any of the machines to try. Rebooting gets it working again for awhile.
_________________
Beware the grue.
Back to top
View user's profile Send private message
TomWij
Retired Dev
Retired Dev


Joined: 04 Jul 2012
Posts: 1553

PostPosted: Fri Dec 06, 2013 9:40 pm    Post subject: Reply with quote

duby2291 wrote:
Thank you for your quick response. The driver that is in the kernel does require a firmware called rtl8192cufw.bin. It's available in the linux-firmware package. But the realtek driver that is from the manufacturer does not need any firmware. It's just the driver...


I think it is part of the driver on Windows; on Linux, you need to `emerge sys-kernel/linux-firmware` to obtain it. Did you set the module as Y or as M in the kernel config?
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sat Dec 07, 2013 4:07 am    Post subject: Reply with quote

Aiken wrote:
How are you finding the realtek driver? Have a few usb wifi rtl8192cu adaptors. When they work I am happy enough with their performance. The problem is keeping them working. All I have used so far is the kernel driver.

I thought the kernel driver was slowing being fixed. Last time I tried was with a 3.12 kernel. While a bit better than previous kernels it was still not useful long term. Sometimes the rtl8192cu seemed to go for hours and other days the wireless connection would be dead within minutes. No windows on any of the machines to try. Rebooting gets it working again for awhile.


https://github.com/dz0ny/rt8192cu

Try this driver. This is not the driver that was included in the linux kernel. This is the manufacturer driver. It does not require any firmware, just "make all && make install" and then "modprobe rt8192cu" make sure you blacklist the in kernel driver as that won't work at the same time as this one because 2 drivers can;t drive the same hardware at the same time.. Or better yet just build a kernel without that pos driver.

I'm having much better connections with network manager now than I was last night with wicd.
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sat Dec 07, 2013 4:12 am    Post subject: Reply with quote

TomWij wrote:
duby2291 wrote:
Thank you for your quick response. The driver that is in the kernel does require a firmware called rtl8192cufw.bin. It's available in the linux-firmware package. But the realtek driver that is from the manufacturer does not need any firmware. It's just the driver...


I think it is part of the driver on Windows; on Linux, you need to `emerge sys-kernel/linux-firmware` to obtain it. Did you set the module as Y or as M in the kernel config?


Thank you for your response. I did try both ways. It didn't make a difference.

However what I'm using now is not the driver that is included in the kernel, What I'm using is the manufacturers driver, you can find it here in this git repo.
https://github.com/dz0ny/rt8192cu

This driver is licensed gplv2 and does -not- require any firmware at all. Since last night I've switched from using wicd to networkmanager and it seems better. I do still get the slow down issue, but it isnt nearly as bad.
Back to top
View user's profile Send private message
Aiken
Apprentice
Apprentice


Joined: 22 Jan 2003
Posts: 239
Location: Toowoomba/Australia

PostPosted: Sat Dec 07, 2013 4:19 am    Post subject: Reply with quote

I did not mean find as in search for, meant find as in how it is working for you? I know it is not the driver in the kernel. For the moment the machines where I have tried the in kernel driver now have ethernet cable running across the floor to them.

Curious about how is the reliability of the other driver?
_________________
Beware the grue.
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sat Dec 07, 2013 4:24 am    Post subject: Reply with quote

I think what is going on here is that either the manufacturers driver (that I linked to in the above posts) has bugs in its wext interface or that wpa_supplicant has bugs in its wext interface. Either way, whichever one it is, it's broken....

Networkmanager seems to be working fine. I'll have to keep it going and see if this lasts, but so far so good.
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sat Dec 07, 2013 7:48 am    Post subject: Reply with quote

Just an update guys.... Well, even with network manager it slowed down to an unusable speed. pinging the router was between 600ms and over 1000ms..... Unusable....

So I'm stumped again and swtching to networkmanager didnt help after all. Just rebooting gentoo doesnt fix the problem. I have to boot into windows and and then reboot into gentoo.
Back to top
View user's profile Send private message
TomWij
Retired Dev
Retired Dev


Joined: 04 Jul 2012
Posts: 1553

PostPosted: Sat Dec 07, 2013 8:31 am    Post subject: Reply with quote

And what happens if you use the firmware? Because that's the missing piece that your Windows has and your Linux currently doesn't...
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sat Dec 07, 2013 6:04 pm    Post subject: Reply with quote

I don't understand what your asking. This driver doesnt use the firmware. There would be nothing to load it.
Back to top
View user's profile Send private message
TomWij
Retired Dev
Retired Dev


Joined: 04 Jul 2012
Posts: 1553

PostPosted: Sat Dec 07, 2013 6:11 pm    Post subject: Reply with quote

duby2291 wrote:
I don't understand what your asking. This driver doesnt use the firmware. There would be nothing to load it.


Sorry, I am confused; you have previously said:

duby2291 wrote:
The driver that is in the kernel does require a firmware called rtl8192cufw.bin.


I think you need that driver and firmware for the hardware to work properly. Can you correct me where I misunderstood you?
Back to top
View user's profile Send private message
Barvinok
n00b
n00b


Joined: 29 Sep 2013
Posts: 34
Location: Ukraine

PostPosted: Sat Dec 07, 2013 6:55 pm    Post subject: Reply with quote

Not a suggestion, but just a side note.
I have an USB wi-fi dongle based on this rtl8192cu chip, called EDUP (image of it) and the stock linux driver with the firmware you mentioned works relatively well.
By "relatively" I mean that one can't really expect good signal quality from 1/2 inch device with internal (!) antenna. Talking to a stock TP-Link WR743ND from a distance no less than 5 meters is ok. Talking to a power-boosted D-Link DIR330 from a distance of about 10 to 15 meters is also ok. Of course it is less than even builtin wifi cards do, but I consider this as expected performance.
I may be wrong, though.
_________________
Unlike reality, stupidity is inescapable
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sat Dec 07, 2013 11:08 pm    Post subject: Reply with quote

TomWij wrote:
duby2291 wrote:
I don't understand what your asking. This driver doesnt use the firmware. There would be nothing to load it.


Sorry, I am confused; you have previously said:

duby2291 wrote:
The driver that is in the kernel does require a firmware called rtl8192cufw.bin.


I think you need that driver and firmware for the hardware to work properly. Can you correct me where I misunderstood you?


I'm not using the kernels driver. It doesnt work at all. It's completely broken. It's so bad it should be deleted from the kernel immediately.

I'm using the manufacturers driver that was developed by realtek themselves. You can find the source here...
https://github.com/dz0ny/rt8192cu This driver does not use any firmware and is licensed GPLv2.

Just to clarify some things... This hardware has 2 linux drivers.... The in kernel driver and the manufactrer driver. The in kernel driver requires firmware, the manufacturer driver does not. The in kernel driver is called rtl8192. The manufacturer driver is called rt8192cu

rtl8192 is the in kernel driver, it does not work at all. I get 100% packet loss 100% of the time.
rt8192cu is the realtek manufacturer driver, it works for a time, but then after a few hours it slows down so much that it becomes unusable. The fix is to boot into windows, and then to reboot into linux.

I did explain all of this in detail in my first post on this thread. I am sorry that I havent been clear. If you need me to provide any logs or any information I'd be glad to cooperate in any way that I can.


Last edited by duby2291 on Sat Dec 07, 2013 11:24 pm; edited 5 times in total
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sat Dec 07, 2013 11:10 pm    Post subject: Reply with quote

Barvinok wrote:
Not a suggestion, but just a side note.
I have an USB wi-fi dongle based on this rtl8192cu chip, called EDUP (image of it) and the stock linux driver with the firmware you mentioned works relatively well.
By "relatively" I mean that one can't really expect good signal quality from 1/2 inch device with internal (!) antenna. Talking to a stock TP-Link WR743ND from a distance no less than 5 meters is ok. Talking to a power-boosted D-Link DIR330 from a distance of about 10 to 15 meters is also ok. Of course it is less than even builtin wifi cards do, but I consider this as expected performance.
I may be wrong, though.


You are the only person I've heard report that the in kernel driver was working acceptably for them. I've spent the last few days reading forum posts and mailing lists and I havent heard anyone say what you just did.

EDIT: This is my device... http://www.newegg.com/Product/Product.aspx?Item=N82E16833180079

In windows and with the manufacturer driver in linux I'm picking up access points from half a mile away.
Back to top
View user's profile Send private message
Barvinok
n00b
n00b


Joined: 29 Sep 2013
Posts: 34
Location: Ukraine

PostPosted: Sun Dec 08, 2013 12:36 am    Post subject: Reply with quote

duby2291 wrote:
You are the only person I've heard report that the in kernel driver was working acceptably for them. I've spent the last few days reading forum posts and mailing lists and I havent heard anyone say what you just did.

I guess those who had the in-kernel driver working for them didn't bother writing to forums and mailing lists about it :D
I can't be of much help anyway.
Did you enable all debug options for your kernel driver experiments?
On my another laptop I had similar symptoms with b43 wifi driver until it turned out it started to fail electronically.

duby2291 wrote:
The in kernel driver is called rtl8192

something tells me its rtl8192c and rtl8192cu.
then the fact that my little dongle works might be because it's "cu" and not "c" which seems to be your case.
_________________
Unlike reality, stupidity is inescapable


Last edited by Barvinok on Sun Dec 08, 2013 12:42 am; edited 2 times in total
Back to top
View user's profile Send private message
Aiken
Apprentice
Apprentice


Joined: 22 Jan 2003
Posts: 239
Location: Toowoomba/Australia

PostPosted: Sun Dec 08, 2013 12:37 am    Post subject: Reply with quote

The in kernel driver works for me for a short while then dies. It uses /lib/firmware/rtlwifi/rtl8192cufw.bin

The realtek driver does not work for me. It looks to include it's own firmware and not use anything from /lib/firmware. For me this driver loads, wlan0 is created, I can bring it up with ifconfig but it is not a useful interface.

In the source code for the realtek driver rtl8192cfwU.bin is mentioned so for something to do I copied /lib/firmware/rtlwifi/rtl8192cfwU.bin over /lib/firmware/rtlwifi/rtl8192cufw.bin to try that firmware with the kernel driver.
_________________
Beware the grue.
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sun Dec 08, 2013 12:55 am    Post subject: Reply with quote

Barvinok wrote:
duby2291 wrote:
You are the only person I've heard report that the in kernel driver was working acceptably for them. I've spent the last few days reading forum posts and mailing lists and I havent heard anyone say what you just did.

I guess those who had the in-kernel driver working for them didn't bother writing to forums and mailing lists about it :D
I can't be of much help anyway.
Did you enable all debug options for your kernel driver experiments?
On my another laptop I had similar symptoms with b43 wifi driver until it turned out it started to fail electronically.

duby2291 wrote:
The in kernel driver is called rtl8192

something tells me its rtl8192c and rtl8192cu.
then the fact that my little dongle works might be because it's "cu" and not "c" which seems to be your case.


The chipset is 8192cu chip that I have, the kernel driver for that chipset is called rtl8192, the manufacturer driver for that chipset is called rt8192cu. Yeah I do have all debugging options enabled.
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Sun Dec 08, 2013 12:56 am    Post subject: Reply with quote

Aiken wrote:
The in kernel driver works for me for a short while then dies. It uses /lib/firmware/rtlwifi/rtl8192cufw.bin

The realtek driver does not work for me. It looks to include it's own firmware and not use anything from /lib/firmware. For me this driver loads, wlan0 is created, I can bring it up with ifconfig but it is not a useful interface.

In the source code for the realtek driver rtl8192cfwU.bin is mentioned so for something to do I copied /lib/firmware/rtlwifi/rtl8192cfwU.bin over /lib/firmware/rtlwifi/rtl8192cufw.bin to try that firmware with the kernel driver.


Let me know how that works, if it works well for you please let me know I will try that too if all else fails.
Back to top
View user's profile Send private message
Aiken
Apprentice
Apprentice


Joined: 22 Jan 2003
Posts: 239
Location: Toowoomba/Australia

PostPosted: Sun Dec 08, 2013 1:40 am    Post subject: Reply with quote

While trying the other firmware seemed like a good idea at the time the wireless eventually went boom. Once machine has a 3.10.7 kernel and the other 3.12.0 kernel. Both worked for awhile then the wireless went splat. These 2 machines did not seem any different compared to using the normal firmware. A network debian wheezy install on a 3rd machine (don't know the kernel version) did not make it past network setup. Gone back to the normal firmware.

The 3.12.0 machine also has the source for 3.12.3 on it and noticed some changes to the rtlwifi code. Easy enough to do a new kernel for it and when that fails (shows my confidence :? ) suppose try 3.13.

There had been some work on 3.11.x and 3.12.x. Did not try any 3.11 kernel. 3.12.0 has seemed a bit more reliable than 3.10 with the rtl8192cu. Another thing that some people claimed to work for them was load the module with swenc=1 but that did not seem to do much for me.
_________________
Beware the grue.
Back to top
View user's profile Send private message
Aiken
Apprentice
Apprentice


Joined: 22 Jan 2003
Posts: 239
Location: Toowoomba/Australia

PostPosted: Sun Dec 08, 2013 3:02 am    Post subject: Reply with quote

Neither 3.12.3 and 3.13-rc3 are reliable with my rtl8192cu. 3 adaptors on 3 computers and it is the same story on all 3. Work for awhile then nothing. Reboot and they work for awhile .......
_________________
Beware the grue.
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Wed Dec 11, 2013 3:22 am    Post subject: Reply with quote

So I switched to the in kernel driver and I finally managed to get that thing working..... I updated the firmware to the newest version and now it connects reliably and doesnt get 100% packet loss like was....

But.....

It is exhibiting -exactly- the same behavior as the manufacturer driver. After a little while it slows down to an unusable state. Ping times to the router are really high and the connection is too slow to be usable. (and just like with the manufacturer driver, rebooting linux doesnt fix the problem, but booting into windows and then rebooting into linux does)

One important difference though is that the in kernel driver produced an error message in dmesg at the very moment that it slowed down....

Code:
rtl_usb:_rtl_submit_tx_urb():<200-1> Failed to submit urb


I have no idea what that means though, but at the very moment it slowed down, that was error message spit out from dmesg.

Any ideas?
Back to top
View user's profile Send private message
Logicien
Veteran
Veteran


Joined: 16 Sep 2005
Posts: 1555
Location: Montréal

PostPosted: Wed Dec 11, 2013 4:33 am    Post subject: Reply with quote

In my city, a lot of computer stores allow their customers to have their money back for a period of time or exchange their product if they are not satisfy of what they buy.

This possibility is particularly usefull when your are not sure of the Linux compatibility of what you buy. Some stores ever allow me to boot a Linux live-cd on place to check a laptop compatibility for example. I ever brink my laptop with me to test extension devices.

But, most of the time you have to go home to test the product to be sure your are satisfy. So, I use a lot this money back and exchange services with Linux. I can test a lot of things without penalty.

USB wireless adaptors are known to be less reliable than PCI(e) ones. If you need one of it, it can be because your desktop computer do not have a wireles adaptor or your laptop is to old to have an integrated one, even if you say that the old one broke.

I have not been able to make the Ndiswrapper work on 64 bits processors like I did on 32 bits ones. But this is a long time ago. I haven't need it since then. But again it can be a possibility for you to use the Windows driver with Linux.
_________________
Paul
Back to top
View user's profile Send private message
duby2291
Guru
Guru


Joined: 17 Oct 2004
Posts: 583

PostPosted: Wed Dec 11, 2013 5:30 am    Post subject: Reply with quote

I've tried ndiswrapper. It won't install 32bit drivers, 64bit drivers install, but when I modprobe ndiswrapper it kernel panics.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Kernel & Hardware All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum