cachepc-linux

Fork of AMDESE/linux with modifications for CachePC side-channel attack
git clone https://git.sinitax.com/sinitax/cachepc-linux
Log | Files | Refs | README | LICENSE | sfeed.txt

tda827x.h (1383B)


      1/* SPDX-License-Identifier: GPL-2.0-or-later */
      2  /*
      3     DVB Driver for Philips tda827x / tda827xa Silicon tuners
      4
      5     (c) 2005 Hartmut Hackmann
      6     (c) 2007 Michael Krufky
      7
      8
      9  */
     10
     11#ifndef __DVB_TDA827X_H__
     12#define __DVB_TDA827X_H__
     13
     14#include <linux/i2c.h>
     15#include <media/dvb_frontend.h>
     16#include "tda8290.h"
     17
     18struct tda827x_config
     19{
     20	/* saa7134 - provided callbacks */
     21	int (*init) (struct dvb_frontend *fe);
     22	int (*sleep) (struct dvb_frontend *fe);
     23
     24	/* interface to tda829x driver */
     25	enum tda8290_lna config;
     26	int	     switch_addr;
     27
     28	void (*agcf)(struct dvb_frontend *fe);
     29};
     30
     31
     32/**
     33 * tda827x_attach() - Attach a tda827x tuner to the supplied frontend structure
     34 *
     35 * @fe: Frontend to attach to.
     36 * @addr: i2c address of the tuner.
     37 * @i2c: i2c adapter to use.
     38 * @cfg: optional callback function pointers.
     39 * @return FE pointer on success, NULL on failure.
     40 */
     41#if IS_REACHABLE(CONFIG_MEDIA_TUNER_TDA827X)
     42extern struct dvb_frontend* tda827x_attach(struct dvb_frontend *fe, int addr,
     43					   struct i2c_adapter *i2c,
     44					   struct tda827x_config *cfg);
     45#else
     46static inline struct dvb_frontend* tda827x_attach(struct dvb_frontend *fe,
     47						  int addr,
     48						  struct i2c_adapter *i2c,
     49						  struct tda827x_config *cfg)
     50{
     51	printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
     52	return NULL;
     53}
     54#endif // CONFIG_MEDIA_TUNER_TDA827X
     55
     56#endif // __DVB_TDA827X_H__