Here is a new patch for the urtwn driver. I basically brought over the
changes committed to NetBSD that enabled hostap mode by merging in what
appeared to be the relevant differences. I also merged in two changes
that looked like they would make monitor mode more useful.

The only
change I added was to revert the beacon config register back to it's
original value when the adapter is switched back to station mode. There
are no comments around that particular call in the NetBSD driver so I'm
not sure if what I did was correct, it just seemed logical.

I think too.

This patch doesn't manually generate a beacon frame using
ieee80211_beacon_alloc so I assume that setting the MSR register using
the appropriate value instructs the chip to handle that in hardware. I
tested this on both my ESXi VM using USB passthru and my raspberry pi 2.
Both appear to work as expected but the connection seemed less stable on
the latter.

Can you check this with tcpdump(1) or dumpcap(1) on the sta side?
(I have seen configurations, where STA's were associated with an AP
without beaconing).

About patch:

+               if (vap->iv_opmode ==IEEE80211_M_HOSTAP) {
...
+                       /* Allow Rx from any BSSID. */
+                       urtwn_write_4(sc, R92C_RCR,
+                           urtwn_read_4(sc, R92C_RCR) &
+                           ~(R92C_RCR_CBSSID_DATA | R92C_RCR_CBSSID_BCN));

Is there any reason for that? (can be useful in ad-hoc mode,
but I'm not sure about hostap).

+                       /* Set appropriate MSR bits */
+                       msr |= R92C_MSR_INFRA;

Probably, R92C_MSR_AP should be used here instead.

Thanks again,

-Matthew
_______________________________________________
freebsd-wireless@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-wireless
To unsubscribe, send any mail to "freebsd-wireless-unsubscr...@freebsd.org"

Reply via email to