18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-only */ 28c2ecf20Sopenharmony_ci/** 38c2ecf20Sopenharmony_ci * Driver for Zarlink ZL10036 DVB-S silicon tuner 48c2ecf20Sopenharmony_ci * 58c2ecf20Sopenharmony_ci * Copyright (C) 2006 Tino Reichardt 68c2ecf20Sopenharmony_ci * Copyright (C) 2007-2009 Matthias Schwarzott <zzam@gentoo.de> 78c2ecf20Sopenharmony_ci */ 88c2ecf20Sopenharmony_ci 98c2ecf20Sopenharmony_ci#ifndef DVB_ZL10036_H 108c2ecf20Sopenharmony_ci#define DVB_ZL10036_H 118c2ecf20Sopenharmony_ci 128c2ecf20Sopenharmony_ci#include <linux/i2c.h> 138c2ecf20Sopenharmony_ci#include <media/dvb_frontend.h> 148c2ecf20Sopenharmony_ci 158c2ecf20Sopenharmony_cistruct zl10036_config { 168c2ecf20Sopenharmony_ci u8 tuner_address; 178c2ecf20Sopenharmony_ci int rf_loop_enable; 188c2ecf20Sopenharmony_ci}; 198c2ecf20Sopenharmony_ci 208c2ecf20Sopenharmony_ci#if IS_REACHABLE(CONFIG_DVB_ZL10036) 218c2ecf20Sopenharmony_ci/** 228c2ecf20Sopenharmony_ci * Attach a zl10036 tuner to the supplied frontend structure. 238c2ecf20Sopenharmony_ci * 248c2ecf20Sopenharmony_ci * @fe: Frontend to attach to. 258c2ecf20Sopenharmony_ci * @config: zl10036_config structure. 268c2ecf20Sopenharmony_ci * @i2c: pointer to struct i2c_adapter. 278c2ecf20Sopenharmony_ci * return: FE pointer on success, NULL on failure. 288c2ecf20Sopenharmony_ci */ 298c2ecf20Sopenharmony_ciextern struct dvb_frontend *zl10036_attach(struct dvb_frontend *fe, 308c2ecf20Sopenharmony_ci const struct zl10036_config *config, struct i2c_adapter *i2c); 318c2ecf20Sopenharmony_ci#else 328c2ecf20Sopenharmony_cistatic inline struct dvb_frontend *zl10036_attach(struct dvb_frontend *fe, 338c2ecf20Sopenharmony_ci const struct zl10036_config *config, struct i2c_adapter *i2c) 348c2ecf20Sopenharmony_ci{ 358c2ecf20Sopenharmony_ci printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__); 368c2ecf20Sopenharmony_ci return NULL; 378c2ecf20Sopenharmony_ci} 388c2ecf20Sopenharmony_ci#endif 398c2ecf20Sopenharmony_ci 408c2ecf20Sopenharmony_ci#endif /* DVB_ZL10036_H */ 41