1 /* SPDX-License-Identifier: GPL-2.0 */ 2 /****************************************************************************** 3 * 4 * Copyright(c) 2007 - 2017 Realtek Corporation. 5 * 6 * This program is free software; you can redistribute it and/or modify it 7 * under the terms of version 2 of the GNU General Public License as 8 * published by the Free Software Foundation. 9 * 10 * This program is distributed in the hope that it will be useful, but WITHOUT 11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 13 * more details. 14 * 15 *****************************************************************************/ 16 #ifndef __RTL8710B_SPEC_H__ 17 #define __RTL8710B_SPEC_H__ 18 19 #include <drv_conf.h> 20 21 22 #define HAL_NAV_UPPER_UNIT_8710B 128 /* micro-second */ 23 24 /* ----------------------------------------------------- 25 * 26 * 0x0000h ~ 0x00FFh System Configuration 27 * 28 * ----------------------------------------------------- */ 29 #define REG_SYS_ISO_CTRL_8710B 0x0000 /* 2 Byte */ 30 #define REG_APS_FSMCO_8710B 0x0004 /* 4 Byte */ 31 #define REG_SYS_CLKR_8710B 0x0008 /* 2 Byte */ 32 #define REG_9346CR_8710B 0x000A /* 2 Byte */ 33 #define REG_EE_VPD_8710B 0x000C /* 2 Byte */ 34 #define REG_AFE_MISC_8710B 0x0010 /* 1 Byte */ 35 #define REG_SPS0_CTRL_8710B 0x0011 /* 7 Byte */ 36 #define REG_SPS_OCP_CFG_8710B 0x0018 /* 4 Byte */ 37 #define REG_RSV_CTRL_8710B 0x001C /* 3 Byte */ 38 #define REG_RF_CTRL_8710B 0x001F /* 1 Byte */ 39 #define REG_LPLDO_CTRL_8710B 0x0023 /* 1 Byte */ 40 #define REG_AFE_XTAL_CTRL_8710B 0x0024 /* 4 Byte */ 41 #define REG_AFE_PLL_CTRL_8710B 0x0028 /* 4 Byte */ 42 #define REG_MAC_PLL_CTRL_EXT_8710B 0x002c /* 4 Byte */ 43 #define REG_EFUSE_CTRL_8710B 0x0030 44 #define REG_EFUSE_TEST_8710B 0x0034 45 #define REG_PWR_DATA_8710B 0x0038 46 #define REG_CAL_TIMER_8710B 0x003C 47 #define REG_ACLK_MON_8710B 0x003E 48 #define REG_GPIO_MUXCFG_8710B 0x0040 49 #define REG_GPIO_IO_SEL_8710B 0x0042 50 #define REG_MAC_PINMUX_CFG_8710B 0x0043 51 #define REG_GPIO_PIN_CTRL_8710B 0x0044 52 #define REG_GPIO_INTM_8710B 0x0048 53 #define REG_LEDCFG0_8710B 0x004C 54 #define REG_LEDCFG1_8710B 0x004D 55 #define REG_LEDCFG2_8710B 0x004E 56 #define REG_LEDCFG3_8710B 0x004F 57 #define REG_FSIMR_8710B 0x0050 58 #define REG_FSISR_8710B 0x0054 59 #define REG_HSIMR_8710B 0x0058 60 #define REG_HSISR_8710B 0x005c 61 #define REG_GPIO_EXT_CTRL 0x0060 62 #define REG_PAD_CTRL1_8710B 0x0064 63 #define REG_MULTI_FUNC_CTRL_8710B 0x0068 64 #define REG_GPIO_STATUS_8710B 0x006C 65 #define REG_SDIO_CTRL_8710B 0x0070 66 #define REG_OPT_CTRL_8710B 0x0074 67 #define REG_AFE_CTRL_4_8710B 0x0078 68 #define REG_MCUFWDL_8710B 0x0080 69 #define REG_8051FW_CTRL_8710B 0x0080 70 #define REG_HMEBOX_DBG_0_8710B 0x0088 71 #define REG_HMEBOX_DBG_1_8710B 0x008A 72 #define REG_HMEBOX_DBG_2_8710B 0x008C 73 #define REG_HMEBOX_DBG_3_8710B 0x008E 74 #define REG_WLLPS_CTRL 0x0090 75 76 #define REG_PMC_DBG_CTRL2_8710B 0x00CC 77 #define REG_EFUSE_BURN_GNT_8710B 0x00CF 78 #define REG_HPON_FSM_8710B 0x00EC 79 #define REG_SYS_CFG1_8710B 0x00F0 80 #define REG_SYS_CFG_8710B 0x00FC 81 #define REG_ROM_VERSION 0x00FD 82 83 /* ----------------------------------------------------- 84 * 85 * 0x0100h ~ 0x01FFh MACTOP General Configuration 86 * 87 * ----------------------------------------------------- */ 88 #define REG_C2HEVT_CMD_ID_8710B 0x01A0 89 #define REG_C2HEVT_CMD_SEQ_88XX 0x01A1 90 #define REG_C2hEVT_CMD_CONTENT_88XX 0x01A2 91 #define REG_C2HEVT_CMD_LEN_8710B 0x01AE 92 #define REG_C2HEVT_CLEAR_8710B 0x01AF 93 #define REG_MCUTST_1_8710B 0x01C0 94 #define REG_WOWLAN_WAKE_REASON 0x01C7 95 #define REG_FMETHR_8710B 0x01C8 96 #define REG_HMETFR_8710B 0x01CC 97 #define REG_HMEBOX_0_8710B 0x01D0 98 #define REG_HMEBOX_1_8710B 0x01D4 99 #define REG_HMEBOX_2_8710B 0x01D8 100 #define REG_HMEBOX_3_8710B 0x01DC 101 #define REG_LLT_INIT_8710B 0x01E0 102 #define REG_HMEBOX_EXT0_8710B 0x01F0 103 #define REG_HMEBOX_EXT1_8710B 0x01F4 104 #define REG_HMEBOX_EXT2_8710B 0x01F8 105 #define REG_HMEBOX_EXT3_8710B 0x01FC 106 107 /* ----------------------------------------------------- 108 * 109 * 0x0200h ~ 0x027Fh TXDMA Configuration 110 * 111 * ----------------------------------------------------- */ 112 #define REG_RQPN_8710B 0x0200 113 #define REG_FIFOPAGE_8710B 0x0204 114 #define REG_DWBCN0_CTRL_8710B REG_TDECTRL 115 #define REG_TXDMA_OFFSET_CHK_8710B 0x020C 116 #define REG_TXDMA_STATUS_8710B 0x0210 117 #define REG_RQPN_NPQ_8710B 0x0214 118 #define REG_DWBCN1_CTRL_8710B 0x0228 119 120 121 /* ----------------------------------------------------- 122 * 123 * 0x0280h ~ 0x02FFh RXDMA Configuration 124 * 125 * ----------------------------------------------------- */ 126 #define REG_RXDMA_AGG_PG_TH_8710B 0x0280 127 #define REG_FW_UPD_RDPTR_8710B 0x0284 /* FW shall update this register before FW write RXPKT_RELEASE_POLL to 1 */ 128 #define REG_RXDMA_CONTROL_8710B 0x0286 /* Control the RX DMA. */ 129 #define REG_RXDMA_STATUS_8710B 0x0288 130 #define REG_RXDMA_MODE_CTRL_8710B 0x0290 131 #define REG_EARLY_MODE_CONTROL_8710B 0x02BC 132 #define REG_RSVD5_8710B 0x02F0 133 #define REG_RSVD6_8710B 0x02F4 134 135 /* ----------------------------------------------------- 136 * 137 * 0x0300h ~ 0x03FFh PCIe 138 * 139 * ----------------------------------------------------- */ 140 #define REG_PCIE_CTRL_REG_8710B 0x0300 141 #define REG_INT_MIG_8710B 0x0304 /* Interrupt Migration */ 142 #define REG_BCNQ_TXBD_DESA_8710B 0x0308 /* TX Beacon Descriptor Address */ 143 #define REG_MGQ_TXBD_DESA_8710B 0x0310 /* TX Manage Queue Descriptor Address */ 144 #define REG_VOQ_TXBD_DESA_8710B 0x0318 /* TX VO Queue Descriptor Address */ 145 #define REG_VIQ_TXBD_DESA_8710B 0x0320 /* TX VI Queue Descriptor Address */ 146 #define REG_BEQ_TXBD_DESA_8710B 0x0328 /* TX BE Queue Descriptor Address */ 147 #define REG_BKQ_TXBD_DESA_8710B 0x0330 /* TX BK Queue Descriptor Address */ 148 #define REG_RXQ_RXBD_DESA_8710B 0x0338 /* RX Queue Descriptor Address */ 149 #define REG_HI0Q_TXBD_DESA_8710B 0x0340 150 #define REG_HI1Q_TXBD_DESA_8710B 0x0348 151 #define REG_HI2Q_TXBD_DESA_8710B 0x0350 152 #define REG_HI3Q_TXBD_DESA_8710B 0x0358 153 #define REG_HI4Q_TXBD_DESA_8710B 0x0360 154 #define REG_HI5Q_TXBD_DESA_8710B 0x0368 155 #define REG_HI6Q_TXBD_DESA_8710B 0x0370 156 #define REG_HI7Q_TXBD_DESA_8710B 0x0378 157 #define REG_MGQ_TXBD_NUM_8710B 0x0380 158 #define REG_RX_RXBD_NUM_8710B 0x0382 159 #define REG_VOQ_TXBD_NUM_8710B 0x0384 160 #define REG_VIQ_TXBD_NUM_8710B 0x0386 161 #define REG_BEQ_TXBD_NUM_8710B 0x0388 162 #define REG_BKQ_TXBD_NUM_8710B 0x038A 163 #define REG_HI0Q_TXBD_NUM_8710B 0x038C 164 #define REG_HI1Q_TXBD_NUM_8710B 0x038E 165 #define REG_HI2Q_TXBD_NUM_8710B 0x0390 166 #define REG_HI3Q_TXBD_NUM_8710B 0x0392 167 #define REG_HI4Q_TXBD_NUM_8710B 0x0394 168 #define REG_HI5Q_TXBD_NUM_8710B 0x0396 169 #define REG_HI6Q_TXBD_NUM_8710B 0x0398 170 #define REG_HI7Q_TXBD_NUM_8710B 0x039A 171 #define REG_TSFTIMER_HCI_8710B 0x039C 172 #define REG_BD_RW_PTR_CLR_8710B 0x039C 173 174 /* Read Write Point */ 175 #define REG_VOQ_TXBD_IDX_8710B 0x03A0 176 #define REG_VIQ_TXBD_IDX_8710B 0x03A4 177 #define REG_BEQ_TXBD_IDX_8710B 0x03A8 178 #define REG_BKQ_TXBD_IDX_8710B 0x03AC 179 #define REG_MGQ_TXBD_IDX_8710B 0x03B0 180 #define REG_RXQ_TXBD_IDX_8710B 0x03B4 181 #define REG_HI0Q_TXBD_IDX_8710B 0x03B8 182 #define REG_HI1Q_TXBD_IDX_8710B 0x03BC 183 #define REG_HI2Q_TXBD_IDX_8710B 0x03C0 184 #define REG_HI3Q_TXBD_IDX_8710B 0x03C4 185 #define REG_HI4Q_TXBD_IDX_8710B 0x03C8 186 #define REG_HI5Q_TXBD_IDX_8710B 0x03CC 187 #define REG_HI6Q_TXBD_IDX_8710B 0x03D0 188 #define REG_HI7Q_TXBD_IDX_8710B 0x03D4 189 190 #define REG_PCIE_HCPWM_8710BE 0x03D8 /* ?????? */ 191 #define REG_PCIE_HRPWM_8710BE 0x03DC /* PCIe RPWM ?????? */ 192 #define REG_DBI_WDATA_V1_8710B 0x03E8 193 #define REG_DBI_RDATA_V1_8710B 0x03EC 194 #define REG_DBI_FLAG_V1_8710B 0x03F0 195 #define REG_MDIO_V1_8710B 0x03F4 196 #define REG_PCIE_MIX_CFG_8710B 0x03F8 197 #define REG_HCI_MIX_CFG_8710B 0x03FC 198 199 /* ----------------------------------------------------- 200 * 201 * 0x0400h ~ 0x047Fh Protocol Configuration 202 * 203 * ----------------------------------------------------- */ 204 #define REG_VOQ_INFORMATION_8710B 0x0400 205 #define REG_VIQ_INFORMATION_8710B 0x0404 206 #define REG_BEQ_INFORMATION_8710B 0x0408 207 #define REG_BKQ_INFORMATION_8710B 0x040C 208 #define REG_MGQ_INFORMATION_8710B 0x0410 209 #define REG_HGQ_INFORMATION_8710B 0x0414 210 #define REG_BCNQ_INFORMATION_8710B 0x0418 211 #define REG_TXPKT_EMPTY_8710B 0x041A 212 213 #define REG_FWHW_TXQ_CTRL_8710B 0x0420 214 #define REG_HWSEQ_CTRL_8710B 0x0423 215 #define REG_TXPKTBUF_BCNQ_BDNY_8710B 0x0424 216 #define REG_TXPKTBUF_MGQ_BDNY_8710B 0x0425 217 #define REG_LIFECTRL_CTRL_8710B 0x0426 218 #define REG_MULTI_BCNQ_OFFSET_8710B 0x0427 219 #define REG_SPEC_SIFS_8710B 0x0428 220 #define REG_RL_8710B 0x042A 221 #define REG_TXBF_CTRL_8710B 0x042C 222 #define REG_DARFRC_8710B 0x0430 223 #define REG_RARFRC_8710B 0x0438 224 #define REG_RRSR_8710B 0x0440 225 #define REG_ARFR0_8710B 0x0444 226 #define REG_ARFR1_8710B 0x044C 227 #define REG_CCK_CHECK_8710B 0x0454 228 #define REG_AMPDU_MAX_TIME_8710B 0x0456 229 #define REG_TXPKTBUF_BCNQ_BDNY1_8710B 0x0457 230 231 #define REG_AMPDU_MAX_LENGTH_8710B 0x0458 232 #define REG_TXPKTBUF_WMAC_LBK_BF_HD_8710B 0x045D 233 #define REG_NDPA_OPT_CTRL_8710B 0x045F 234 #define REG_FAST_EDCA_CTRL_8710B 0x0460 235 #define REG_RD_RESP_PKT_TH_8710B 0x0463 236 #define REG_DATA_SC_8710B 0x0483 237 #ifdef CONFIG_WOWLAN 238 #define REG_TXPKTBUF_IV_LOW 0x0484 239 #define REG_TXPKTBUF_IV_HIGH 0x0488 240 #endif 241 #define REG_TXRPT_START_OFFSET 0x04AC 242 #define REG_POWER_STAGE1_8710B 0x04B4 243 #define REG_POWER_STAGE2_8710B 0x04B8 244 #define REG_AMPDU_BURST_MODE_8710B 0x04BC 245 #define REG_PKT_VO_VI_LIFE_TIME_8710B 0x04C0 246 #define REG_PKT_BE_BK_LIFE_TIME_8710B 0x04C2 247 #define REG_STBC_SETTING_8710B 0x04C4 248 #define REG_HT_SINGLE_AMPDU_8710B 0x04C7 249 #define REG_PROT_MODE_CTRL_8710B 0x04C8 250 #define REG_MAX_AGGR_NUM_8710B 0x04CA 251 #define REG_RTS_MAX_AGGR_NUM_8710B 0x04CB 252 #define REG_BAR_MODE_CTRL_8710B 0x04CC 253 #define REG_RA_TRY_RATE_AGG_LMT_8710B 0x04CF 254 #define REG_MACID_PKT_DROP0_8710B 0x04D0 255 #define REG_MACID_PKT_SLEEP_8710B 0x04D4 256 257 /* ----------------------------------------------------- 258 * 259 * 0x0500h ~ 0x05FFh EDCA Configuration 260 * 261 * ----------------------------------------------------- */ 262 #define REG_EDCA_VO_PARAM_8710B 0x0500 263 #define REG_EDCA_VI_PARAM_8710B 0x0504 264 #define REG_EDCA_BE_PARAM_8710B 0x0508 265 #define REG_EDCA_BK_PARAM_8710B 0x050C 266 #define REG_BCNTCFG_8710B 0x0510 267 #define REG_PIFS_8710B 0x0512 268 #define REG_RDG_PIFS_8710B 0x0513 269 #define REG_SIFS_CTX_8710B 0x0514 270 #define REG_SIFS_TRX_8710B 0x0516 271 #define REG_AGGR_BREAK_TIME_8710B 0x051A 272 #define REG_SLOT_8710B 0x051B 273 #define REG_TX_PTCL_CTRL_8710B 0x0520 274 #define REG_TXPAUSE_8710B 0x0522 275 #define REG_DIS_TXREQ_CLR_8710B 0x0523 276 #define REG_RD_CTRL_8710B 0x0524 277 /* 278 * Format for offset 540h-542h: 279 * [3:0]: TBTT prohibit setup in unit of 32us. The time for HW getting beacon content before TBTT. 280 * [7:4]: Reserved. 281 * [19:8]: TBTT prohibit hold in unit of 32us. The time for HW holding to send the beacon packet. 282 * [23:20]: Reserved 283 * Description: 284 * | 285 * |<--Setup--|--Hold------------>| 286 * --------------|---------------------- 287 * | 288 * TBTT 289 * Note: We cannot update beacon content to HW or send any AC packets during the time between Setup and Hold. 290 * Described by Designer Tim and Bruce, 2011-01-14. 291 * */ 292 #define REG_TBTT_PROHIBIT_8710B 0x0540 293 #define REG_RD_NAV_NXT_8710B 0x0544 294 #define REG_NAV_PROT_LEN_8710B 0x0546 295 #define REG_BCN_CTRL_8710B 0x0550 296 #define REG_BCN_CTRL_1_8710B 0x0551 297 #define REG_MBID_NUM_8710B 0x0552 298 #define REG_DUAL_TSF_RST_8710B 0x0553 299 #define REG_BCN_INTERVAL_8710B 0x0554 300 #define REG_DRVERLYINT_8710B 0x0558 301 #define REG_BCNDMATIM_8710B 0x0559 302 #define REG_ATIMWND_8710B 0x055A 303 #define REG_USTIME_TSF_8710B 0x055C 304 #define REG_BCN_MAX_ERR_8710B 0x055D 305 #define REG_RXTSF_OFFSET_CCK_8710B 0x055E 306 #define REG_RXTSF_OFFSET_OFDM_8710B 0x055F 307 #define REG_TSFTR_8710B 0x0560 308 #define REG_CTWND_8710B 0x0572 309 #define REG_SECONDARY_CCA_CTRL_8710B 0x0577 310 #define REG_PSTIMER_8710B 0x0580 311 #define REG_TIMER0_8710B 0x0584 312 #define REG_TIMER1_8710B 0x0588 313 #define REG_ACMHWCTRL_8710B 0x05C0 314 #define REG_SCH_TXCMD_8710B 0x05F8 315 316 /* ----------------------------------------------------- 317 * 318 * 0x0600h ~ 0x07FFh WMAC Configuration 319 * 320 * ----------------------------------------------------- */ 321 #define REG_MAC_CR_8710B 0x0600 322 #define REG_TCR_8710B 0x0604 323 #define REG_RCR_8710B 0x0608 324 #define REG_RX_PKT_LIMIT_8710B 0x060C 325 #define REG_RX_DLK_TIME_8710B 0x060D 326 #define REG_RX_DRVINFO_SZ_8710B 0x060F 327 328 #define REG_MACID_8710B 0x0610 329 #define REG_BSSID_8710B 0x0618 330 #define REG_MAR_8710B 0x0620 331 #define REG_MBIDCAMCFG_8710B 0x0628 332 #define REG_WOWLAN_GTK_DBG1 0x630 333 #define REG_WOWLAN_GTK_DBG2 0x634 334 335 #define REG_USTIME_EDCA_8710B 0x0638 336 #define REG_MAC_SPEC_SIFS_8710B 0x063A 337 #define REG_RESP_SIFP_CCK_8710B 0x063C 338 #define REG_RESP_SIFS_OFDM_8710B 0x063E 339 #define REG_ACKTO_8710B 0x0640 340 #define REG_CTS2TO_8710B 0x0641 341 #define REG_EIFS_8710B 0x0642 342 343 #define REG_NAV_UPPER_8710B 0x0652 /* unit of 128 */ 344 #define REG_TRXPTCL_CTL_8710B 0x0668 345 346 /* Security */ 347 #define REG_CAMCMD_8710B 0x0670 348 #define REG_CAMWRITE_8710B 0x0674 349 #define REG_CAMREAD_8710B 0x0678 350 #define REG_CAMDBG_8710B 0x067C 351 #define REG_SECCFG_8710B 0x0680 352 353 /* Power */ 354 #define REG_WOW_CTRL_8710B 0x0690 355 #define REG_PS_RX_INFO_8710B 0x0692 356 #define REG_UAPSD_TID_8710B 0x0693 357 #define REG_WKFMCAM_CMD_8710B 0x0698 358 #define REG_WKFMCAM_NUM_8710B 0x0698 359 #define REG_WKFMCAM_RWD_8710B 0x069C 360 #define REG_RXFLTMAP0_8710B 0x06A0 361 #define REG_RXFLTMAP1_8710B 0x06A2 362 #define REG_RXFLTMAP2_8710B 0x06A4 363 #define REG_BCN_PSR_RPT_8710B 0x06A8 364 #define REG_BT_COEX_TABLE_8710B 0x06C0 365 #define REG_BFMER0_INFO_8710B 0x06E4 366 #define REG_BFMER1_INFO_8710B 0x06EC 367 #define REG_CSI_RPT_PARAM_BW20_8710B 0x06F4 368 #define REG_CSI_RPT_PARAM_BW40_8710B 0x06F8 369 #define REG_CSI_RPT_PARAM_BW80_8710B 0x06FC 370 371 /* Hardware Port 2 */ 372 #define REG_MACID1_8710B 0x0700 373 #define REG_BSSID1_8710B 0x0708 374 #define REG_BFMEE_SEL_8710B 0x0714 375 #define REG_SND_PTCL_CTRL_8710B 0x0718 376 377 /* LTR */ 378 #define REG_LTR_CTRL_BASIC_8710B 0x07A4 379 #define REG_LTR_IDLE_LATENCY_V1_8710B 0x0798 380 #define REG_LTR_ACTIVE_LATENCY_V1_8710B 0x079C 381 382 /* LTE_COEX */ 383 #define REG_LTECOEX_CTRL 0x07C0 384 #define REG_LTECOEX_WRITE_DATA 0x07C4 385 #define REG_LTECOEX_READ_DATA 0x07C8 386 #define REG_LTECOEX_PATH_CONTROL 0x70 387 388 /* Other */ 389 #define REG_USB_ACCESS_TIMEOUT 0xFE4C 390 391 /* ----------------------------------------------------- 392 * SYSON_REG_SPEC 393 * ----------------------------------------------------- */ 394 #define SYSON_REG_BASE_ADDR_8710B 0x40000000 395 #define REG_SYS_XTAL_CTRL0 0x0060 396 #define REG_SYS_SYSTEM_CFG0 0x1F0 397 #define REG_SYS_SYSTEM_CFG1 0x1F4 398 #define REG_SYS_SYSTEM_CFG2 0x1F8 399 #define REG_SYS_EEPROM_CTRL0 0x0E0 400 401 402 /* ----------------------------------------------------- 403 * Indirect_R/W_SPEC 404 * ----------------------------------------------------- */ 405 #define NORMAL_REG_READ_OFFSET 0x83000000 406 #define NORMAL_REG_WRITE_OFFSET 0x84000000 407 #define EFUSE_READ_OFFSET 0x85000000 408 #define EFUSE_WRITE_OFFSET 0x86000000 409 410 411 /* ----------------------------------------------------- 412 * PAGE0_WLANON_REG_SPEC 413 * ----------------------------------------------------- */ 414 #define PAGE0_OFFSET 0x0 // WLANON_PAGE0_REG needs to add an offset. 415 416 417 418 /* **************************************************************************** 419 * 8723 Regsiter Bit and Content definition 420 * **************************************************************************** */ 421 422 /* ----------------------------------------------------- 423 * REG_SYS_SYSTEM_CFG0 424 * ----------------------------------------------------- */ 425 #define BIT_RTL_ID_8710B BIT(16) 426 427 #define BIT_MASK_CHIP_VER_8710B 0xf 428 #define BIT_GET_CHIP_VER_8710B(x) ((x) & BIT_MASK_CHIP_VER_8710B) 429 430 #define BIT_SHIFT_VENDOR_ID_8710B 4 431 #define BIT_MASK_VENDOR_ID_8710B 0xf 432 #define BIT_GET_VENDOR_ID_8710B(x) (((x) >> BIT_SHIFT_VENDOR_ID_8710B) & BIT_MASK_VENDOR_ID_8710B) 433 434 /* ----------------------------------------------------- 435 * REG_SYS_SYSTEM_CFG1 436 * ----------------------------------------------------- */ 437 #define BIT_SPSLDO_SEL_8710B BIT(25) 438 439 /* ----------------------------------------------------- 440 * REG_SYS_SYSTEM_CFG2 441 * ----------------------------------------------------- */ 442 #define BIT_MASK_RF_RL_ID_8710B 0xf 443 #define BIT_GET_RF_RL_ID_8710B(x) ((x) & BIT_MASK_RF_RL_ID_8710B) 444 445 /* ----------------------------------------------------- 446 * REG_SYS_SYSTEM_CFG2 447 * ----------------------------------------------------- */ 448 #define BIT_EERPOMSEL_8710B BIT(4) 449 #define BIT_AUTOLOAD_SUS_8710B BIT(5) 450 451 452 /* ----------------------------------------------------- 453 * Other 454 * ----------------------------------------------------- */ 455 456 457 #define BIT_USB_RXDMA_AGG_EN BIT(31) 458 #define RXDMA_AGG_MODE_EN BIT(1) 459 460 #ifdef CONFIG_WOWLAN 461 #define RXPKT_RELEASE_POLL BIT(16) 462 #define RXDMA_IDLE BIT(17) 463 #define RW_RELEASE_EN BIT(18) 464 #endif 465 466 /* 2 HSISR 467 * interrupt mask which needs to clear */ 468 #define MASK_HSISR_CLEAR (HSISR_GPIO12_0_INT |\ 469 HSISR_SPS_OCP_INT |\ 470 HSISR_RON_INT |\ 471 HSISR_PDNINT |\ 472 HSISR_GPIO9_INT) 473 474 #ifdef CONFIG_RF_POWER_TRIM 475 #ifdef CONFIG_RTL8710B 476 #define EEPROM_RF_GAIN_OFFSET 0xC1 477 #endif 478 479 #define EEPROM_RF_GAIN_VAL 0x1F6 480 #endif /*CONFIG_RF_POWER_TRIM*/ 481 482 #endif /* __RTL8710B_SPEC_H__ */ 483