Module Name: src Committed By: nat Date: Thu Apr 16 17:24:49 UTC 2020
Modified Files: src/sys/dev/ic [phil-wifi]: rtwnreg.h src/sys/dev/usb [phil-wifi]: if_urtwn.c Log Message: Update with 92EU changes from -current. To generate a diff of this commit: cvs rdiff -u -r1.1.8.3 -r1.1.8.4 src/sys/dev/ic/rtwnreg.h cvs rdiff -u -r1.59.2.10 -r1.59.2.11 src/sys/dev/usb/if_urtwn.c Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/sys/dev/ic/rtwnreg.h diff -u src/sys/dev/ic/rtwnreg.h:1.1.8.3 src/sys/dev/ic/rtwnreg.h:1.1.8.4 --- src/sys/dev/ic/rtwnreg.h:1.1.8.3 Mon Apr 13 08:04:22 2020 +++ src/sys/dev/ic/rtwnreg.h Thu Apr 16 17:24:49 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: rtwnreg.h,v 1.1.8.3 2020/04/13 08:04:22 martin Exp $ */ +/* $NetBSD: rtwnreg.h,v 1.1.8.4 2020/04/16 17:24:49 nat Exp $ */ /* $OpenBSD: r92creg.h,v 1.16 2017/09/22 13:41:56 kevlo Exp $ */ /*- @@ -1341,6 +1341,8 @@ struct r92c_rx_desc_usb { #define R92C_RXDW2_PKTCNT_M 0x00ff0000 #define R92C_RXDW2_PKTCNT_S 16 +#define R92E_RXDW2_PKTCNT_M 0x3fc00000 +#define R92E_RXDW2_PKTCNT_S 22 #define R92C_RXDW3_RATE_M 0x0000003f #define R92C_RXDW3_RATE_S 0 Index: src/sys/dev/usb/if_urtwn.c diff -u src/sys/dev/usb/if_urtwn.c:1.59.2.10 src/sys/dev/usb/if_urtwn.c:1.59.2.11 --- src/sys/dev/usb/if_urtwn.c:1.59.2.10 Thu Apr 16 15:33:07 2020 +++ src/sys/dev/usb/if_urtwn.c Thu Apr 16 17:24:49 2020 @@ -1,4 +1,4 @@ -/* $NetBSD: if_urtwn.c,v 1.59.2.10 2020/04/16 15:33:07 nat Exp $ */ +/* $NetBSD: if_urtwn.c,v 1.59.2.11 2020/04/16 17:24:49 nat Exp $ */ /* $OpenBSD: if_urtwn.c,v 1.42 2015/02/10 23:25:46 mpi Exp $ */ /*- @@ -42,7 +42,7 @@ */ #include <sys/cdefs.h> -__KERNEL_RCSID(0, "$NetBSD: if_urtwn.c,v 1.59.2.10 2020/04/16 15:33:07 nat Exp $"); +__KERNEL_RCSID(0, "$NetBSD: if_urtwn.c,v 1.59.2.11 2020/04/16 17:24:49 nat Exp $"); #ifdef _KERNEL_OPT #include "opt_inet.h" @@ -2923,7 +2923,10 @@ urtwn_rxeof(struct usbd_xfer *xfer, void /* Get the number of encapsulated frames. */ stat = (struct r92c_rx_desc_usb *)buf; - npkts = MS(le32toh(stat->rxdw2), R92C_RXDW2_PKTCNT); + if (ISSET(sc->chip, URTWN_CHIP_92EU)) + npkts = MS(le32toh(stat->rxdw2), R92E_RXDW2_PKTCNT); + else + npkts = MS(le32toh(stat->rxdw2), R92C_RXDW2_PKTCNT); DPRINTFN(DBG_RX, ("%s: %s: Rx %d frames in one chunk\n", device_xname(sc->sc_dev), __func__, npkts));