aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/em28xx/em28xx-dvb.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/media/video/em28xx/em28xx-dvb.c')
-rw-r--r--drivers/media/video/em28xx/em28xx-dvb.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/drivers/media/video/em28xx/em28xx-dvb.c b/drivers/media/video/em28xx/em28xx-dvb.c
index bcd3c371009b..cf1d8c3655fc 100644
--- a/drivers/media/video/em28xx/em28xx-dvb.c
+++ b/drivers/media/video/em28xx/em28xx-dvb.c
@@ -467,6 +467,7 @@ static int dvb_init(struct em28xx *dev)
467 } 467 }
468 dev->dvb = dvb; 468 dev->dvb = dvb;
469 469
470 mutex_lock(&dev->lock);
470 em28xx_set_mode(dev, EM28XX_DIGITAL_MODE); 471 em28xx_set_mode(dev, EM28XX_DIGITAL_MODE);
471 /* init frontend */ 472 /* init frontend */
472 switch (dev->model) { 473 switch (dev->model) {
@@ -506,6 +507,7 @@ static int dvb_init(struct em28xx *dev)
506 case EM2880_BOARD_TERRATEC_HYBRID_XS_FR: 507 case EM2880_BOARD_TERRATEC_HYBRID_XS_FR:
507 case EM2881_BOARD_PINNACLE_HYBRID_PRO: 508 case EM2881_BOARD_PINNACLE_HYBRID_PRO:
508 case EM2882_BOARD_DIKOM_DK300: 509 case EM2882_BOARD_DIKOM_DK300:
510 case EM2882_BOARD_KWORLD_VS_DVBT:
509 dvb->frontend = dvb_attach(zl10353_attach, 511 dvb->frontend = dvb_attach(zl10353_attach,
510 &em28xx_zl10353_xc3028_no_i2c_gate, 512 &em28xx_zl10353_xc3028_no_i2c_gate,
511 &dev->i2c_adap); 513 &dev->i2c_adap);
@@ -589,15 +591,16 @@ static int dvb_init(struct em28xx *dev)
589 if (result < 0) 591 if (result < 0)
590 goto out_free; 592 goto out_free;
591 593
592 em28xx_set_mode(dev, EM28XX_SUSPEND);
593 em28xx_info("Successfully loaded em28xx-dvb\n"); 594 em28xx_info("Successfully loaded em28xx-dvb\n");
594 return 0; 595ret:
596 em28xx_set_mode(dev, EM28XX_SUSPEND);
597 mutex_unlock(&dev->lock);
598 return result;
595 599
596out_free: 600out_free:
597 em28xx_set_mode(dev, EM28XX_SUSPEND);
598 kfree(dvb); 601 kfree(dvb);
599 dev->dvb = NULL; 602 dev->dvb = NULL;
600 return result; 603 goto ret;
601} 604}
602 605
603static int dvb_fini(struct em28xx *dev) 606static int dvb_fini(struct em28xx *dev)