2
* Copyright (c) 2002-2010 Atheros Communications, Inc.
2
* Copyright (c) 2010-2011 Atheros Communications, Inc.
4
4
* Permission to use, copy, modify, and/or distribute this software for any
5
5
* purpose with or without fee is hereby granted, provided that the above
261
261
#define AR_PHY_EXT_CCA0 (AR_AGC_BASE + 0x20)
262
262
#define AR_PHY_RESTART (AR_AGC_BASE + 0x24)
265
* Antenna Diversity settings
264
267
#define AR_PHY_MC_GAIN_CTRL (AR_AGC_BASE + 0x28)
265
268
#define AR_ANT_DIV_CTRL_ALL 0x7e000000
266
269
#define AR_ANT_DIV_CTRL_ALL_S 25
267
270
#define AR_ANT_DIV_ENABLE 0x1000000
268
271
#define AR_ANT_DIV_ENABLE_S 24
274
#define AR_PHY_9485_ANT_FAST_DIV_BIAS 0x00007e00
275
#define AR_PHY_9485_ANT_FAST_DIV_BIAS_S 9
276
#define AR_PHY_9485_ANT_DIV_LNADIV 0x01000000
277
#define AR_PHY_9485_ANT_DIV_LNADIV_S 24
278
#define AR_PHY_9485_ANT_DIV_ALT_LNACONF 0x06000000
279
#define AR_PHY_9485_ANT_DIV_ALT_LNACONF_S 25
280
#define AR_PHY_9485_ANT_DIV_MAIN_LNACONF 0x18000000
281
#define AR_PHY_9485_ANT_DIV_MAIN_LNACONF_S 27
282
#define AR_PHY_9485_ANT_DIV_ALT_GAINTB 0x20000000
283
#define AR_PHY_9485_ANT_DIV_ALT_GAINTB_S 29
284
#define AR_PHY_9485_ANT_DIV_MAIN_GAINTB 0x40000000
285
#define AR_PHY_9485_ANT_DIV_MAIN_GAINTB_S 30
287
#define AR_PHY_9485_ANT_DIV_LNA1_MINUS_LNA2 0x0
288
#define AR_PHY_9485_ANT_DIV_LNA2 0x1
289
#define AR_PHY_9485_ANT_DIV_LNA1 0x2
290
#define AR_PHY_9485_ANT_DIV_LNA1_PLUS_LNA2 0x3
270
292
#define AR_PHY_EXTCHN_PWRTHR1 (AR_AGC_BASE + 0x2c)
271
293
#define AR_PHY_EXT_CHN_WIN (AR_AGC_BASE + 0x30)
272
294
#define AR_PHY_20_40_DET_THR (AR_AGC_BASE + 0x34)
486
508
#define AR_PHY_HEAVYCLIP_40 (AR_SM_BASE + 0x1ac)
487
509
#define AR_PHY_ILLEGAL_TXRATE (AR_SM_BASE + 0x1b0)
511
#define AR_PHY_POWER_TX_RATE(_d) (AR_SM_BASE + 0x1c0 + ((_d) << 2))
489
513
#define AR_PHY_PWRTX_MAX (AR_SM_BASE + 0x1f0)
490
514
#define AR_PHY_POWER_TX_SUB (AR_SM_BASE + 0x1f4)
547
571
#define AR_PHY_TXGAIN_TABLE (AR_SM_BASE + 0x300)
549
#define AR_PHY_TX_IQCAL_START_9485 (AR_SM_BASE + 0x3c4)
550
#define AR_PHY_TX_IQCAL_START_DO_CAL_9485 0x80000000
551
#define AR_PHY_TX_IQCAL_START_DO_CAL_9485_S 31
552
#define AR_PHY_TX_IQCAL_CONTROL_1_9485 (AR_SM_BASE + 0x3c8)
553
#define AR_PHY_TX_IQCAL_STATUS_B0_9485 (AR_SM_BASE + 0x3f0)
555
#define AR_PHY_TX_IQCAL_CONTROL_1 (AR_SM_BASE + 0x448)
556
#define AR_PHY_TX_IQCAL_START (AR_SM_BASE + 0x440)
557
#define AR_PHY_TX_IQCAL_STATUS_B0 (AR_SM_BASE + 0x48c)
573
#define AR_PHY_TX_IQCAL_CONTROL_1 (AR_SM_BASE + AR_SREV_9485(ah) ? \
575
#define AR_PHY_TX_IQCAL_START (AR_SM_BASE + AR_SREV_9485(ah) ? \
577
#define AR_PHY_TX_IQCAL_STATUS_B0 (AR_SM_BASE + AR_SREV_9485(ah) ? \
558
579
#define AR_PHY_TX_IQCAL_CORR_COEFF_B0(_i) (AR_SM_BASE + \
559
580
(AR_SREV_9485(ah) ? \
560
581
0x3d0 : 0x450) + ((_i) << 2))
586
607
#define AR_PHY_65NM_CH0_BIAS2 0x160c4
587
608
#define AR_PHY_65NM_CH0_BIAS4 0x160cc
588
609
#define AR_PHY_65NM_CH0_RXTX4 0x1610c
589
#define AR_PHY_65NM_CH0_THERM (AR_SREV_9485(ah) ? 0x1628c : 0x16290)
610
#define AR_PHY_65NM_CH0_THERM (AR_SREV_9300(ah) ? 0x16290 : 0x1628c)
591
612
#define AR_PHY_65NM_CH0_THERM_LOCAL 0x80000000
592
613
#define AR_PHY_65NM_CH0_THERM_LOCAL_S 31
756
777
#define AR_PHY_SPECTRAL_SCAN_SHORT_REPEAT 0x01000000
757
778
#define AR_PHY_SPECTRAL_SCAN_SHORT_REPEAT_S 24
758
779
#define AR_PHY_CHANNEL_STATUS_RX_CLEAR 0x00000004
759
#define AR_PHY_TX_IQCAQL_CONTROL_1_IQCORR_I_Q_COFF_DELPT 0x01fc0000
760
#define AR_PHY_TX_IQCAQL_CONTROL_1_IQCORR_I_Q_COFF_DELPT_S 18
761
#define AR_PHY_TX_IQCAL_START_DO_CAL 0x00000001
762
#define AR_PHY_TX_IQCAL_START_DO_CAL_S 0
780
#define AR_PHY_TX_IQCAL_CONTROL_1_IQCORR_I_Q_COFF_DELPT 0x01fc0000
781
#define AR_PHY_TX_IQCAL_CONTROL_1_IQCORR_I_Q_COFF_DELPT_S 18
782
#define AR_PHY_TX_IQCAL_START_DO_CAL 0x00000001
783
#define AR_PHY_TX_IQCAL_START_DO_CAL_S 0
764
785
#define AR_PHY_TX_IQCAL_STATUS_FAILED 0x00000001
765
786
#define AR_PHY_CALIBRATED_GAINS_0 0x3e