11da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds/*
21da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    Support for OR51132 (pcHDTV HD-3000) - VSB/QAM
31da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *
41da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    Copyright (C) 2005 Kirk Lapray <kirk_lapray@bigfoot.com>
51da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *
61da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    This program is free software; you can redistribute it and/or modify
71da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    it under the terms of the GNU General Public License as published by
81da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    the Free Software Foundation; either version 2 of the License, or
91da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    (at your option) any later version.
101da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *
111da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    This program is distributed in the hope that it will be useful,
121da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    but WITHOUT ANY WARRANTY; without even the implied warranty of
131da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
141da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    GNU General Public License for more details.
151da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *
161da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    You should have received a copy of the GNU General Public License
171da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    along with this program; if not, write to the Free Software
181da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *    Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
191da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds *
201da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds*/
211da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds
221da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#ifndef OR51132_H
231da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#define OR51132_H
241da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds
251da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#include <linux/firmware.h>
261da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#include <linux/dvb/frontend.h>
271da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds
281da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvaldsstruct or51132_config
291da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds{
301da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds	/* The demodulator's i2c address */
311da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds	u8 demod_address;
321da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds
331da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds	/* Need to set device param for start_dma */
341da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds	int (*set_ts_params)(struct dvb_frontend* fe, int is_punctured);
351da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds};
361da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds
37c5dec9fb248e3318f30a26f9984b3b064053a77fTrent Piepho#if defined(CONFIG_DVB_OR51132) || (defined(CONFIG_DVB_OR51132_MODULE) && defined(MODULE))
381da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvaldsextern struct dvb_frontend* or51132_attach(const struct or51132_config* config,
391da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds					   struct i2c_adapter* i2c);
40102a342bb9672f67a34fd185803aaded4ce8dd0fAndrew de Quincey#else
41102a342bb9672f67a34fd185803aaded4ce8dd0fAndrew de Quinceystatic inline struct dvb_frontend* or51132_attach(const struct or51132_config* config,
42102a342bb9672f67a34fd185803aaded4ce8dd0fAndrew de Quincey					   struct i2c_adapter* i2c)
43102a342bb9672f67a34fd185803aaded4ce8dd0fAndrew de Quincey{
44271ddbf702c3a4e6b18f6464180eda0f62efd9a5Harvey Harrison	printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);
45102a342bb9672f67a34fd185803aaded4ce8dd0fAndrew de Quincey	return NULL;
46102a342bb9672f67a34fd185803aaded4ce8dd0fAndrew de Quincey}
47102a342bb9672f67a34fd185803aaded4ce8dd0fAndrew de Quincey#endif // CONFIG_DVB_OR51132
481da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds
491da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds#endif // OR51132_H
501da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds
511da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds/*
521da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * Local variables:
531da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * c-basic-offset: 8
541da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds * End:
551da177e4c3f41524e886b7f1b8a0c1fc7321cacLinus Torvalds */
56