aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/cx88
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@infradead.org>2008-04-11 10:29:44 -0400
committerMauro Carvalho Chehab <mchehab@infradead.org>2008-04-24 13:08:00 -0400
commit9950c1b5b4b86d4aae12853c2f0a0ef11d976764 (patch)
tree50ad703f54ea15f738dfc54c471b89fcdeca7dc0 /drivers/media/video/cx88
parentfb7b37cf913c19dbdbb9bf3e653924e126b4007e (diff)
V4L/DVB (7537): cx88/saa7134: Fix: avoid OOPS on module unload
If frontend is not attached, both cx88-dvb and saa7134-dvb don't register DVB. However, dvb unregister were inconditionally called. Due to that, an OOPS is generated. Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Diffstat (limited to 'drivers/media/video/cx88')
-rw-r--r--drivers/media/video/cx88/cx88-dvb.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/media/video/cx88/cx88-dvb.c b/drivers/media/video/cx88/cx88-dvb.c
index 8fc929eb47ba..e83d9869e68b 100644
--- a/drivers/media/video/cx88/cx88-dvb.c
+++ b/drivers/media/video/cx88/cx88-dvb.c
@@ -951,7 +951,8 @@ static int cx8802_dvb_remove(struct cx8802_driver *drv)
951 struct cx8802_dev *dev = drv->core->dvbdev; 951 struct cx8802_dev *dev = drv->core->dvbdev;
952 952
953 /* dvb */ 953 /* dvb */
954 videobuf_dvb_unregister(&dev->dvb); 954 if (dev->dvb.frontend)
955 videobuf_dvb_unregister(&dev->dvb);
955 956
956 vp3054_i2c_remove(dev); 957 vp3054_i2c_remove(dev);
957 958