aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/au0828/au0828-dvb.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/au0828/au0828-dvb.c')
-rw-r--r--drivers/media/video/au0828/au0828-dvb.c47
1 files changed, 42 insertions, 5 deletions
diff --git a/drivers/media/video/au0828/au0828-dvb.c b/drivers/media/video/au0828/au0828-dvb.c
index ba94be7e0ac1..f0fcdb4769d7 100644
--- a/drivers/media/video/au0828/au0828-dvb.c
+++ b/drivers/media/video/au0828/au0828-dvb.c
@@ -36,11 +36,39 @@ DVB_DEFINE_MOD_OPT_ADAPTER_NR(adapter_nr);
36#define _AU0828_BULKPIPE 0x83 36#define _AU0828_BULKPIPE 0x83
37#define _BULKPIPESIZE 0xe522 37#define _BULKPIPESIZE 0xe522
38 38
39static u8 hauppauge_hvr950q_led_states[] = {
40 0x00, /* off */
41 0x02, /* yellow */
42 0x04, /* green */
43};
44
45static struct au8522_led_config hauppauge_hvr950q_led_cfg = {
46 .gpio_output = 0x00e0,
47 .gpio_output_enable = 0x6006,
48 .gpio_output_disable = 0x0660,
49
50 .gpio_leds = 0x00e2,
51 .led_states = hauppauge_hvr950q_led_states,
52 .num_led_states = sizeof(hauppauge_hvr950q_led_states),
53
54 .vsb8_strong = 20 /* dB */ * 10,
55 .qam64_strong = 25 /* dB */ * 10,
56 .qam256_strong = 32 /* dB */ * 10,
57};
58
39static struct au8522_config hauppauge_hvr950q_config = { 59static struct au8522_config hauppauge_hvr950q_config = {
40 .demod_address = 0x8e >> 1, 60 .demod_address = 0x8e >> 1,
41 .status_mode = AU8522_DEMODLOCKING, 61 .status_mode = AU8522_DEMODLOCKING,
42 .qam_if = AU8522_IF_6MHZ, 62 .qam_if = AU8522_IF_6MHZ,
43 .vsb_if = AU8522_IF_6MHZ, 63 .vsb_if = AU8522_IF_6MHZ,
64 .led_cfg = &hauppauge_hvr950q_led_cfg,
65};
66
67static struct au8522_config fusionhdtv7usb_config = {
68 .demod_address = 0x8e >> 1,
69 .status_mode = AU8522_DEMODLOCKING,
70 .qam_if = AU8522_IF_6MHZ,
71 .vsb_if = AU8522_IF_6MHZ,
44}; 72};
45 73
46static struct au8522_config hauppauge_woodbury_config = { 74static struct au8522_config hauppauge_woodbury_config = {
@@ -53,7 +81,6 @@ static struct au8522_config hauppauge_woodbury_config = {
53static struct xc5000_config hauppauge_hvr950q_tunerconfig = { 81static struct xc5000_config hauppauge_hvr950q_tunerconfig = {
54 .i2c_address = 0x61, 82 .i2c_address = 0x61,
55 .if_khz = 6000, 83 .if_khz = 6000,
56 .tuner_callback = au0828_tuner_callback
57}; 84};
58 85
59static struct mxl5007t_config mxl5007t_hvr950q_config = { 86static struct mxl5007t_config mxl5007t_hvr950q_config = {
@@ -353,14 +380,12 @@ int au0828_dvb_register(struct au0828_dev *dev)
353 switch (dev->board) { 380 switch (dev->board) {
354 case AU0828_BOARD_HAUPPAUGE_HVR850: 381 case AU0828_BOARD_HAUPPAUGE_HVR850:
355 case AU0828_BOARD_HAUPPAUGE_HVR950Q: 382 case AU0828_BOARD_HAUPPAUGE_HVR950Q:
356 case AU0828_BOARD_DVICO_FUSIONHDTV7:
357 dvb->frontend = dvb_attach(au8522_attach, 383 dvb->frontend = dvb_attach(au8522_attach,
358 &hauppauge_hvr950q_config, 384 &hauppauge_hvr950q_config,
359 &dev->i2c_adap); 385 &dev->i2c_adap);
360 if (dvb->frontend != NULL) 386 if (dvb->frontend != NULL)
361 dvb_attach(xc5000_attach, dvb->frontend, 387 dvb_attach(xc5000_attach, dvb->frontend, &dev->i2c_adap,
362 &dev->i2c_adap, 388 &hauppauge_hvr950q_tunerconfig);
363 &hauppauge_hvr950q_tunerconfig, dev);
364 break; 389 break;
365 case AU0828_BOARD_HAUPPAUGE_HVR950Q_MXL: 390 case AU0828_BOARD_HAUPPAUGE_HVR950Q_MXL:
366 dvb->frontend = dvb_attach(au8522_attach, 391 dvb->frontend = dvb_attach(au8522_attach,
@@ -380,6 +405,16 @@ int au0828_dvb_register(struct au0828_dev *dev)
380 0x60, &dev->i2c_adap, 405 0x60, &dev->i2c_adap,
381 &hauppauge_woodbury_tunerconfig); 406 &hauppauge_woodbury_tunerconfig);
382 break; 407 break;
408 case AU0828_BOARD_DVICO_FUSIONHDTV7:
409 dvb->frontend = dvb_attach(au8522_attach,
410 &fusionhdtv7usb_config,
411 &dev->i2c_adap);
412 if (dvb->frontend != NULL) {
413 dvb_attach(xc5000_attach, dvb->frontend,
414 &dev->i2c_adap,
415 &hauppauge_hvr950q_tunerconfig);
416 }
417 break;
383 default: 418 default:
384 printk(KERN_WARNING "The frontend of your DVB/ATSC card " 419 printk(KERN_WARNING "The frontend of your DVB/ATSC card "
385 "isn't supported yet\n"); 420 "isn't supported yet\n");
@@ -390,6 +425,8 @@ int au0828_dvb_register(struct au0828_dev *dev)
390 __func__); 425 __func__);
391 return -1; 426 return -1;
392 } 427 }
428 /* define general-purpose callback pointer */
429 dvb->frontend->callback = au0828_tuner_callback;
393 430
394 /* register everything */ 431 /* register everything */
395 ret = dvb_register(dev); 432 ret = dvb_register(dev);