linux/drivers/media/tuners/mc44s803_priv.h

/* SPDX-License-Identifier: GPL-2.0-or-later */
/*
 *  Driver for Freescale MC44S803 Low Power CMOS Broadband Tuner
 *
 *  Copyright (c) 2009 Jochen Friedrich <[email protected]>
 */

#ifndef MC44S803_PRIV_H
#define MC44S803_PRIV_H

/* This driver is based on the information available in the datasheet
   http://www.freescale.com/files/rf_if/doc/data_sheet/MC44S803.pdf

   SPI or I2C Address : 0xc0-0xc6

   Reg.No | Function
   -------------------------------------------
       00 | Power Down
       01 | Reference Oszillator
       02 | Reference Dividers
       03 | Mixer and Reference Buffer
       04 | Reset/Serial Out
       05 | LO 1
       06 | LO 2
       07 | Circuit Adjust
       08 | Test
       09 | Digital Tune
       0A | LNA AGC
       0B | Data Register Address
       0C | Regulator Test
       0D | VCO Test
       0E | LNA Gain/Input Power
       0F | ID Bits

*/

#define MC44S803_OSC
#define MC44S803_IF1
#define MC44S803_IF2

#define MC44S803_REG_POWER
#define MC44S803_REG_REFOSC
#define MC44S803_REG_REFDIV
#define MC44S803_REG_MIXER
#define MC44S803_REG_RESET
#define MC44S803_REG_LO1
#define MC44S803_REG_LO2
#define MC44S803_REG_CIRCADJ
#define MC44S803_REG_TEST
#define MC44S803_REG_DIGTUNE
#define MC44S803_REG_LNAAGC
#define MC44S803_REG_DATAREG
#define MC44S803_REG_REGTEST
#define MC44S803_REG_VCOTEST
#define MC44S803_REG_LNAGAIN
#define MC44S803_REG_ID

/* Register definitions */
#define MC44S803_ADDR
#define MC44S803_ADDR_S
/* REG_POWER */
#define MC44S803_POWER
#define MC44S803_POWER_S
/* REG_REFOSC */
#define MC44S803_REFOSC
#define MC44S803_REFOSC_S
#define MC44S803_OSCSEL
#define MC44S803_OSCSEL_S
/* REG_REFDIV */
#define MC44S803_R2
#define MC44S803_R2_S
#define MC44S803_REFBUF_EN
#define MC44S803_REFBUF_EN_S
#define MC44S803_R1
#define MC44S803_R1_S
/* REG_MIXER */
#define MC44S803_R3
#define MC44S803_R3_S
#define MC44S803_MUX3
#define MC44S803_MUX3_S
#define MC44S803_MUX4
#define MC44S803_MUX4_S
#define MC44S803_OSC_SCR
#define MC44S803_OSC_SCR_S
#define MC44S803_TRI_STATE
#define MC44S803_TRI_STATE_S
#define MC44S803_BUF_GAIN
#define MC44S803_BUF_GAIN_S
#define MC44S803_BUF_IO
#define MC44S803_BUF_IO_S
#define MC44S803_MIXER_RES
#define MC44S803_MIXER_RES_S
/* REG_RESET */
#define MC44S803_RS
#define MC44S803_RS_S
#define MC44S803_SO
#define MC44S803_SO_S
/* REG_LO1 */
#define MC44S803_LO1
#define MC44S803_LO1_S
/* REG_LO2 */
#define MC44S803_LO2
#define MC44S803_LO2_S
/* REG_CIRCADJ */
#define MC44S803_G1
#define MC44S803_G1_S
#define MC44S803_G3
#define MC44S803_G3_S
#define MC44S803_CIRCADJ_RES
#define MC44S803_CIRCADJ_RES_S
#define MC44S803_G6
#define MC44S803_G6_S
#define MC44S803_G7
#define MC44S803_G7_S
#define MC44S803_S1
#define MC44S803_S1_S
#define MC44S803_LP
#define MC44S803_LP_S
#define MC44S803_CLRF
#define MC44S803_CLRF_S
#define MC44S803_CLIF
#define MC44S803_CLIF_S
/* REG_TEST */
/* REG_DIGTUNE */
#define MC44S803_DA
#define MC44S803_DA_S
#define MC44S803_XOD
#define MC44S803_XOD_S
#define MC44S803_RST
#define MC44S803_RST_S
#define MC44S803_LO_REF
#define MC44S803_LO_REF_S
#define MC44S803_AT
#define MC44S803_AT_S
#define MC44S803_MT
#define MC44S803_MT_S
/* REG_LNAAGC */
#define MC44S803_G
#define MC44S803_G_S
#define MC44S803_AT1
#define MC44S803_AT1_S
#define MC44S803_AT2
#define MC44S803_AT2_S
#define MC44S803_HL_GR_EN
#define MC44S803_HL_GR_EN_S
#define MC44S803_AGC_AN_DIG
#define MC44S803_AGC_AN_DIG_S
#define MC44S803_ATTEN_EN
#define MC44S803_ATTEN_EN_S
#define MC44S803_AGC_READ_EN
#define MC44S803_AGC_READ_EN_S
#define MC44S803_LNA0
#define MC44S803_LNA0_S
#define MC44S803_AGC_SEL
#define MC44S803_AGC_SEL_S
#define MC44S803_AT0
#define MC44S803_AT0_S
#define MC44S803_B
#define MC44S803_B_S
/* REG_DATAREG */
#define MC44S803_D
#define MC44S803_D_S
/* REG_REGTEST */
/* REG_VCOTEST */
/* REG_LNAGAIN */
#define MC44S803_IF_PWR
#define MC44S803_IF_PWR_S
#define MC44S803_RF_PWR
#define MC44S803_RF_PWR_S
#define MC44S803_LNA_GAIN
#define MC44S803_LNA_GAIN_S
/* REG_ID */
#define MC44S803_ID
#define MC44S803_ID_S

/* Some macros to read/write fields */

/* First shift, then mask */
#define MC44S803_REG_SM(_val, _reg)

/* First mask, then shift */
#define MC44S803_REG_MS(_val, _reg)

struct mc44s803_priv {};

#endif