]> git.baikalelectronics.ru Git - kernel.git/commit
[media] gspca - main: Add endpoint direction test in alt_xfer
authorPatrice Chotard <patrice.chotard@sfr.fr>
Mon, 21 Mar 2011 19:58:56 +0000 (16:58 -0300)
committerMauro Carvalho Chehab <mchehab@redhat.com>
Tue, 22 Mar 2011 19:38:26 +0000 (16:38 -0300)
commit14d9539ace867ec9c00138854024367097d6513f
tree5372803a5702a4f92bd5f2774ffccc9fff2d4326
parentd73ed1b49f43d9940c3f0f04fed6861467152ffa
[media] gspca - main: Add endpoint direction test in alt_xfer

This patch fixes a bug in gspca, more precisely in alt_xfer().

This function looks for an input transfer endpoint in an alternate setting.
By default it returns the first endpoint corresponding to the transfer type
indicated in parameter.
But with some USB devices, the first endpoint corresponding to the transfer
type is not always an INPUT endpoint but an OUTPUT one.

This patch adds the endpoint direction test to be sure to return an INPUT endpoint

Signed-off-by: Patrice CHOTARD <patricechotard@free.fr>
Signed-off-by: Jean-François Moine <moinejf@free.fr>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/video/gspca/gspca.c