1/* SPDX-License-Identifier: GPL-2.0-or-later */
2  /*
3     Driver for Philips tda10086 DVBS Frontend
4
5     (c) 2006 Andrew de Quincey
6
7
8   */
9
10#ifndef TDA10086_H
11#define TDA10086_H
12
13#include <linux/dvb/frontend.h>
14#include <linux/firmware.h>
15
16enum tda10086_xtal {
17	TDA10086_XTAL_16M,
18	TDA10086_XTAL_4M
19};
20
21struct tda10086_config
22{
23	/* the demodulator's i2c address */
24	u8 demod_address;
25
26	/* does the "inversion" need inverted? */
27	u8 invert;
28
29	/* do we need the diseqc signal with carrier? */
30	u8 diseqc_tone;
31
32	/* frequency of the reference xtal */
33	enum tda10086_xtal xtal_freq;
34};
35
36#if IS_REACHABLE(CONFIG_DVB_TDA10086)
37extern struct dvb_frontend* tda10086_attach(const struct tda10086_config* config,
38					    struct i2c_adapter* i2c);
39#else
40static inline struct dvb_frontend* tda10086_attach(const struct tda10086_config* config,
41						   struct i2c_adapter* i2c)
42{
43	printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
44	return NULL;
45}
46#endif /* CONFIG_DVB_TDA10086 */
47
48#endif /* TDA10086_H */
49