Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cannot bring interface up #2

Closed
AleXoundOS opened this issue May 1, 2020 · 20 comments
Closed

cannot bring interface up #2

AleXoundOS opened this issue May 1, 2020 · 20 comments

Comments

@AleXoundOS
Copy link

AleXoundOS commented May 1, 2020

# ip link set wlp0s20f0u3 up
RTNETLINK answers: Operation not permitted

# ip link | grep -A2 wlp0s20f0u3
5: wlp0s20f0u3: <BROADCAST,MULTICAST> mtu 1500 qdisc noop state DOWN mode DEFAULT group default qlen 1000
    link/ether 50:2b:73:d5:57:d1 brd ff:ff:ff:ff:ff:ff

# iwconfig 2>&1 | grep -A8 wlp0s20f0u3
wlp0s20f0u3  unassociated  Nickname:"<WIFI@REALTEK>"
          Mode:Auto  Frequency=2.412 GHz  Access Point: Not-Associated   
          Sensitivity:0/0  
          Retry:off   RTS thr:off   Fragment thr:off
          Encryption key:off
          Power Management:off
          Link Quality:0  Signal level:0  Noise level:0
          Rx invalid nwid:0  Rx invalid crypt:0  Rx invalid frag:0
          Tx excessive retries:0  Invalid misc:0   Missed beacon:0

dmesg logs:

  1. # insmod 8188gu.ko
  2. adapter usb insert
  3. # ip link set wlp0s20f0u3 up
    Notably:
    2020-05-01T21:55:48,275715+03:00 RTW: rtl8710b_FirmwareDownload: Error! No shift for fw header! 10b1
    2020-05-01T21:55:48,275743+03:00 RTW: rtl8710b_FirmwareDownload by IO write!
    2020-05-01T21:55:48,524054+03:00 RTW: polling_fwdl_chksum: Checksum report Fail! (247, 10ms), REG_MCUFWDL:0x01050101
    2020-05-01T21:55:48,782042+03:00 RTW: polling_fwdl_chksum: Checksum report Fail! (230, 10ms), REG_MCUFWDL:0x01050101
    2020-05-01T21:55:49,040025+03:00 RTW: polling_fwdl_chksum: Checksum report Fail! (242, 10ms), REG_MCUFWDL:0x01050101
    2020-05-01T21:55:49,297998+03:00 RTW: polling_fwdl_chksum: Checksum report Fail! (243, 10ms), REG_MCUFWDL:0x01050101
    2020-05-01T21:55:49,555987+03:00 RTW: polling_fwdl_chksum: Checksum report Fail! (242, 10ms), REG_MCUFWDL:0x01050101
    2020-05-01T21:55:49,566228+03:00 RTW: DUMP REG 0x90=0x1000105 
    2020-05-01T21:55:49,566228+03:00 RTW: ERROR Dump FW page 0x1000 ~ 0x10FF :
    

@lwfinger
Copy link
Owner

lwfinger commented May 2, 2020

Do another git pull. I discovered that I missed updating some file, and I added some debugging output. If it fails the same way, send me the output of the lines that start with *****.

@AleXoundOS
Copy link
Author

@lwfinger, the latest commit is still 891c425 at the moment.

@lwfinger
Copy link
Owner

lwfinger commented May 2, 2020

I forgot to push. Try it now.

@AleXoundOS
Copy link
Author

AleXoundOS commented May 2, 2020

# ip link set wlp0s20f0u3 up
RTNETLINK answers: Operation not permitted

dmesg after asterisks.


Driver commit: 8483b4f.

@lwfinger
Copy link
Owner

lwfinger commented May 2, 2020

The code says that when the vendor ID is 1, the firmware should have signature 10B1, and when the vendor code is 2, the signature should be 10B2. For those cases, a 32-byte header is removed. Your device has vendor ID of 2, but the firmware signature is 10B1, thus no header is removed, and you get the error printout. To me, it looks as though there is a header present, thus I have pushed (I really did) a version that unconditionally removes a header.

One question: Is your computer running x86_64?

@AleXoundOS
Copy link
Author

AleXoundOS commented May 2, 2020

I have pushed (I really did) a version that unconditionally removes a header

# ip link set wlp0s20f0u3 up
RTNETLINK answers: Operation not permitted

dmesg logs:

  1. insmod
  2. usb insert
  3. ip link up

Driver commit: 03e81cf.


Is your computer running x86_64?

Yes.

# uname -srvmo
Linux 4.19.84 #1-NixOS SMP Tue Nov 12 18:21:46 UTC 2019 x86_64 GNU/Linux

@lwfinger
Copy link
Owner

lwfinger commented May 3, 2020

This kind of debugging is very slow. I pushed another test printout. Would it be possible to access your computer via ssh, or using Teamviewer?

I only need dmesg after "ip link up".

@AleXoundOS
Copy link
Author

AleXoundOS commented May 3, 2020

dmesg: ip link up.

Commit: e7d5cd0.

@AleXoundOS
Copy link
Author

Would it be possible to access your computer via ssh, or using Teamviewer?

It's not easy but I'll try to provide something. I will contact you privately via email.

@lwfinger
Copy link
Owner

lwfinger commented May 3, 2020

I'm starting to get the feeling that the RTL8710BU driver will never work for this device. Realtek may have reused the USB ID, which is a bad thing to do.

Just in case the original driver I tried will work, I added it to the repo in branch rtl8188gu. Do the following:

git checkout origin/rtl8188gu -b rtl8188gu

Make that one and try it. If it fails, please post the entire dmesg.

I have also written to Tenda to see if they have a driver, despite not listing it on their web site.

@AleXoundOS
Copy link
Author

AleXoundOS commented May 3, 2020

git checkout origin/rtl8188gu -b rtl8188gu
Make that one and try it. If it fails, please post the entire dmesg.

Fails. Interface is not created. Tested on a different machine, but I don't think it matters.
dmesg-rtl8188gtv.txt.

I have also written to Tenda to see if they have a driver, despite not listing it on their web site.

Thank you.

@lwfinger
Copy link
Owner

lwfinger commented May 3, 2020

It does not matter. That one failed to read the EFUSE, thus it is not correct either.

Trying to make either of these drivers work is not likely to work, plus my contact at Realtek does not have any others available to him.

I thing we need to pause this project until/if I hear from Tenda.

@lwfinger lwfinger closed this as completed May 3, 2020
@lwfinger
Copy link
Owner

lwfinger commented May 6, 2020

The Tenda E-mail could not be delivered. I guess we are at a dead end. There may not be a Linux driver for this device.

@AleXoundOS
Copy link
Author

@lwfinger, but how come initially you received the driver with the rtl8188gu name? Maybe the same sender has the correct rtl8188gu driver (instead of rtl8188gtv)?

@lwfinger
Copy link
Owner

lwfinger commented May 7, 2020

No, I got what he has. If you look at the "Free Driver" versions listed on E-Bay, such as https://www.ebay.com/itm/NEW-Realtek-RTL8188GU-USB-WiFi-802-11b-g-n-Adapter-Mini-Wireless-Network-Dongle/233273662203?hash=item3650319afb:g:gUsAAOSwiZddFx2k, they only list drivers for Windows. Nothing for Linux or MacOS. I do not believe that there is a Linux driver for this device.

To find out, I just ordered one of those, which I should receive by mid June. Then we will know for sure. Those are dual devices - a USB storage device and a wifi device. You use modeswitch to change.

@AleXoundOS
Copy link
Author

@lwfinger, following the link, there is:

Specifications
Chipset:Realtek RTL8188GU
Interface:USB2.0 Hi-Speed connector
Wireless Speed:11n:Up to 150Mbps
Frequency Range:2.4-2.4835GHz
Wireless Transmit Power:20dBm(MAXEIRP)
Modulation Technique:OFDM/CCK/16-QAM/64-QAM
Work Mod:Ad-Hoc/Infrastructure
Wireless Security:64/128bitsWEP,WPA/WPA2,WPA-PSK/WPA2-PSK(TKIP/AES)
Temperature Range:Operating:-20ºCto70ºC, Storage:-40ºCto90ºC
Humidity:Operating:5%to95%(non-condensing), Storage:Max.90%(non-condensing)
Support Operating System:WindowsXP/Vista/Linnux/Win7/Win8/Win8.1/Win10
Dimensions(HxWxD):15x21x6.5mm

  • Chipset:Realtek RTL8188GU
  • Support Operating System:WindowsXP/Vista/Linnux/Win7/Win8/Win8.1/Win10
    (perhaps, double n confused your search)

Those are dual devices - a USB storage device and a wifi device. You use modeswitch to change.

In fact I do modeswitch for my Tenda W311MI v3. Otherwise, it appears as 0bda:1a2b.

@lwfinger
Copy link
Owner

lwfinger commented May 7, 2020

What is on the USB edrive part of the device? Send me a directory listing.

@AleXoundOS
Copy link
Author

AleXoundOS commented May 8, 2020

$ sudo mount /dev/sr0 /media/misc/; find /media/misc
mount: /media/misc: WARNING: device write-protected, mounted read-only.
/media/misc
/media/misc/Autorun.inf
/media/misc/Setup.exe

There is also a bunch of errors in dmesg until usb_modeswitch is run:

2020-05-07T05:35:02,188773+03:00 scsi 2:0:0:0: CD-ROM            Realtek  USB Disk autorun 1.00 PQ: 0 ANSI: 0 CCS
2020-05-07T05:35:02,210723+03:00 sr 2:0:0:0: [sr0] scsi-1 drive
2020-05-07T05:35:02,210726+03:00 cdrom: Uniform CD-ROM driver Revision: 3.20
2020-05-07T05:35:02,211179+03:00 sr 2:0:0:0: Attached scsi CD-ROM sr0
2020-05-07T05:35:02,235440+03:00 sr 2:0:0:0: [sr0] tag#0 FAILED Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
2020-05-07T05:35:02,235445+03:00 sr 2:0:0:0: [sr0] tag#0 CDB: Read(10) 28 00 00 00 ff fc 00 00 02 00
2020-05-07T05:35:02,235449+03:00 print_req_error: I/O error, dev sr0, sector 262128
2020-05-07T05:35:02,261899+03:00 sr 2:0:0:0: [sr0] tag#0 FAILED Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
2020-05-07T05:35:02,261910+03:00 sr 2:0:0:0: [sr0] tag#0 CDB: Read(10) 28 00 00 00 ff fc 00 00 02 00
2020-05-07T05:35:02,261915+03:00 print_req_error: I/O error, dev sr0, sector 262128
2020-05-07T05:35:02,261931+03:00 Buffer I/O error on dev sr0, logical block 32766, async page read
2020-05-07T05:35:02,266838+03:00 sr 2:0:0:0: [sr0] tag#0 FAILED Result: hostbyte=DID_ERROR driverbyte=DRIVER_OK
2020-05-07T05:35:02,266843+03:00 sr 2:0:0:0: [sr0] tag#0 CDB: Read(10) 28 00 00 00 04 00 00 00 02 00
2020-05-07T05:35:02,266846+03:00 print_req_error: I/O error, dev sr0, sector 4096

The last part repeats until:

2020-05-07T05:35:02,463935+03:00 print_req_error: I/O error, dev sr0, sector 262128
2020-05-07T05:35:02,463942+03:00 Buffer I/O error on dev sr0, logical block 32766, async page read
2020-05-07T05:35:02,493833+03:00 Buffer I/O error on dev sr0, logical block 512, async page read
2020-05-07T05:35:02,564664+03:00 Buffer I/O error on dev sr0, logical block 32576, async page read
2020-05-07T05:35:02,588691+03:00 Buffer I/O error on dev sr0, logical block 512, async page read
2020-05-07T05:35:02,614883+03:00 Buffer I/O error on dev sr0, logical block 32765, async page read
2020-05-07T05:35:04,573921+03:00 usb 1-3: USB disconnect, device number 7

Then the USB device gets found again and the whole process loops infinitely. But, as you see, there is some time window when I can access /dev/sr0.

@lwfinger
Copy link
Owner

lwfinger commented May 8, 2020

I think those files are only for the Windows driver. I see no indication of anything for Linux. The errors indicate a faulty implementation.

@AleXoundOS
Copy link
Author

Unlikely that Linux drivers will (ever?) be embedded on any device.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants