aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/realtek/rtl8xxxu/rtl8xxxu_regs.h (follow)
AgeCommit message (Collapse)AuthorFilesLines
2021-10-05rtl8xxxu: Use lower tx rates for the ack packetChris Chiu1-0/+2
According to the Realtek propritary driver and the rtw88 driver, the tx rates of the ack (includes block ack) are initialized with lower tx rates (no HT rates) which is set by the RRSR register value. In real cases, ack rate higher than current tx rate could lead to difficulty for the receiving end to receive management/control frames. The retransmission rate would be higher then expected when the driver is acting as receiver and the RSSI is not good. Cross out higer rates for ack packet before implementing dynamic rrsr configuration like the commit 4830872685f8 ("rtw88: add dynamic rrsr configuration"). Signed-off-by: Chris Chiu <chris.chiu@canonical.com> Acked-by: Jes Sorensen <Jes.Sorensen@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org> Link: https://lore.kernel.org/r/20211001040044.1028708-1-chris.chiu@canonical.com
2019-06-05treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 295Thomas Gleixner1-9/+1
Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of version 2 of the gnu general public license as published by the free software foundation this program is distributed in the hope that it will be useful but without any warranty without even the implied warranty of merchantability or fitness for a particular purpose see the gnu general public license for more details extracted by the scancode license scanner the SPDX license identifier GPL-2.0-only has been chosen to replace the boilerplate/reference in 64 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Alexios Zavras <alexios.zavras@intel.com> Reviewed-by: Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190529141901.894819585@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2017-01-20rtl8xxxu: Update author/maintainer contact infoJes Sorensen1-1/+1
Update copyright year and email address. Signed-off-by: Jes Sorensen <Jes.Sorensen@gmail.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-09-17rtl8xxxu: Implement 8192e specific power down sequenceJes Sorensen1-0/+1
This powers down the 8192e correctly, or at least to the point where the firmware will load again, when reloading the driver module. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-09-03rtl8xxxu: Add interrupt bit definitions for gen2 partsJes Sorensen1-0/+56
These are primarily needed for SDIO/PCI parts, but the vendor driver still sets them for some USB devices. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-09-03rtl8xxxu: Add bit definitions for REG_FPGA0_TX_INFOJes Sorensen1-0/+4
This adds TX antenna selection bit defines for OFDM mode. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-06-29rtl8xxxu: Add additional documentation for RX DMA registersJes Sorensen1-3/+7
This also renames REG_USB_AGG_{TO,TH} to REG_USB_AGG_{TIMEOUT,THRESH} Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-06-29rtl8xxxu: Add bit definitions for REG_USB_SPECIAL_OPTIONJes Sorensen1-0/+4
Documentation for enabling USB aggregation and whether to select interrupt or bulk delivery of interrupt events. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-04-15rtl8xxxu: Update copyright statement to include 2016Jes Sorensen1-1/+1
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-04-15rtl8xxxu: Use descriptive bits for setting RX paths for 1T2R partsJes Sorensen1-0/+4
This reduce the use of magic values a little. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-04-15rtl8xxxu: Implement generic init_queue_reserved_page() functionJes Sorensen1-1/+1
Longer term we should switch all the chips over to use this function instead of the random chip specific ifdef hacks. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-04-14rtl8xxxu: Adjust AFE crystal value on 8192euJes Sorensen1-0/+4
Adjust AFE before enabling PLL on 8192eu, probably also needed for 8723bu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-04-14rtl8xxxu: Implement IQK calibration for 8192euJes Sorensen1-0/+1
8192eu has it's own IQK calibration procedure, and notably uses undocumented RF register 0x56 in the process. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-04-14rtl8xxxu: Implement 8192eu device specific quirksJes Sorensen1-0/+1
Set REG_QUEUE_CTRL and REG_ACLK_MON for 8192eu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-04-14rtl8xxxu: Set REG_USB_HRPWM for 8192euJes Sorensen1-0/+1
The vendor driver set register 0xfe58 REG_USB_HWPWM in it's init sequence for 8192eu. Do the same here. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-04-07rtl8xxxu: Update some register definitionsJes Sorensen1-7/+24
Improve descriptive names of some registers and add some additional registers only found on nextgen chips. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Flush FIFO before powering down devicesJes Sorensen1-0/+2
This should help when reloading the driver for 8723bu devices Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Implement device specific power_off functionJes Sorensen1-0/+2
Implment 8723bu specific device power down, and make power_off() a fileops function. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Use define for REG_PWR_DATA bitsJes Sorensen1-1/+1
Use the bit define rather than hard code the value for REG_PWR_DATA bits. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: RF_T_METER is different on the newer chipsJes Sorensen1-6/+7
Provide RF_T_METER register location for nextgen chips. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Implement init_statistics for 8723buJes Sorensen1-0/+7
Vendor driver implements this for 8723b and 8821 series Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Setup RX aggregationJes Sorensen1-0/+1
This initializes RX DMA aggregation on 8723bu. We should do this for all parts eventually, and also init TX aggregation. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Add REG_DWBCN1_CTRL_8723B defineJes Sorensen1-0/+2
List yet another new register found on the 8723b. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Initialize burst parameters for 8723buJes Sorensen1-1/+4
Implement burst parameter sequence for 8723bu parts. Eventually this should be moved into device specific sections. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Implement 8723bu power on sequenceJes Sorensen1-0/+11
This implements the 8723bu specific power on sequence as it is different from that of the 8723au chips. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Improve 8723bu init codeJes Sorensen1-1/+4
Implement additional init sequence code for the 8723bu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Initial rtl8723bu_init_bt() codeJes Sorensen1-0/+2
This should initialize the antennas on the 8723bu, but so far I am still not receiving anything :( More work is needed. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Initial implementation of rtl8723bu_config_channel()Jes Sorensen1-0/+14
This is a first stab of implementing rtl8723bu_config_channel(). For now this will only do 20MHz channels. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: First stab at adding IQK calibration for 8723bu partsJes Sorensen1-0/+17
The 8723bu also has it's own IQK calibration process. This is similar in flow, but still different enough to warrent it's own implementation, at least for now. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Add a couple of new register definitionsJes Sorensen1-0/+6
This adds some additional register definitions for 8723bu, as well as a bit define for USB RXDMA aggregation in REG_RXDMA_AGG_PG_TH. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Add some missing register definitions for 8723buJes Sorensen1-1/+7
This introduces additional register definitions for newer generation chips. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Init REG_HIMR[01] for 8192eu partsJes Sorensen1-0/+4
The newer generation chips have different interrupt registers. Initialize this correct registers on 8192eu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Kludge to drop incorrect USB OUT EP for 8192EUJes Sorensen1-0/+1
The 8192eu (and some other parts) will report an incorrect USB OUT EP. This tells the chip to drop it - as per the vendor driver. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Add rtl8xxxu_auto_llt_table()Jes Sorensen1-0/+3
Newer chips can auto load the LLT table, it is no longer necessary to build it manually in the driver. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Implment rtl8192eu_power_on()Jes Sorensen1-0/+6
This implements the rtl8192eu power on sequence, and splits it off from the rtl8192cu/rtl8723au power on sequence. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-03-10rtl8xxxu: Identify chip vendors correctlyJes Sorensen1-0/+4
This identifies the chip vendors correctly and also picks the correct firmware for rtl8192eu. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Add missing bit define for REG_APS_FSMCOJes Sorensen1-0/+1
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Document REG_RXFLTMAP registersBruno Randolf1-6/+20
Add comments describing how REG_RXFLTMAP0, REG_RXFLTMAP1 and REG_RXFLTMAP2 work. Signed-off-by: Bruno Randolf <br1@einfach.org> Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Add REG_OFDM0_RX_D_SYNC_PATH definitionsJes Sorensen1-0/+3
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Add mbox extension register definitions for 8723BJes Sorensen1-0/+5
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Add definitions for antenna selection registers for 8723BUJes Sorensen1-0/+4
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Add more RCR bitsJes Sorensen1-1/+10
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Add REG_TX_REPORT_* definesJes Sorensen1-0/+2
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Define SYS_CFG_SW_OFFLOAD_ENJes Sorensen1-0/+1
This is needed for chips with IOL support. Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2016-02-25rtl8xxxu: Add RQPN_[NE]PQ_SHIFT valuesJes Sorensen1-0/+2
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
2015-10-21New driver: rtl8xxxu (mac80211)Jes Sorensen1-0/+981
This is an alternate driver for a number of Realtek WiFi USB devices, including RTL8723AU, RTL8188CU, RTL8188RU, RTL8191CU, and RTL8192CU. It was written from scratch utilizing the Linux mac80211 stack. After spending months cleaning up the vendor provided rtl8723au driver, which comes with it's own 802.11 stack included, I decided to rewrite this driver from the bottom up. Many thanks to Johannes Berg for 802.11 insights and help and Larry Finger for help with the vendor driver. The full git log for the development of this driver can be found here: git git://git.kernel.org/pub/scm/linux/kernel/git/jes/linux.git branch rtl8723au-mac80211 This driver is still under development, but has proven to be very stable for me. It currently supports station mode only. It has support for OFDM and CCK rates. It does lack certain features found in the staging driver, such as power management, AMPDU, and 40MHz channel support. In addition it does not support AD-HOC, AP, and monitor mode support at this point. The driver is known to work with the following devices: Lenovo Yoga (rtl8723au) TP-Link TL-WN823N (rtl8192cu) Etekcity 6R (rtl8188cu) Daffodil LAN03 (rtl8188cu) Alfa AWUS036NHR (rtl8188ru) Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>