aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video
diff options
context:
space:
mode:
authorHartmut Hackmann <hartmut.hackmann@t-online.de>2007-04-27 11:31:16 -0400
committerMauro Carvalho Chehab <mchehab@infradead.org>2007-04-27 14:43:38 -0400
commit1c4f76abb85918646eed5dee0b26744cc49fd1da (patch)
tree770660479480422f9d59fc248702e1014cdf597d /drivers/media/video
parent11f65106adb25a9ef5b6d8911267b2365c97a759 (diff)
V4L/DVB (5321): Saa7134-dvb: initialize the dvb frontend in dvb_init
The hardware is completely initialized afterwards, especially the tda10046 has its firmware - which is also necessary in analog mode of some hybrid boards. Calling the sleep function afterwards saves power and definitely puts hybrid boards into analog mode without additional code elsewere. Signed-off-by: Hartmut Hackmann <hartmut.hackmann@t-online.de> Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video')
-rw-r--r--drivers/media/video/saa7134/saa7134-dvb.c14
1 files changed, 13 insertions, 1 deletions
diff --git a/drivers/media/video/saa7134/saa7134-dvb.c b/drivers/media/video/saa7134/saa7134-dvb.c
index bbb1a1e55af2..6f98ec40553c 100644
--- a/drivers/media/video/saa7134/saa7134-dvb.c
+++ b/drivers/media/video/saa7134/saa7134-dvb.c
@@ -937,6 +937,7 @@ static struct nxt200x_config kworldatsc110 = {
937static int dvb_init(struct saa7134_dev *dev) 937static int dvb_init(struct saa7134_dev *dev)
938{ 938{
939 char *board_name; 939 char *board_name;
940 int ret;
940 /* init struct videobuf_dvb */ 941 /* init struct videobuf_dvb */
941 dev->ts.nr_bufs = 32; 942 dev->ts.nr_bufs = 32;
942 dev->ts.nr_packets = 32*4; 943 dev->ts.nr_packets = 32*4;
@@ -1145,7 +1146,18 @@ static int dvb_init(struct saa7134_dev *dev)
1145 } 1146 }
1146 1147
1147 /* register everything else */ 1148 /* register everything else */
1148 return videobuf_dvb_register(&dev->dvb, THIS_MODULE, dev, &dev->pci->dev); 1149 ret = videobuf_dvb_register(&dev->dvb, THIS_MODULE, dev, &dev->pci->dev);
1150
1151 /* this sequence is necessary to make the tda1004x load its firmware
1152 * and to enter analog mode of hybrid boards
1153 */
1154 if (!ret) {
1155 if (dev->dvb.frontend->ops.init)
1156 dev->dvb.frontend->ops.init(dev->dvb.frontend);
1157 if (dev->dvb.frontend->ops.sleep)
1158 dev->dvb.frontend->ops.sleep(dev->dvb.frontend);
1159 }
1160 return ret;
1149} 1161}
1150 1162
1151static int dvb_fini(struct saa7134_dev *dev) 1163static int dvb_fini(struct saa7134_dev *dev)