All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Theodore Kilgore <kilgota@banach.math.auburn.edu>
Cc: Mauro Carvalho Chehab <mchehab@redhat.com>,
	Adam Baker <linux@baker-net.org.uk>,
	workshop-2011@linuxtv.org,
	Linux Media Mailing List <linux-media@vger.kernel.org>
Subject: Re: [Workshop-2011] Media Subsystem Workshop 2011
Date: Tue, 09 Aug 2011 09:30:20 +0200	[thread overview]
Message-ID: <4E40E20C.2090001@redhat.com> (raw)
In-Reply-To: <alpine.LNX.2.00.1108081208080.21409@banach.math.auburn.edu>

Hi,

On 08/08/2011 07:39 PM, Theodore Kilgore wrote:
>
>
> On Mon, 8 Aug 2011, Mauro Carvalho Chehab wrote:
>

<snip>

> Mauro,
>
> In fact none of the currently known and supported cameras are using PTP.
> All of them are proprietary. They have a rather intimidating set of
> differences in functionality, too. Namely, some of them have an
> isochronous endpoint, and some of them rely exclusively upon bulk
> transport. Some of them have a well developed set of internal capabilities
> as far as handling still photos are concerned. I mean, such things as the
> ability to download a single photo, selected at random from the set of
> photos on the camera, and some do not, requiring that the "ability" to do
> this is emulated in software -- by first downloading all previously listed
> photos and sending the data to /dev/null, then downloading the desired
> photo and saving it. Some of them permit deletion of individual photos, or
> all photos, and some do not. For some of them it is even true, as I have
> previously mentioned, that the USB command string which will delete all
> photos is the same command used for starting the camera in streaming mode.
>
> But the point here is that these cameras are all different from one
> another, depending upon chipset and even, sometimes, upon firmware
> or chipset version. The still camera abilities and limitations of all of
> them are pretty much worked out in libgphoto2. My suggestion would be that
> the libgphoto2 support libraries for these cameras ought to be left the
> hell alone, except for some changes in, for example, how the camera is
> accessed in the first place (through libusb or through a kernel device) in
> order to address adequately the need to support both modes. I know what is
> in those libgphoto2 drivers because I wrote them. I can definitely promise
> that to move all of that functionality over into kernel modules would be a
> nightmare and would moreover greatly contribute to kernel bloat. You
> really don't want to go there.

I strongly disagree with this. The libgphoto2 camlibs (drivers) for these
cameras handle a number of different tasks:

1) Talking to the camera getting binary blobs out of them (be it a PAT or
    some data)
2) Interpreting said blobs
3) Converting the data parts to pictures doing post processing, etc.

I'm not suggesting to move all of this to the kernel driver, we just need
to move part 1. to the kernel driver. This is not rocket science.

We currently have a really bad situation were drivers are fighting
for the same device. The problem here is that these devices are not
only one device on the physical level, but also one device on the
logical level (IOW they have only 1 usb interface).

It is time to quit thinking in band-aides and solve this properly,
1 logical device means it gets 1 driver.

This may be an approach which means some more work then others, but
I believe in the end that doing it right is worth the effort.

As for Mauro's resource locking patches, these won't work because
the assume both drivers are active at the same time, which is simply
not true. Only 1 driver can be bound to the interface at a time, and
when switching from the gspca driver to the usbfs driver, gspca will
see an unplug which is indistinguishable from a real device unplug.

More over a kernel only solution without libgphoto changes won't solve
the problem of a libgphoto app keeping the device open locking out
streaming.

Regards,

Hans

  parent reply	other threads:[~2011-08-09  7:28 UTC|newest]

Thread overview: 64+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-03 17:21 Media Subsystem Workshop 2011 Mauro Carvalho Chehab
2011-08-03 17:45 ` Mauro Carvalho Chehab
2011-08-08  6:22   ` Hans Verkuil
2011-08-08 13:25     ` Mauro Carvalho Chehab
2011-08-08 15:25       ` Hans Verkuil
2011-08-11 17:49       ` Rémi Denis-Courmont
2011-08-11 19:00         ` Mauro Carvalho Chehab
2011-08-03 19:53 ` Theodore Kilgore
2011-08-03 20:36   ` Mauro Carvalho Chehab
2011-08-03 23:20     ` Theodore Kilgore
2011-08-04 12:34       ` Mauro Carvalho Chehab
2011-08-04 18:37         ` Theodore Kilgore
2011-08-04 19:11           ` Mauro Carvalho Chehab
2011-08-04 21:16             ` Theodore Kilgore
2011-08-04 21:58               ` Mauro Carvalho Chehab
2011-08-04 22:57                 ` Theodore Kilgore
2011-08-05  7:02         ` [Workshop-2011] " Hans de Goede
2011-08-05 17:13           ` Theodore Kilgore
2011-08-07 22:53           ` Adam Baker
2011-08-08  2:26             ` Theodore Kilgore
2011-08-08 13:45               ` Mauro Carvalho Chehab
2011-08-08 17:39                 ` Theodore Kilgore
2011-08-08 18:39                   ` Mauro Carvalho Chehab
2011-08-08 19:32                     ` Theodore Kilgore
2011-08-08 20:07                       ` Mauro Carvalho Chehab
2011-08-08 20:24                         ` Adam Baker
2011-08-08 20:43                           ` Theodore Kilgore
2011-08-09  7:30                   ` Hans de Goede [this message]
2011-08-09 17:10                     ` Theodore Kilgore
2011-08-09 20:30                       ` Hans de Goede
2011-08-10  0:34                         ` Theodore Kilgore
2011-08-10  7:02                           ` Hans de Goede
2011-08-08 20:33                 ` Adam Baker
2011-08-08 21:06                   ` Theodore Kilgore
2011-08-09  7:37                     ` Hans de Goede
2011-08-09 19:06                       ` Theodore Kilgore
2011-08-08  2:56             ` Theodore Kilgore
2011-08-08  7:53             ` Hans de Goede
2011-08-04 11:39     ` Hans de Goede
2011-08-04 12:40       ` Mauro Carvalho Chehab
2011-08-04 16:40         ` Jean-Francois Moine
2011-08-04 19:02           ` Guennadi Liakhovetski
2011-08-04 20:33             ` Mauro Carvalho Chehab
2011-08-04 21:38               ` Adam Baker
2011-08-04 21:49                 ` Mauro Carvalho Chehab
2011-08-04 22:30                 ` Theodore Kilgore
2011-08-04 19:05           ` Theodore Kilgore
2011-08-04 20:35             ` Adam Baker
2011-08-04 21:55               ` Theodore Kilgore
2011-08-04 23:04                 ` Adam Baker
2011-08-05  0:01                   ` Theodore Kilgore
2011-08-07 22:30                     ` Adam Baker
2011-08-07 23:19                       ` Alan Stern
2011-08-08  0:30                         ` Adam Baker
2011-08-08 14:38                           ` Alan Stern
2011-08-08  3:33                         ` Theodore Kilgore
2011-08-08 14:55                           ` Alan Stern
2011-08-08 18:14                             ` Theodore Kilgore
2011-08-08 19:22                               ` Alan Stern
2011-08-08 19:58                                 ` Theodore Kilgore
2011-08-08 20:33                                   ` Alan Stern
2011-08-04 18:55         ` Theodore Kilgore
2011-08-11 10:16 ` Sakari Ailus
2011-08-11 11:03   ` Mauro Carvalho Chehab

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=4E40E20C.2090001@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=kilgota@banach.math.auburn.edu \
    --cc=linux-media@vger.kernel.org \
    --cc=linux@baker-net.org.uk \
    --cc=mchehab@redhat.com \
    --cc=workshop-2011@linuxtv.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.