18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci * Public Include File for DRV6000 users
48c2ecf20Sopenharmony_ci * (ie. NxtWave Communications - NXT6000 demodulator driver)
58c2ecf20Sopenharmony_ci *
68c2ecf20Sopenharmony_ci * Copyright (C) 2001 NxtWave Communications, Inc.
78c2ecf20Sopenharmony_ci *
88c2ecf20Sopenharmony_ci */
98c2ecf20Sopenharmony_ci
108c2ecf20Sopenharmony_ci/*  Nxt6000 Register Addresses and Bit Masks */
118c2ecf20Sopenharmony_ci
128c2ecf20Sopenharmony_ci/* Maximum Register Number */
138c2ecf20Sopenharmony_ci#define MAXNXT6000REG          (0x9A)
148c2ecf20Sopenharmony_ci
158c2ecf20Sopenharmony_ci/* 0x1B A_VIT_BER_0  aka 0x3A */
168c2ecf20Sopenharmony_ci#define A_VIT_BER_0            (0x1B)
178c2ecf20Sopenharmony_ci
188c2ecf20Sopenharmony_ci/* 0x1D A_VIT_BER_TIMER_0 aka 0x38 */
198c2ecf20Sopenharmony_ci#define A_VIT_BER_TIMER_0      (0x1D)
208c2ecf20Sopenharmony_ci
218c2ecf20Sopenharmony_ci/* 0x21 RS_COR_STAT */
228c2ecf20Sopenharmony_ci#define RS_COR_STAT            (0x21)
238c2ecf20Sopenharmony_ci#define RSCORESTATUS           (0x03)
248c2ecf20Sopenharmony_ci
258c2ecf20Sopenharmony_ci/* 0x22 RS_COR_INTEN */
268c2ecf20Sopenharmony_ci#define RS_COR_INTEN           (0x22)
278c2ecf20Sopenharmony_ci
288c2ecf20Sopenharmony_ci/* 0x23 RS_COR_INSTAT */
298c2ecf20Sopenharmony_ci#define RS_COR_INSTAT          (0x23)
308c2ecf20Sopenharmony_ci#define INSTAT_ERROR           (0x04)
318c2ecf20Sopenharmony_ci#define LOCK_LOSS_BITS         (0x03)
328c2ecf20Sopenharmony_ci
338c2ecf20Sopenharmony_ci/* 0x24 RS_COR_SYNC_PARAM */
348c2ecf20Sopenharmony_ci#define RS_COR_SYNC_PARAM      (0x24)
358c2ecf20Sopenharmony_ci#define SYNC_PARAM             (0x03)
368c2ecf20Sopenharmony_ci
378c2ecf20Sopenharmony_ci/* 0x25 BER_CTRL */
388c2ecf20Sopenharmony_ci#define BER_CTRL               (0x25)
398c2ecf20Sopenharmony_ci#define BER_ENABLE             (0x02)
408c2ecf20Sopenharmony_ci#define BER_RESET              (0x01)
418c2ecf20Sopenharmony_ci
428c2ecf20Sopenharmony_ci/* 0x26 BER_PAY */
438c2ecf20Sopenharmony_ci#define BER_PAY                (0x26)
448c2ecf20Sopenharmony_ci
458c2ecf20Sopenharmony_ci/* 0x27 BER_PKT_L */
468c2ecf20Sopenharmony_ci#define BER_PKT_L              (0x27)
478c2ecf20Sopenharmony_ci#define BER_PKTOVERFLOW        (0x80)
488c2ecf20Sopenharmony_ci
498c2ecf20Sopenharmony_ci/* 0x30 VIT_COR_CTL */
508c2ecf20Sopenharmony_ci#define VIT_COR_CTL            (0x30)
518c2ecf20Sopenharmony_ci#define BER_CONTROL            (0x02)
528c2ecf20Sopenharmony_ci#define VIT_COR_MASK           (0x82)
538c2ecf20Sopenharmony_ci#define VIT_COR_RESYNC         (0x80)
548c2ecf20Sopenharmony_ci
558c2ecf20Sopenharmony_ci
568c2ecf20Sopenharmony_ci/* 0x32 VIT_SYNC_STATUS */
578c2ecf20Sopenharmony_ci#define VIT_SYNC_STATUS        (0x32)
588c2ecf20Sopenharmony_ci#define VITINSYNC              (0x80)
598c2ecf20Sopenharmony_ci
608c2ecf20Sopenharmony_ci/* 0x33 VIT_COR_INTEN */
618c2ecf20Sopenharmony_ci#define VIT_COR_INTEN          (0x33)
628c2ecf20Sopenharmony_ci#define GLOBAL_ENABLE          (0x80)
638c2ecf20Sopenharmony_ci
648c2ecf20Sopenharmony_ci/* 0x34 VIT_COR_INTSTAT */
658c2ecf20Sopenharmony_ci#define VIT_COR_INTSTAT        (0x34)
668c2ecf20Sopenharmony_ci#define BER_DONE               (0x08)
678c2ecf20Sopenharmony_ci#define BER_OVERFLOW           (0x10)
688c2ecf20Sopenharmony_ci
698c2ecf20Sopenharmony_ci/* 0x38 VIT_BERTIME_2 */
708c2ecf20Sopenharmony_ci#define VIT_BERTIME_2      (0x38)
718c2ecf20Sopenharmony_ci
728c2ecf20Sopenharmony_ci/* 0x39 VIT_BERTIME_1 */
738c2ecf20Sopenharmony_ci#define VIT_BERTIME_1      (0x39)
748c2ecf20Sopenharmony_ci
758c2ecf20Sopenharmony_ci/* 0x3A VIT_BERTIME_0 */
768c2ecf20Sopenharmony_ci#define VIT_BERTIME_0      (0x3a)
778c2ecf20Sopenharmony_ci
788c2ecf20Sopenharmony_ci			     /* 0x38 OFDM_BERTimer *//* Use the alias registers */
798c2ecf20Sopenharmony_ci#define A_VIT_BER_TIMER_0      (0x1D)
808c2ecf20Sopenharmony_ci
818c2ecf20Sopenharmony_ci			     /* 0x3A VIT_BER_TIMER_0 *//* Use the alias registers */
828c2ecf20Sopenharmony_ci#define A_VIT_BER_0            (0x1B)
838c2ecf20Sopenharmony_ci
848c2ecf20Sopenharmony_ci/* 0x3B VIT_BER_1 */
858c2ecf20Sopenharmony_ci#define VIT_BER_1              (0x3b)
868c2ecf20Sopenharmony_ci
878c2ecf20Sopenharmony_ci/* 0x3C VIT_BER_0 */
888c2ecf20Sopenharmony_ci#define VIT_BER_0              (0x3c)
898c2ecf20Sopenharmony_ci
908c2ecf20Sopenharmony_ci/* 0x40 OFDM_COR_CTL */
918c2ecf20Sopenharmony_ci#define OFDM_COR_CTL           (0x40)
928c2ecf20Sopenharmony_ci#define COREACT                (0x20)
938c2ecf20Sopenharmony_ci#define HOLDSM                 (0x10)
948c2ecf20Sopenharmony_ci#define WAIT_AGC               (0x02)
958c2ecf20Sopenharmony_ci#define WAIT_SYR               (0x03)
968c2ecf20Sopenharmony_ci
978c2ecf20Sopenharmony_ci/* 0x41 OFDM_COR_STAT */
988c2ecf20Sopenharmony_ci#define OFDM_COR_STAT          (0x41)
998c2ecf20Sopenharmony_ci#define COR_STATUS             (0x0F)
1008c2ecf20Sopenharmony_ci#define MONITOR_TPS            (0x06)
1018c2ecf20Sopenharmony_ci#define TPSLOCKED              (0x40)
1028c2ecf20Sopenharmony_ci#define AGCLOCKED              (0x10)
1038c2ecf20Sopenharmony_ci
1048c2ecf20Sopenharmony_ci/* 0x42 OFDM_COR_INTEN */
1058c2ecf20Sopenharmony_ci#define OFDM_COR_INTEN         (0x42)
1068c2ecf20Sopenharmony_ci#define TPSRCVBAD              (0x04)
1078c2ecf20Sopenharmony_ci#define TPSRCVCHANGED         (0x02)
1088c2ecf20Sopenharmony_ci#define TPSRCVUPDATE           (0x01)
1098c2ecf20Sopenharmony_ci
1108c2ecf20Sopenharmony_ci/* 0x43 OFDM_COR_INSTAT */
1118c2ecf20Sopenharmony_ci#define OFDM_COR_INSTAT        (0x43)
1128c2ecf20Sopenharmony_ci
1138c2ecf20Sopenharmony_ci/* 0x44 OFDM_COR_MODEGUARD */
1148c2ecf20Sopenharmony_ci#define OFDM_COR_MODEGUARD     (0x44)
1158c2ecf20Sopenharmony_ci#define FORCEMODE              (0x08)
1168c2ecf20Sopenharmony_ci#define FORCEMODE8K			   (0x04)
1178c2ecf20Sopenharmony_ci
1188c2ecf20Sopenharmony_ci/* 0x45 OFDM_AGC_CTL */
1198c2ecf20Sopenharmony_ci#define OFDM_AGC_CTL           (0x45)
1208c2ecf20Sopenharmony_ci#define INITIAL_AGC_BW		   (0x08)
1218c2ecf20Sopenharmony_ci#define AGCNEG                 (0x02)
1228c2ecf20Sopenharmony_ci#define AGCLAST				   (0x10)
1238c2ecf20Sopenharmony_ci
1248c2ecf20Sopenharmony_ci/* 0x48 OFDM_AGC_TARGET */
1258c2ecf20Sopenharmony_ci#define OFDM_AGC_TARGET		   (0x48)
1268c2ecf20Sopenharmony_ci#define OFDM_AGC_TARGET_DEFAULT (0x28)
1278c2ecf20Sopenharmony_ci#define OFDM_AGC_TARGET_IMPULSE (0x38)
1288c2ecf20Sopenharmony_ci
1298c2ecf20Sopenharmony_ci/* 0x49 OFDM_AGC_GAIN_1 */
1308c2ecf20Sopenharmony_ci#define OFDM_AGC_GAIN_1        (0x49)
1318c2ecf20Sopenharmony_ci
1328c2ecf20Sopenharmony_ci/* 0x4B OFDM_ITB_CTL */
1338c2ecf20Sopenharmony_ci#define OFDM_ITB_CTL           (0x4B)
1348c2ecf20Sopenharmony_ci#define ITBINV                 (0x01)
1358c2ecf20Sopenharmony_ci
1368c2ecf20Sopenharmony_ci/* 0x49 AGC_GAIN_1 */
1378c2ecf20Sopenharmony_ci#define AGC_GAIN_1             (0x49)
1388c2ecf20Sopenharmony_ci
1398c2ecf20Sopenharmony_ci/* 0x4A AGC_GAIN_2 */
1408c2ecf20Sopenharmony_ci#define AGC_GAIN_2             (0x4A)
1418c2ecf20Sopenharmony_ci
1428c2ecf20Sopenharmony_ci/* 0x4C OFDM_ITB_FREQ_1 */
1438c2ecf20Sopenharmony_ci#define OFDM_ITB_FREQ_1        (0x4C)
1448c2ecf20Sopenharmony_ci
1458c2ecf20Sopenharmony_ci/* 0x4D OFDM_ITB_FREQ_2 */
1468c2ecf20Sopenharmony_ci#define OFDM_ITB_FREQ_2        (0x4D)
1478c2ecf20Sopenharmony_ci
1488c2ecf20Sopenharmony_ci/* 0x4E  OFDM_CAS_CTL */
1498c2ecf20Sopenharmony_ci#define OFDM_CAS_CTL           (0x4E)
1508c2ecf20Sopenharmony_ci#define ACSDIS                 (0x40)
1518c2ecf20Sopenharmony_ci#define CCSEN                  (0x80)
1528c2ecf20Sopenharmony_ci
1538c2ecf20Sopenharmony_ci/* 0x4F CAS_FREQ */
1548c2ecf20Sopenharmony_ci#define CAS_FREQ               (0x4F)
1558c2ecf20Sopenharmony_ci
1568c2ecf20Sopenharmony_ci/* 0x51 OFDM_SYR_CTL */
1578c2ecf20Sopenharmony_ci#define OFDM_SYR_CTL           (0x51)
1588c2ecf20Sopenharmony_ci#define SIXTH_ENABLE           (0x80)
1598c2ecf20Sopenharmony_ci#define SYR_TRACKING_DISABLE   (0x01)
1608c2ecf20Sopenharmony_ci
1618c2ecf20Sopenharmony_ci/* 0x52 OFDM_SYR_STAT */
1628c2ecf20Sopenharmony_ci#define OFDM_SYR_STAT		   (0x52)
1638c2ecf20Sopenharmony_ci#define GI14_2K_SYR_LOCK	   (0x13)
1648c2ecf20Sopenharmony_ci#define GI14_8K_SYR_LOCK	   (0x17)
1658c2ecf20Sopenharmony_ci#define GI14_SYR_LOCK		   (0x10)
1668c2ecf20Sopenharmony_ci
1678c2ecf20Sopenharmony_ci/* 0x55 OFDM_SYR_OFFSET_1 */
1688c2ecf20Sopenharmony_ci#define OFDM_SYR_OFFSET_1      (0x55)
1698c2ecf20Sopenharmony_ci
1708c2ecf20Sopenharmony_ci/* 0x56 OFDM_SYR_OFFSET_2 */
1718c2ecf20Sopenharmony_ci#define OFDM_SYR_OFFSET_2      (0x56)
1728c2ecf20Sopenharmony_ci
1738c2ecf20Sopenharmony_ci/* 0x58 OFDM_SCR_CTL */
1748c2ecf20Sopenharmony_ci#define OFDM_SCR_CTL           (0x58)
1758c2ecf20Sopenharmony_ci#define SYR_ADJ_DECAY_MASK     (0x70)
1768c2ecf20Sopenharmony_ci#define SYR_ADJ_DECAY          (0x30)
1778c2ecf20Sopenharmony_ci
1788c2ecf20Sopenharmony_ci/* 0x59 OFDM_PPM_CTL_1 */
1798c2ecf20Sopenharmony_ci#define OFDM_PPM_CTL_1         (0x59)
1808c2ecf20Sopenharmony_ci#define PPMMAX_MASK            (0x30)
1818c2ecf20Sopenharmony_ci#define PPM256				   (0x30)
1828c2ecf20Sopenharmony_ci
1838c2ecf20Sopenharmony_ci/* 0x5B OFDM_TRL_NOMINALRATE_1 */
1848c2ecf20Sopenharmony_ci#define OFDM_TRL_NOMINALRATE_1 (0x5B)
1858c2ecf20Sopenharmony_ci
1868c2ecf20Sopenharmony_ci/* 0x5C OFDM_TRL_NOMINALRATE_2 */
1878c2ecf20Sopenharmony_ci#define OFDM_TRL_NOMINALRATE_2 (0x5C)
1888c2ecf20Sopenharmony_ci
1898c2ecf20Sopenharmony_ci/* 0x5D OFDM_TRL_TIME_1 */
1908c2ecf20Sopenharmony_ci#define OFDM_TRL_TIME_1        (0x5D)
1918c2ecf20Sopenharmony_ci
1928c2ecf20Sopenharmony_ci/* 0x60 OFDM_CRL_FREQ_1 */
1938c2ecf20Sopenharmony_ci#define OFDM_CRL_FREQ_1        (0x60)
1948c2ecf20Sopenharmony_ci
1958c2ecf20Sopenharmony_ci/* 0x63 OFDM_CHC_CTL_1 */
1968c2ecf20Sopenharmony_ci#define OFDM_CHC_CTL_1         (0x63)
1978c2ecf20Sopenharmony_ci#define MANMEAN1               (0xF0);
1988c2ecf20Sopenharmony_ci#define CHCFIR                 (0x01)
1998c2ecf20Sopenharmony_ci
2008c2ecf20Sopenharmony_ci/* 0x64 OFDM_CHC_SNR */
2018c2ecf20Sopenharmony_ci#define OFDM_CHC_SNR           (0x64)
2028c2ecf20Sopenharmony_ci
2038c2ecf20Sopenharmony_ci/* 0x65 OFDM_BDI_CTL */
2048c2ecf20Sopenharmony_ci#define OFDM_BDI_CTL           (0x65)
2058c2ecf20Sopenharmony_ci#define LP_SELECT              (0x02)
2068c2ecf20Sopenharmony_ci
2078c2ecf20Sopenharmony_ci/* 0x67 OFDM_TPS_RCVD_1 */
2088c2ecf20Sopenharmony_ci#define OFDM_TPS_RCVD_1        (0x67)
2098c2ecf20Sopenharmony_ci#define TPSFRAME               (0x03)
2108c2ecf20Sopenharmony_ci
2118c2ecf20Sopenharmony_ci/* 0x68 OFDM_TPS_RCVD_2 */
2128c2ecf20Sopenharmony_ci#define OFDM_TPS_RCVD_2        (0x68)
2138c2ecf20Sopenharmony_ci
2148c2ecf20Sopenharmony_ci/* 0x69 OFDM_TPS_RCVD_3 */
2158c2ecf20Sopenharmony_ci#define OFDM_TPS_RCVD_3        (0x69)
2168c2ecf20Sopenharmony_ci
2178c2ecf20Sopenharmony_ci/* 0x6A OFDM_TPS_RCVD_4 */
2188c2ecf20Sopenharmony_ci#define OFDM_TPS_RCVD_4        (0x6A)
2198c2ecf20Sopenharmony_ci
2208c2ecf20Sopenharmony_ci/* 0x6B OFDM_TPS_RESERVED_1 */
2218c2ecf20Sopenharmony_ci#define OFDM_TPS_RESERVED_1    (0x6B)
2228c2ecf20Sopenharmony_ci
2238c2ecf20Sopenharmony_ci/* 0x6C OFDM_TPS_RESERVED_2 */
2248c2ecf20Sopenharmony_ci#define OFDM_TPS_RESERVED_2    (0x6C)
2258c2ecf20Sopenharmony_ci
2268c2ecf20Sopenharmony_ci/* 0x73 OFDM_MSC_REV */
2278c2ecf20Sopenharmony_ci#define OFDM_MSC_REV           (0x73)
2288c2ecf20Sopenharmony_ci
2298c2ecf20Sopenharmony_ci/* 0x76 OFDM_SNR_CARRIER_2 */
2308c2ecf20Sopenharmony_ci#define OFDM_SNR_CARRIER_2     (0x76)
2318c2ecf20Sopenharmony_ci#define MEAN_MASK              (0x80)
2328c2ecf20Sopenharmony_ci#define MEANBIT                (0x80)
2338c2ecf20Sopenharmony_ci
2348c2ecf20Sopenharmony_ci/* 0x80 ANALOG_CONTROL_0 */
2358c2ecf20Sopenharmony_ci#define ANALOG_CONTROL_0       (0x80)
2368c2ecf20Sopenharmony_ci#define POWER_DOWN_ADC         (0x40)
2378c2ecf20Sopenharmony_ci
2388c2ecf20Sopenharmony_ci/* 0x81 ENABLE_TUNER_IIC */
2398c2ecf20Sopenharmony_ci#define ENABLE_TUNER_IIC       (0x81)
2408c2ecf20Sopenharmony_ci#define ENABLE_TUNER_BIT       (0x01)
2418c2ecf20Sopenharmony_ci
2428c2ecf20Sopenharmony_ci/* 0x82 EN_DMD_RACQ */
2438c2ecf20Sopenharmony_ci#define EN_DMD_RACQ            (0x82)
2448c2ecf20Sopenharmony_ci#define EN_DMD_RACQ_REG_VAL    (0x81)
2458c2ecf20Sopenharmony_ci#define EN_DMD_RACQ_REG_VAL_14 (0x01)
2468c2ecf20Sopenharmony_ci
2478c2ecf20Sopenharmony_ci/* 0x84 SNR_COMMAND */
2488c2ecf20Sopenharmony_ci#define SNR_COMMAND            (0x84)
2498c2ecf20Sopenharmony_ci#define SNRStat                (0x80)
2508c2ecf20Sopenharmony_ci
2518c2ecf20Sopenharmony_ci/* 0x85 SNRCARRIERNUMBER_LSB */
2528c2ecf20Sopenharmony_ci#define SNRCARRIERNUMBER_LSB   (0x85)
2538c2ecf20Sopenharmony_ci
2548c2ecf20Sopenharmony_ci/* 0x87 SNRMINTHRESHOLD_LSB */
2558c2ecf20Sopenharmony_ci#define SNRMINTHRESHOLD_LSB    (0x87)
2568c2ecf20Sopenharmony_ci
2578c2ecf20Sopenharmony_ci/* 0x89 SNR_PER_CARRIER_LSB */
2588c2ecf20Sopenharmony_ci#define SNR_PER_CARRIER_LSB    (0x89)
2598c2ecf20Sopenharmony_ci
2608c2ecf20Sopenharmony_ci/* 0x8B SNRBELOWTHRESHOLD_LSB */
2618c2ecf20Sopenharmony_ci#define SNRBELOWTHRESHOLD_LSB  (0x8B)
2628c2ecf20Sopenharmony_ci
2638c2ecf20Sopenharmony_ci/* 0x91 RF_AGC_VAL_1 */
2648c2ecf20Sopenharmony_ci#define RF_AGC_VAL_1           (0x91)
2658c2ecf20Sopenharmony_ci
2668c2ecf20Sopenharmony_ci/* 0x92 RF_AGC_STATUS */
2678c2ecf20Sopenharmony_ci#define RF_AGC_STATUS          (0x92)
2688c2ecf20Sopenharmony_ci
2698c2ecf20Sopenharmony_ci/* 0x98 DIAG_CONFIG */
2708c2ecf20Sopenharmony_ci#define DIAG_CONFIG            (0x98)
2718c2ecf20Sopenharmony_ci#define DIAG_MASK              (0x70)
2728c2ecf20Sopenharmony_ci#define TB_SET                 (0x10)
2738c2ecf20Sopenharmony_ci#define TRAN_SELECT            (0x07)
2748c2ecf20Sopenharmony_ci#define SERIAL_SELECT          (0x01)
2758c2ecf20Sopenharmony_ci
2768c2ecf20Sopenharmony_ci/* 0x99 SUB_DIAG_MODE_SEL */
2778c2ecf20Sopenharmony_ci#define SUB_DIAG_MODE_SEL      (0x99)
2788c2ecf20Sopenharmony_ci#define CLKINVERSION           (0x01)
2798c2ecf20Sopenharmony_ci
2808c2ecf20Sopenharmony_ci/* 0x9A TS_FORMAT */
2818c2ecf20Sopenharmony_ci#define TS_FORMAT              (0x9A)
2828c2ecf20Sopenharmony_ci#define ERROR_SENSE            (0x08)
2838c2ecf20Sopenharmony_ci#define VALID_SENSE            (0x04)
2848c2ecf20Sopenharmony_ci#define SYNC_SENSE             (0x02)
2858c2ecf20Sopenharmony_ci#define GATED_CLOCK            (0x01)
2868c2ecf20Sopenharmony_ci
2878c2ecf20Sopenharmony_ci#define NXT6000ASICDEVICE      (0x0b)
288