Path: blob/master/drivers/media/dvb/frontends/au8522.h
15112 views
/*1Auvitek AU8522 QAM/8VSB demodulator driver23Copyright (C) 2008 Steven Toth <[email protected]>45This program is free software; you can redistribute it and/or modify6it under the terms of the GNU General Public License as published by7the Free Software Foundation; either version 2 of the License, or8(at your option) any later version.910This program is distributed in the hope that it will be useful,11but WITHOUT ANY WARRANTY; without even the implied warranty of12MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the13GNU General Public License for more details.1415You should have received a copy of the GNU General Public License16along with this program; if not, write to the Free Software17Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.1819*/2021#ifndef __AU8522_H__22#define __AU8522_H__2324#include <linux/dvb/frontend.h>2526enum au8522_if_freq {27AU8522_IF_6MHZ = 0,28AU8522_IF_4MHZ,29AU8522_IF_3_25MHZ,30};3132struct au8522_led_config {33u16 vsb8_strong;34u16 qam64_strong;35u16 qam256_strong;3637u16 gpio_output;38/* unset hi bits, set low bits */39u16 gpio_output_enable;40u16 gpio_output_disable;4142u16 gpio_leds;43u8 *led_states;44unsigned int num_led_states;45};4647struct au8522_config {48/* the demodulator's i2c address */49u8 demod_address;5051/* Return lock status based on tuner lock, or demod lock */52#define AU8522_TUNERLOCKING 053#define AU8522_DEMODLOCKING 154u8 status_mode;5556struct au8522_led_config *led_cfg;5758enum au8522_if_freq vsb_if;59enum au8522_if_freq qam_if;60};6162#if defined(CONFIG_DVB_AU8522) || \63(defined(CONFIG_DVB_AU8522_MODULE) && defined(MODULE))64extern struct dvb_frontend *au8522_attach(const struct au8522_config *config,65struct i2c_adapter *i2c);66#else67static inline68struct dvb_frontend *au8522_attach(const struct au8522_config *config,69struct i2c_adapter *i2c)70{71printk(KERN_WARNING "%s: driver disabled by Kconfig\n", __func__);72return NULL;73}74#endif /* CONFIG_DVB_AU8522 */7576/* Other modes may need to be added later */77enum au8522_video_input {78AU8522_COMPOSITE_CH1 = 1,79AU8522_COMPOSITE_CH2,80AU8522_COMPOSITE_CH3,81AU8522_COMPOSITE_CH4,82AU8522_COMPOSITE_CH4_SIF,83AU8522_SVIDEO_CH13,84AU8522_SVIDEO_CH24,85};8687enum au8522_audio_input {88AU8522_AUDIO_NONE,89AU8522_AUDIO_SIF,90};9192#endif /* __AU8522_H__ */9394/*95* Local variables:96* c-basic-offset: 897*/9899100