Estou tentando construir um módulo do kernel para usar umRalink RT5370Dispositivo USB Wi-Fi, com ID lsusb 148f:5370
. Meu host é um NAS com kernel Linux baseado na versão 2.6.33.2.
Eu baixei as fontes do driver doSite da Mediateke estou praticamente na mesma situação descritaaqui; o módulo do kernel compilado rt5370sta.ko
parece carregar corretamente porque:
[/share/Public/ralink/alt] # insmod rt5370sta.ko
[/share/Public/ralink/alt] # dmesg -c
rtusb init rt2870 --->
=== pAd = f9d70000, size = 511776 ===
<-- RTMPAllocAdapterBlock, Status=0
Efuse Size=0x2d [2d0-2fc]
NVM is EFUSE
usbcore: registered new interface driver rt2870
Mas os problemas começam na hora de montar a interface, em especial aRTUSBBulkReceive: Falha ao enviar Rx URB -22mensagem:
[/share/Public/ralink/alt] # ifconfig ra0 up
[/share/Public/ralink/alt] # dmesg -c
RtmpAsicLoadFirmware: ver 21/21, sum cdf7/cdf7, mac cdf72100
NICLoadFirmware: firmware loaded already
<-- RTMPAllocTxRxRingMemory, Status=0
RTMP_TimerListAdd: add timer obj f9db81c4!
RTMP_TimerListAdd: add timer obj f9db81f0!
RTMP_TimerListAdd: add timer obj f9db821c!
RTMP_TimerListAdd: add timer obj f9db8198!
RTMP_TimerListAdd: add timer obj f9db8114!
RTMP_TimerListAdd: add timer obj f9db8140!
RTMP_TimerListAdd: add timer obj f9d8295c!
RTMP_TimerListAdd: add timer obj f9d71f90!
RTMP_TimerListAdd: add timer obj f9d71fc0!
RTMP_TimerListAdd: add timer obj f9d829f4!
RTMP_TimerListAdd: add timer obj f9d82904!
RTMP_TimerListAdd: add timer obj f9d829c4!
-->RTUSBVenderReset
<--RTUSBVenderReset
Key1Str is Invalid key length(0) or Type(0)
Key2Str is Invalid key length(0) or Type(0)
Key3Str is Invalid key length(0) or Type(0)
Key4Str is Invalid key length(0) or Type(0)
1. Phy Mode = 5
2. Phy Mode = 5
NVM is Efuse and its size =2d[2d0-2fc]
phy mode> Error! The chip does not support 5G band 15!
RTMPSetPhyMode: channel is out of range, use first channel=1
3. Phy Mode = 9
AntCfgInit: primary/secondary ant 0/1
NICInitRT5390RFRegisters: Initialize frequency - EEPROM = 46, RF_R17 = 46
AsicSetRxAnt, switch to main antenna
bAutoTxAgcG = 0
---> InitFrequencyCalibration
InitFrequencyCalibration: frequency offset in the EEPROM = 46
<--- InitFrequencyCalibration
MCS Set = ff 00 00 00 01
RTUSBBulkReceive: Submit Rx URB failed -22
<==== rt28xx_init, Status=0
0x1300 = 00064300
Claro que não digitaliza e oultrapassagenscomece a incrementar:
[/share/Public/ralink/alt] # /usr/local/bin/iwlist ra0 scan
ra0 No scan results
[/share/Public/ralink/alt] # ifconfig ra0
ra0 Link encap:Ethernet HWaddr 1C:BF:XX:XX:XX:XX
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
RX packets:0 errors:0 dropped:0 overruns:1098 frame:1098
TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:1000
RX bytes:0 (0.0 B) TX bytes:3400 (3.3 KiB)
Nesta situação, verificandodmesgnovamente leva a muitos desses-22erros:
[/share/Public/ralink/alt] # dmesg -c
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
CMDTHREAD_RESET_BULK_IN: Submit Rx URB failed(-22), status=0
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
RTUSBBulkOutMLMEPacket: Submit MLME URB failed -22
CMDTHREAD_RESET_BULK_IN: Submit Rx URB failed(-22), status=0
CMDTHREAD_RESET_BULK_IN: Submit Rx URB failed(-22), status=0
Então minha pergunta é: o queRTUSBBulkOutMLMEPacket: Falha no envio do URB do MLME -22significa e como resolvê-lo, se possível? Não consegui encontrar essa informação em lugar nenhum.