13e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham/*
23e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	TDA665x tuner driver
33e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	Copyright (C) Manu Abraham (abraham.manu@gmail.com)
43e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
53e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	This program is free software; you can redistribute it and/or modify
63e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	it under the terms of the GNU General Public License as published by
73e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	the Free Software Foundation; either version 2 of the License, or
83e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	(at your option) any later version.
93e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
103e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	This program is distributed in the hope that it will be useful,
113e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	but WITHOUT ANY WARRANTY; without even the implied warranty of
123e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
133e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	GNU General Public License for more details.
143e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
153e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	You should have received a copy of the GNU General Public License
163e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	along with this program; if not, write to the Free Software
173e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
183e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham*/
193e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
203e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham#ifndef __TDA665x_H
213e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham#define __TDA665x_H
223e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
233e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abrahamstruct tda665x_config {
243e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	char name[128];
253e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
263e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	u8	addr;
273e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	u32	frequency_min;
283e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	u32	frequency_max;
293e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	u32	frequency_offst;
303e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	u32	ref_multiplier;
313e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	u32	ref_divider;
323e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham};
333e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
347b34be71db533f3e0cf93d53cf62d036cdb5418aPeter Senna Tschudin#if IS_ENABLED(CONFIG_DVB_TDA665x)
353e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
363e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abrahamextern struct dvb_frontend *tda665x_attach(struct dvb_frontend *fe,
373e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham					   const struct tda665x_config *config,
383e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham					   struct i2c_adapter *i2c);
393e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
403e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham#else
413e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
423e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abrahamstatic inline struct dvb_frontend *tda665x_attach(struct dvb_frontend *fe,
43f5ae4f6f482191c531ea9e50ac91d9bd2ffca171Manu Abraham						  const struct tda665x_config *config,
443e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham						  struct i2c_adapter *i2c)
453e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham{
463e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	printk(KERN_WARNING "%s: Driver disabled by Kconfig\n", __func__);
473e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham	return NULL;
483e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham}
493e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
503e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham#endif /* CONFIG_DVB_TDA665x */
513e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham
523e978a8284080d801d20cda377d9cf7c12fe68b9Manu Abraham#endif /* __TDA665x_H */
53