Andrew de Quincey | 96bf2f2 | 2005-07-07 17:57:53 -0700 | [diff] [blame] | 1 | /* |
Patrick Boettcher | dbad108 | 2008-04-13 15:47:53 -0300 | [diff] [blame] | 2 | * Driver for |
| 3 | * Samsung S5H1420 and |
| 4 | * PnpNetwork PN1010 QPSK Demodulator |
| 5 | * |
| 6 | * Copyright (C) 2005 Andrew de Quincey <adq_dvb@lidskialf.net> |
| 7 | * Copyright (C) 2005-8 Patrick Boettcher <pb@linuxtv.org> |
| 8 | * |
| 9 | * This program is free software; you can redistribute it and/or modify |
| 10 | * it under the terms of the GNU General Public License as published by |
| 11 | * the Free Software Foundation; either version 2 of the License, or |
| 12 | * (at your option) any later version. |
| 13 | * |
| 14 | * This program is distributed in the hope that it will be useful, |
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
| 17 | * |
| 18 | * GNU General Public License for more details. |
Patrick Boettcher | dbad108 | 2008-04-13 15:47:53 -0300 | [diff] [blame] | 19 | */ |
Andrew de Quincey | 96bf2f2 | 2005-07-07 17:57:53 -0700 | [diff] [blame] | 20 | #ifndef S5H1420_H |
| 21 | #define S5H1420_H |
| 22 | |
| 23 | #include <linux/dvb/frontend.h> |
| 24 | |
| 25 | struct s5h1420_config |
| 26 | { |
| 27 | /* the demodulator's i2c address */ |
| 28 | u8 demod_address; |
| 29 | |
Andrew de Quincey | a9d6a80 | 2005-09-09 13:02:31 -0700 | [diff] [blame] | 30 | /* does the inversion require inversion? */ |
Patrick Boettcher | c18c5ff | 2008-09-06 13:31:58 -0300 | [diff] [blame] | 31 | u8 invert:1; |
Patrick Boettcher | dbad108 | 2008-04-13 15:47:53 -0300 | [diff] [blame] | 32 | |
Patrick Boettcher | c18c5ff | 2008-09-06 13:31:58 -0300 | [diff] [blame] | 33 | u8 repeated_start_workaround:1; |
| 34 | u8 cdclk_polarity:1; /* 1 == falling edge, 0 == raising edge */ |
| 35 | |
| 36 | u8 serial_mpeg:1; |
Andrew de Quincey | 96bf2f2 | 2005-07-07 17:57:53 -0700 | [diff] [blame] | 37 | }; |
| 38 | |
Arnd Bergmann | 9b17452 | 2015-02-18 14:12:42 -0300 | [diff] [blame] | 39 | #if IS_REACHABLE(CONFIG_DVB_S5H1420) |
Patrick Boettcher | dbad108 | 2008-04-13 15:47:53 -0300 | [diff] [blame] | 40 | extern struct dvb_frontend *s5h1420_attach(const struct s5h1420_config *config, |
| 41 | struct i2c_adapter *i2c); |
| 42 | extern struct i2c_adapter *s5h1420_get_tuner_i2c_adapter(struct dvb_frontend *fe); |
Andrew de Quincey | 102a342 | 2006-08-08 09:10:08 -0300 | [diff] [blame] | 43 | #else |
Patrick Boettcher | dbad108 | 2008-04-13 15:47:53 -0300 | [diff] [blame] | 44 | static inline struct dvb_frontend *s5h1420_attach(const struct s5h1420_config *config, |
| 45 | struct i2c_adapter *i2c) |
Andrew de Quincey | 102a342 | 2006-08-08 09:10:08 -0300 | [diff] [blame] | 46 | { |
Harvey Harrison | 271ddbf | 2008-04-08 23:20:00 -0300 | [diff] [blame] | 47 | printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__); |
Andrew de Quincey | 102a342 | 2006-08-08 09:10:08 -0300 | [diff] [blame] | 48 | return NULL; |
| 49 | } |
Patrick Boettcher | dbad108 | 2008-04-13 15:47:53 -0300 | [diff] [blame] | 50 | |
| 51 | static inline struct i2c_adapter *s5h1420_get_tuner_i2c_adapter(struct dvb_frontend *fe) |
| 52 | { |
| 53 | return NULL; |
| 54 | } |
Andrew de Quincey | 102a342 | 2006-08-08 09:10:08 -0300 | [diff] [blame] | 55 | #endif // CONFIG_DVB_S5H1420 |
Andrew de Quincey | 96bf2f2 | 2005-07-07 17:57:53 -0700 | [diff] [blame] | 56 | |
| 57 | #endif // S5H1420_H |