linux/drivers/media/dvb-frontends/ds3000.c

// SPDX-License-Identifier: GPL-2.0-or-later
/*
    Montage Technology DS3000 - DVBS/S2 Demodulator driver
    Copyright (C) 2009-2012 Konstantin Dimitrov <[email protected]>

    Copyright (C) 2009-2012 TurboSight.com

 */

#include <linux/slab.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/moduleparam.h>
#include <linux/init.h>
#include <linux/firmware.h>

#include <media/dvb_frontend.h>
#include "ts2020.h"
#include "ds3000.h"

static int debug;

#define dprintk(args...)

/* as of March 2009 current DS3000 firmware version is 1.78 */
/* DS3000 FW v1.78 MD5: a32d17910c4f370073f9346e71d34b80 */
#define DS3000_DEFAULT_FIRMWARE

#define DS3000_SAMPLE_RATE

/* Register values to initialise the demod in DVB-S mode */
static u8 ds3000_dvbs_init_tab[] =;

/* Register values to initialise the demod in DVB-S2 mode */
static u8 ds3000_dvbs2_init_tab[] =;

struct ds3000_state {};

static int ds3000_writereg(struct ds3000_state *state, int reg, int data)
{}

static int ds3000_i2c_gate_ctrl(struct dvb_frontend *fe, int enable)
{}

/* I2C write for 8k firmware load */
static int ds3000_writeFW(struct ds3000_state *state, int reg,
				const u8 *data, u16 len)
{}

static int ds3000_readreg(struct ds3000_state *state, u8 reg)
{}

static int ds3000_load_firmware(struct dvb_frontend *fe,
					const struct firmware *fw);

static int ds3000_firmware_ondemand(struct dvb_frontend *fe)
{}

static int ds3000_load_firmware(struct dvb_frontend *fe,
					const struct firmware *fw)
{}

static int ds3000_set_voltage(struct dvb_frontend *fe,
			      enum fe_sec_voltage voltage)
{}

static int ds3000_read_status(struct dvb_frontend *fe, enum fe_status *status)
{}

/* read DS3000 BER value */
static int ds3000_read_ber(struct dvb_frontend *fe, u32* ber)
{}

static int ds3000_read_signal_strength(struct dvb_frontend *fe,
						u16 *signal_strength)
{}

/* calculate DS3000 snr value in dB */
static int ds3000_read_snr(struct dvb_frontend *fe, u16 *snr)
{}

/* read DS3000 uncorrected blocks */
static int ds3000_read_ucblocks(struct dvb_frontend *fe, u32 *ucblocks)
{}

static int ds3000_set_tone(struct dvb_frontend *fe, enum fe_sec_tone_mode tone)
{}

static int ds3000_send_diseqc_msg(struct dvb_frontend *fe,
				struct dvb_diseqc_master_cmd *d)
{}

/* Send DiSEqC burst */
static int ds3000_diseqc_send_burst(struct dvb_frontend *fe,
				    enum fe_sec_mini_cmd burst)
{}

static void ds3000_release(struct dvb_frontend *fe)
{}

static const struct dvb_frontend_ops ds3000_ops;

struct dvb_frontend *ds3000_attach(const struct ds3000_config *config,
				    struct i2c_adapter *i2c)
{}
EXPORT_SYMBOL_GPL();

static int ds3000_set_carrier_offset(struct dvb_frontend *fe,
					s32 carrier_offset_khz)
{}

static int ds3000_set_frontend(struct dvb_frontend *fe)
{}

static int ds3000_tune(struct dvb_frontend *fe,
			bool re_tune,
			unsigned int mode_flags,
			unsigned int *delay,
			enum fe_status *status)
{}

static enum dvbfe_algo ds3000_get_algo(struct dvb_frontend *fe)
{}

/*
 * Initialise or wake up device
 *
 * Power config will reset and load initial firmware if required
 */
static int ds3000_initfe(struct dvb_frontend *fe)
{}

static const struct dvb_frontend_ops ds3000_ops =;

module_param(debug, int, 0644);
MODULE_PARM_DESC();

MODULE_DESCRIPTION();
MODULE_AUTHOR();
MODULE_LICENSE();
MODULE_FIRMWARE();