Thomas Gleixner | c942fdd | 2019-05-27 08:55:06 +0200 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0-or-later */ |
Hans-Frieder Vogt | ef89ec7 | 2012-05-06 16:56:55 -0300 | [diff] [blame] | 2 | /* |
| 3 | * Fitipower FC0012 tuner driver - include |
| 4 | * |
| 5 | * Copyright (C) 2012 Hans-Frieder Vogt <hfvogt@gmx.net> |
Hans-Frieder Vogt | ef89ec7 | 2012-05-06 16:56:55 -0300 | [diff] [blame] | 6 | */ |
| 7 | |
| 8 | #ifndef _FC0012_H_ |
| 9 | #define _FC0012_H_ |
| 10 | |
Mauro Carvalho Chehab | fada193 | 2017-12-28 13:03:51 -0500 | [diff] [blame] | 11 | #include <media/dvb_frontend.h> |
Hans-Frieder Vogt | ef89ec7 | 2012-05-06 16:56:55 -0300 | [diff] [blame] | 12 | #include "fc001x-common.h" |
| 13 | |
Antti Palosaari | ad3a758 | 2012-12-08 23:27:49 -0300 | [diff] [blame] | 14 | struct fc0012_config { |
| 15 | /* |
| 16 | * I2C address |
| 17 | */ |
| 18 | u8 i2c_address; |
| 19 | |
| 20 | /* |
| 21 | * clock |
| 22 | */ |
| 23 | enum fc001x_xtal_freq xtal_freq; |
| 24 | |
Antti Palosaari | 3a98477 | 2012-12-09 12:33:04 -0300 | [diff] [blame] | 25 | bool dual_master; |
Antti Palosaari | 71b1e82 | 2012-12-09 00:30:08 -0300 | [diff] [blame] | 26 | |
| 27 | /* |
| 28 | * RF loop-through |
| 29 | */ |
| 30 | bool loop_through; |
Antti Palosaari | 3b0d51a | 2012-12-09 11:46:40 -0300 | [diff] [blame] | 31 | |
| 32 | /* |
| 33 | * clock output |
| 34 | */ |
| 35 | bool clock_out; |
Antti Palosaari | ad3a758 | 2012-12-08 23:27:49 -0300 | [diff] [blame] | 36 | }; |
| 37 | |
Arnd Bergmann | 9b17452 | 2015-02-18 14:12:42 -0300 | [diff] [blame] | 38 | #if IS_REACHABLE(CONFIG_MEDIA_TUNER_FC0012) |
Hans-Frieder Vogt | ef89ec7 | 2012-05-06 16:56:55 -0300 | [diff] [blame] | 39 | extern struct dvb_frontend *fc0012_attach(struct dvb_frontend *fe, |
| 40 | struct i2c_adapter *i2c, |
Antti Palosaari | ad3a758 | 2012-12-08 23:27:49 -0300 | [diff] [blame] | 41 | const struct fc0012_config *cfg); |
Hans-Frieder Vogt | ef89ec7 | 2012-05-06 16:56:55 -0300 | [diff] [blame] | 42 | #else |
| 43 | static inline struct dvb_frontend *fc0012_attach(struct dvb_frontend *fe, |
| 44 | struct i2c_adapter *i2c, |
Antti Palosaari | ad3a758 | 2012-12-08 23:27:49 -0300 | [diff] [blame] | 45 | const struct fc0012_config *cfg) |
Hans-Frieder Vogt | ef89ec7 | 2012-05-06 16:56:55 -0300 | [diff] [blame] | 46 | { |
Antti Palosaari | 4562620 | 2012-12-09 13:42:25 -0300 | [diff] [blame] | 47 | pr_warn("%s: driver disabled by Kconfig\n", __func__); |
Hans-Frieder Vogt | ef89ec7 | 2012-05-06 16:56:55 -0300 | [diff] [blame] | 48 | return NULL; |
| 49 | } |
| 50 | #endif |
| 51 | |
| 52 | #endif |