Discussion:
run(4)
(too old to reply)
Robert Swindells
2015-09-12 21:47:40 UTC
Permalink
I have put some diffs to run(4) on ftp.n.o that add support for some
newer Ralink chipsets, they were derived from OpenBSD.

The driver seems to work but I haven't used it all that much and don't
have any documentation for the chips.

<ftp://ftp.NetBSD.org/pub/NetBSD/misc/rjs/run.diff.bz2>

I also put copies of the new firmware images there as we don't have
make rules to build them from microcode.h.

<ftp://ftp.NetBSD.org/pub/NetBSD/misc/rjs/run-fw.tar.bz2>

It would be good if people could also test some adaptors that work with
the driver in the tree with these patches too.

Robert Swindells

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
NONAKA Kimihiro
2015-09-22 13:27:56 UTC
Permalink
Hi,
Post by Robert Swindells
I have put some diffs to run(4) on ftp.n.o that add support for some
newer Ralink chipsets, they were derived from OpenBSD.
I teste your patch with some modified by me.
It works fine to me.

Tested devices
- Buffalo WLI-IC-AG300N
MAC/BBP RT2872 (rev 0x0202), RF RT2850 (MIMO 2T2R)
- Logitec LAN-W450AN/U2
MAC/BBP RT3593 (rev 0x0402), RF RT3053 (MIMO 3T3R)
- Logitec LAN-W300AU/U2
MAC/BBP RT3572 (rev 0x0223), RF RT3052 (MIMO 2T2R)

Patch by me
- restore $NetBSD$
- add some device ID.
- restore non STA mode process.
- fix m_copydata destination address.
- TAB/whitespace fix.

Regards,
--
NONAKA Kimihiro
Robert Swindells
2015-09-22 17:15:19 UTC
Permalink
Post by NONAKA Kimihiro
Post by Robert Swindells
I have put some diffs to run(4) on ftp.n.o that add support for some
newer Ralink chipsets, they were derived from OpenBSD.
I teste your patch with some modified by me.
It works fine to me.
Tested devices
- Buffalo WLI-IC-AG300N
MAC/BBP RT2872 (rev 0x0202), RF RT2850 (MIMO 2T2R)
- Logitec LAN-W450AN/U2
MAC/BBP RT3593 (rev 0x0402), RF RT3053 (MIMO 3T3R)
- Logitec LAN-W300AU/U2
MAC/BBP RT3572 (rev 0x0223), RF RT3052 (MIMO 2T2R)
I tested with
Ralink RT5370 (labelled as B-LINK)
MAC/BBP RT5390 (rev 0x0502), RF RT5370 (MIMO 1T1R)
Post by NONAKA Kimihiro
Patch by me
- fix m_copydata destination address.
In your patch is this:

@@ -2624,7 +2635,7 @@ run_tx(struct run_softc *sc, struct mbuf *m, struct ieee80211_node *ni)
bpf_mtap2(sc->sc_drvbpf, tap, sc->sc_txtap_len, m);
}

- m_copydata(m, 0, m->m_pkthdr.len, (void *)(txwi + txwisize));
+ m_copydata(m, 0, m->m_pkthdr.len, (void *)(txwi + 1));
m_freem(m);

xferlen += sizeof (*txd) + 4;

I don't think this is correct, I agree that my version is wrong too
but your change (reversion) does not take account of the possible
adjustment to txwisize earlier in the same function:

txwisize = sizeof(struct rt2860_txwi);
if (sc->mac_ver == 0x5592)
txwisize += sizeof(uint32_t);

Maybe we need:

m_copydata(m, 0, m->m_pkthdr.let, (uint8_t *)txwi + txwisize)


Robert Swindells


--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
NONAKA Kimihiro
2015-09-22 22:52:26 UTC
Permalink
Hi,
Post by Robert Swindells
I don't think this is correct, I agree that my version is wrong too
but your change (reversion) does not take account of the possible
txwisize = sizeof(struct rt2860_txwi);
if (sc->mac_ver == 0x5592)
txwisize += sizeof(uint32_t);
m_copydata(m, 0, m->m_pkthdr.let, (uint8_t *)txwi + txwisize)
I agree.


Regards,
--
NONAKA Kimihiro

--
Posted automagically by a mail2news gateway at muc.de e.V.
Please direct questions, flames, donations, etc. to news-***@muc.de
Loading...