From: Jean-Francois Moine <moinejf@free.fr>
To: "Hans de Goede" <hdegoede@redhat.com>,
"Németh Márton" <nm127@freemail.hu>
Cc: V4L Mailing List <linux-media@vger.kernel.org>
Subject: Re: [PATCH 1/2] gspca pac7302: allow controlling LED separately
Date: Sat, 27 Feb 2010 10:04:00 +0100 [thread overview]
Message-ID: <20100227100400.05fede81@tele> (raw)
In-Reply-To: <4B88CF6C.2070703@redhat.com>
On Sat, 27 Feb 2010 08:53:16 +0100
Hans de Goede <hdegoede@redhat.com> wrote:
> This is true for a lot of cameras, so if we are going to add a way to
> support control of the LED separate of the streaming state, we
> should do that at the gspca_main level, and let sub drivers which
> support this export a set_led callback function.
>
> I must say I personally don't see much of a use case for this feature,
> but I believe JF Moine does, so I'll leave further comments and
> review of this to JF. I do believe it is important that if we go this
> way we do so add the gspca_main level.
Hi,
I don't like this mechanism to switch on or off the webcam LEDs. Here
are some arguments (some of them were sent last year to the list):
1) End users.
Many Linux users don't know the kernel internals, nor which of the too
many applications they should use to make their devices work.
Actually, there are a few X11 programs in common Linux distros which can
handle the webcam parameters: I just know about vlc and v4l2ucp, and
they don't even handle the VIDIOC_G_JPEGCOMP and VIDIOC_S_JPEGCOMP
ioctls which are part of the v4l2 API.
The LED interface uses the /sys file system. Will the webcam programs
offer access to this interface? I don't believe it. So, the users will
have to search how they can switch on or off the LEDs of their webcams,
and then, when found, they should start a X terminal and run a command
to do the job!
On the other hand, a webcam LED control, whether general or private, is
available in the graphical interface as soon as the driver offers it.
2) Memory overhead.
Using the led class adds more kernel code and asks the webcam drivers
to create a new device. Also, the function called for changing the LED
brighness cannot sleep, so the use a workqueue is required.
On contrary, with a webcam control, only one byte (for 8 LEDs) is added
to the webcam structure and the change is immediatly done in the ioctl.
3) Development.
If nobody wants a LED control in the v4l2 interface, I think the code
added to access the led class could be splitted between the different
subsystem. For example, the workqueue handling could be done in the led
class itself...
Cheers.
--
Ken ar c'hentañ | ** Breizh ha Linux atav! **
Jef | http://moinejf.free.fr/
next prev parent reply other threads:[~2010-02-27 9:03 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-02-24 6:52 [PATCH 1/2] gspca pac7302: add LED control Németh Márton
2010-02-24 7:22 ` Jean-Francois Moine
2010-02-27 0:20 ` [PATCH 1/2] gspca pac7302: allow controlling LED separately Németh Márton
2010-02-27 7:53 ` Hans de Goede
2010-02-27 8:22 ` Németh Márton
2010-02-27 9:04 ` Jean-Francois Moine [this message]
2010-02-27 15:35 ` Németh Márton
2010-02-27 19:12 ` Hans de Goede
2010-02-27 20:00 ` Jean-Francois Moine
2010-02-27 8:17 ` Németh Márton
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20100227100400.05fede81@tele \
--to=moinejf@free.fr \
--cc=hdegoede@redhat.com \
--cc=linux-media@vger.kernel.org \
--cc=nm127@freemail.hu \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox