diff options
author | Matthias Schwarzott <zzam@gentoo.org> | 2014-07-22 17:12:15 -0300 |
---|---|---|
committer | Mauro Carvalho Chehab <m.chehab@samsung.com> | 2014-07-27 17:02:48 -0300 |
commit | dd2e7dd20cf482bc2fd989bfbd0354476ae904c2 (patch) | |
tree | 01deaaf5d448f3f4b82a68397975fba6fbf8dacb /drivers/media/usb/cx231xx/cx231xx-dvb.c | |
parent | 6d3debafc8e718d5f3b2d87fe0387019b29b3bfa (diff) | |
download | linux-stable-dd2e7dd20cf482bc2fd989bfbd0354476ae904c2.tar.gz |
[media] cx231xx: Add digital support for HVR 930c-HD model 1113xx
Add support for:
[2040:b130] Hauppauge WinTV 930C-HD (model 1113xx)
After loading the driver the first open to dvb device node fails.
Signed-off-by: Matthias Schwarzott <zzam@gentoo.org>
Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/usb/cx231xx/cx231xx-dvb.c')
-rw-r--r-- | drivers/media/usb/cx231xx/cx231xx-dvb.c | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/drivers/media/usb/cx231xx/cx231xx-dvb.c b/drivers/media/usb/cx231xx/cx231xx-dvb.c index 5c69be707a30..4ff6f7f7aa5c 100644 --- a/drivers/media/usb/cx231xx/cx231xx-dvb.c +++ b/drivers/media/usb/cx231xx/cx231xx-dvb.c @@ -32,6 +32,7 @@ #include "tda18271.h" #include "s5h1411.h" #include "lgdt3305.h" +#include "si2165.h" #include "mb86a20s.h" MODULE_DESCRIPTION("driver for cx231xx based DVB cards"); @@ -152,6 +153,12 @@ static struct tda18271_config pv_tda18271_config = { .small_i2c = TDA18271_03_BYTE_CHUNK_INIT, }; +static const struct si2165_config hauppauge_930C_HD_1113xx_si2165_config = { + .i2c_addr = 0x64, + .chip_mode = SI2165_MODE_PLL_XTAL, + .ref_freq_Hz = 16000000, +}; + static inline void print_err_status(struct cx231xx *dev, int packet, int status) { char *errmsg = "Unknown"; @@ -712,6 +719,33 @@ static int dvb_init(struct cx231xx *dev) &hcw_tda18271_config); break; + case CX231XX_BOARD_HAUPPAUGE_930C_HD_1113xx: + + dev->dvb->frontend = dvb_attach(si2165_attach, + &hauppauge_930C_HD_1113xx_si2165_config, + &dev->i2c_bus[dev->board.tuner_i2c_master].i2c_adap + ); + + if (dev->dvb->frontend == NULL) { + printk(DRIVER_NAME + ": Failed to attach SI2165 front end\n"); + result = -EINVAL; + goto out_free; + } + + dev->dvb->frontend->ops.i2c_gate_ctrl = 0; + + /* define general-purpose callback pointer */ + dvb->frontend->callback = cx231xx_tuner_callback; + + dvb_attach(tda18271_attach, dev->dvb->frontend, + 0x60, + &dev->i2c_bus[dev->board.tuner_i2c_master].i2c_adap, + &hcw_tda18271_config); + + dev->cx231xx_reset_analog_tuner = NULL; + break; + case CX231XX_BOARD_PV_PLAYTV_USB_HYBRID: case CX231XX_BOARD_KWORLD_UB430_USB_HYBRID: |