linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] vivi driver works only as first device
       [not found] <20071203225610.GS17496@vidsoft.de>
@ 2007-12-06 22:06 ` Gregor Jasny
  2007-12-10  7:08   ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 4+ messages in thread
From: Gregor Jasny @ 2007-12-06 22:06 UTC (permalink / raw)
  To: video4linux-list
  Cc: Ted Walther, John Sokol, Mauro Carvalho Chehab, linux-kernel

From: Gregor Jasny <gjasny@web.de>

When the vivi driver allocates a video device, video_register_device() stores the
allocated device minor inside the vivi structure. But when the device node is opened,
the file minor number is compared to the minor in the device list. So this patch
copies the allocated minor in the device list, too.

Without this patch it is impossible to use the vivi driver mith minors greater than zero. 

Signed-off-by: Gregor Jasny <gjasny@web.de>
---
diff --git a/drivers/media/video/vivi.c b/drivers/media/video/vivi.c
index ee73dc7..f4e533a 100644
--- a/drivers/media/video/vivi.c
+++ b/drivers/media/video/vivi.c
@@ -1175,6 +1175,9 @@ static int __init vivi_init(void)
 
 	ret = video_register_device(&vivi, VFL_TYPE_GRABBER, video_nr);
 	printk(KERN_INFO "Video Technology Magazine Virtual Video Capture Board (Load status: %d)\n", ret);
+
+	dev->vfd.minor = vivi.minor;
+
 	return ret;
 }
 

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] vivi driver works only as first device
  2007-12-06 22:06 ` [PATCH] vivi driver works only as first device Gregor Jasny
@ 2007-12-10  7:08   ` Mauro Carvalho Chehab
  2008-01-06 22:47     ` Gregor Jasny
  0 siblings, 1 reply; 4+ messages in thread
From: Mauro Carvalho Chehab @ 2007-12-10  7:08 UTC (permalink / raw)
  To: Gregor Jasny; +Cc: video4linux-list, Ted Walther, John Sokol, linux-kernel

Hi Gregor,
Em Qui, 2007-12-06 às 23:06 +0100, Gregor Jasny escreveu:
> From: Gregor Jasny <gjasny@web.de>
> 
> When the vivi driver allocates a video device, video_register_device() stores the
> allocated device minor inside the vivi structure. But when the device node is opened,
> the file minor number is compared to the minor in the device list. So this patch
> copies the allocated minor in the device list, too.

Thanks for the report. Instead of applying your patch, I decided to
better analyze the issue, fixing it with the proper solution. The issue
is that vivi_register changes iminor, but this change were not properly
returned to the driver.

-- 
Cheers,
Mauro


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] vivi driver works only as first device
  2007-12-10  7:08   ` Mauro Carvalho Chehab
@ 2008-01-06 22:47     ` Gregor Jasny
  2008-01-07  9:46       ` Mauro Carvalho Chehab
  0 siblings, 1 reply; 4+ messages in thread
From: Gregor Jasny @ 2008-01-06 22:47 UTC (permalink / raw)
  To: Mauro Carvalho Chehab; +Cc: Gregor Jasny, linux-kernel

On Dec 10, 2007 8:08 AM, Mauro Carvalho Chehab <mchehab@infradead.org> wrote:
> Thanks for the report. Instead of applying your patch, I decided to
> better analyze the issue, fixing it with the proper solution. The issue
> is that vivi_register changes iminor, but this change were not properly
> returned to the driver.

Any chance to push this into 2.6.24?

Gregor

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] vivi driver works only as first device
  2008-01-06 22:47     ` Gregor Jasny
@ 2008-01-07  9:46       ` Mauro Carvalho Chehab
  0 siblings, 0 replies; 4+ messages in thread
From: Mauro Carvalho Chehab @ 2008-01-07  9:46 UTC (permalink / raw)
  To: Gregor Jasny; +Cc: Gregor Jasny, linux-kernel

On Sun, 6 Jan 2008 23:47:19 +0100
"Gregor Jasny" <gjasny@googlemail.com> wrote:

> On Dec 10, 2007 8:08 AM, Mauro Carvalho Chehab <mchehab@infradead.org> wrote:
> > Thanks for the report. Instead of applying your patch, I decided to
> > better analyze the issue, fixing it with the proper solution. The issue
> > is that vivi_register changes iminor, but this change were not properly
> > returned to the driver.
> 
> Any chance to push this into 2.6.24?

I've scheduled this patch for inclusion at 2.6.25-rc.

Cheers,
Mauro

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-01-07  9:46 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20071203225610.GS17496@vidsoft.de>
2007-12-06 22:06 ` [PATCH] vivi driver works only as first device Gregor Jasny
2007-12-10  7:08   ` Mauro Carvalho Chehab
2008-01-06 22:47     ` Gregor Jasny
2008-01-07  9:46       ` Mauro Carvalho Chehab

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).