Page MenuHomeFreeBSD

urtwn(4): fix rssi calculation
ClosedPublic

Authored by avos on Oct 5 2015, 9:04 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Dec 9, 10:12 AM
Unknown Object (File)
Thu, Dec 5, 1:09 AM
Unknown Object (File)
Fri, Nov 29, 4:57 PM
Unknown Object (File)
Oct 16 2024, 4:58 AM
Unknown Object (File)
Oct 11 2024, 2:03 PM
Unknown Object (File)
Oct 1 2024, 10:38 AM
Unknown Object (File)
Sep 28 2024, 4:38 AM
Unknown Object (File)
Sep 25 2024, 1:55 AM
Subscribers

Details

Test Plan

Scan results from different devices:
WUSB54GCv1 (rum):
0x00000 00:1a:70:9e:9a:70 1 54M -76:-95 100 EP RSN
wpi0 00:19:d2:01:02:03 1 54M -75:-95 100 ES WME

Intel 3945BG (wpi):
0x00000 00:1a:70:9e:9a:70 1 54M -70:-95 100 EP RSN
rum0 00:1d:7e:01:02:03 7 54M -69:-95 100 ES WME

RTL8188EU (urtwn) (without this patch):
0x00000 00:1a:70:9e:9a:70 1 54M -140:-95 100 EP RSN
wpi0 00:19:d2:01:02:03 1 54M -140:-95 100 ES WME
rum0 00:1d:7e:01:02:03 7 54M -140:-95 100 ES WME

RTL8188EU (urtwn) (with this patch):
0x00000 00:1a:70:9e:9a:70 1 54M -81:-95 100 EP RSN
wpi0 00:19:d2:01:02:03 1 54M -70:-95 100 ES WME
rum0 00:1d:7e:01:02:03 7 54M -64:-95 100 ES WME

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

avos retitled this revision from to urtwn(4): use one procedure for getting rssi for all devices.
avos updated this object.
avos edited the test plan for this revision. (Show Details)
avos added reviewers: adrian, kevlo.
avos set the repository for this revision to rS FreeBSD src repository - subversion.

Ok, so what's the difference between R88 and R92? Like, should the R88 chips be using R92 method, or is the R88 method we have broken?

In D3820#78814, @adrian wrote:

Ok, so what's the difference between R88 and R92? Like, should the R88 chips be using R92 method, or is the R88 method we have broken?

Even if the R88 method is separate & broken - I don't know how to fix it (and R92 method seems to be good enough for R88 chips).

I think, that r88e_rx_cck structure is wrong (for example, sig_qual field contains current channel number + it is here for all frames, not only for CCK)

OK, this way is not correct too. I will fix this soon.

avos retitled this revision from urtwn(4): use one procedure for getting rssi for all devices to urtwn(4): fix rssi calculation.
avos edited the test plan for this revision. (Show Details)
avos edited edge metadata.
  1. The URTWN_RSSI macro in inappropriate here - since urtwn_get_rssi()/urtwn_r88e_get_rssi() returns negative value, in most cases this macro will cause overflow.
  2. As I have said previously, 3rd byte is channel and 4th is always (or not?) zero. After adding two additional fields here, restored urtwn_r88e_get_rssi() call starts producing more realistic values (almost the same as from other NICs).
adrian edited edge metadata.

if kevin is okay with this, then I'm okay!

This revision is now accepted and ready to land.Oct 22 2015, 5:12 PM
kevlo edited edge metadata.
This revision was automatically updated to reflect the committed changes.