From: stsp Date: Mon, 14 Mar 2022 14:15:33 +0000 (+0000) Subject: Fix Tx performance on urtwn(4) RTL8192EU devices. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=b5162d813ce25a3984cf6cc9f58fcdb16b00f657;p=openbsd Fix Tx performance on urtwn(4) RTL8192EU devices. The "driver rate" bit which tells firmware to use the driver-provided Tx rate is in a different spot of Tx descriptor double word 3. Fix the corresponding macro definition. The device was sending all frames at CCK1 because of this bug, regardless of the Tx rate the driver had chosen. tcpbench before: Conn: 1 Mbps: 0.808 Peak Mbps: 1.108 Avg Mbps: 0.808 tcpbench with fix: Conn: 1 Mbps: 21.078 Peak Mbps: 21.078 Avg Mbps: 21.078 ok jmatthew@ --- diff --git a/sys/dev/ic/r92creg.h b/sys/dev/ic/r92creg.h index 6a9f79658bd..0ef8996a922 100644 --- a/sys/dev/ic/r92creg.h +++ b/sys/dev/ic/r92creg.h @@ -1,4 +1,4 @@ -/* $OpenBSD: r92creg.h,v 1.25 2020/06/11 00:56:12 jmatthew Exp $ */ +/* $OpenBSD: r92creg.h,v 1.26 2022/03/14 14:15:33 stsp Exp $ */ /*- * Copyright (c) 2010 Damien Bergamini @@ -1620,7 +1620,7 @@ struct r92e_tx_desc_usb { #define R88E_TXDW2_AGGBK 0x00010000 #define R92C_TXDW2_CCX_RPT 0x00080000 -#define R92E_TXDW3_DRVRATE 0x1000 +#define R92E_TXDW3_DRVRATE 0x0100 #define R23A_TXDW3_TXRPTEN 0x4000 #define R92C_TXDW3_HWSEQEN 0x8000