[<prev] [next>] [day] [month] [year] [list]
Message-Id: <E1Ni8UK-00087I-Bw@www.linuxtv.org>
Date: Thu, 18 Feb 2010 16:40:24 +0100
From: Patch from Mauro Carvalho Chehab
<linuxtv-commits-bounces@...uxtv.org>
To: linuxtv-commits@...uxtv.org
Cc: Mocean Laboratories <info@...ean-labs.com>,
Randy Dunlap <randy.dunlap@...cle.com>,
Mauro Carvalho Chehab <mchehab@...hat.com>,
linux-kernel@...r.kernel.org, Kang Yong <kangyong@...egent.com>,
Huang Shijie <shijie8@...il.com>,
Zhang Xiaobing <xbzhang@...egent.com>,
Randy Dunlap <randy.dunlap@...cle.com>,
Mauro Carvalho Chehab <mchehab@...hat.com>,
Richard Rojfors <richard.rojfors@...agicore.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Samuel Ortiz <sameo@...ux.intel.com>,
Randy Dunlap <randy.dunlap@...cle.com>,
Mauro Carvalho Chehab <mchehab@...hat.com>,
Mauro Carvalho Chehab <mchehab@...hat.com>,
Mauro Carvalho Chehab <mchehab@...hat.com>
Subject: [git:v4l-dvb/master] V4L/DVB: tm6000: only register after initialized
From: Mauro Carvalho Chehab <mchehab@...hat.com>
Udev calls an utility when it senses a v4l device. So, register needs
to be delayed, otherwise it may cause block conditions.
Signed-off-by: Mauro Carvalho Chehab <mchehab@...hat.com>
drivers/staging/tm6000/tm6000-cards.c | 11 ++++++-----
1 files changed, 6 insertions(+), 5 deletions(-)
---
http://git.linuxtv.org/v4l-dvb.git?a=commit;h=8509e90e868c7eb832a34435e5be284bfce545f7
diff --git a/drivers/staging/tm6000/tm6000-cards.c b/drivers/staging/tm6000/tm6000-cards.c
index ff04bba..8297801 100644
--- a/drivers/staging/tm6000/tm6000-cards.c
+++ b/drivers/staging/tm6000/tm6000-cards.c
@@ -453,11 +453,6 @@ static int tm6000_init_dev(struct tm6000_core *dev)
if (rc<0)
goto err;
- /* register and initialize V4L2 */
- rc=tm6000_v4l2_register(dev);
- if (rc<0)
- goto err;
-
/* Default values for STD and resolutions */
dev->width = 720;
dev->height = 480;
@@ -480,12 +475,18 @@ static int tm6000_init_dev(struct tm6000_core *dev)
v4l2_i2c_new_subdev(&dev->v4l2_dev, &dev->i2c_adap,
"tvaudio", "tvaudio", I2C_ADDR_TDA9874, NULL);
+ /* register and initialize V4L2 */
+ rc=tm6000_v4l2_register(dev);
+ if (rc<0)
+ goto err;
+
if(dev->caps.has_dvb) {
dev->dvb = kzalloc(sizeof(*(dev->dvb)), GFP_KERNEL);
if(!dev->dvb) {
rc = -ENOMEM;
goto err2;
}
+
#ifdef CONFIG_VIDEO_TM6000_DVB
rc = tm6000_dvb_register(dev);
if(rc < 0) {
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists