summaryrefslogtreecommitdiff
path: root/drivers/media/usb/em28xx/em28xx.h
diff options
context:
space:
mode:
authorFrank Schaefer <fschaefer.oss@googlemail.com>2014-01-13 22:02:06 (GMT)
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-01-14 21:24:38 (GMT)
commit961717b41bc1103dcd30d293fd689a614fbfa90c (patch)
treefdff0e05b3a227f1454d6550de6607373b169311 /drivers/media/usb/em28xx/em28xx.h
parent8068eb885a13e33244a8692c880eca478b467d9d (diff)
downloadlinux-961717b41bc1103dcd30d293fd689a614fbfa90c.tar.xz
[media] em28xx: fix usb alternate setting for analog and digital video endpoints > 0
The current code assumes that the analog + digital video endpoints are always at interface number 0 when changing the alternate setting. This seems to work fine for most existing devices. However, at least the SpeedLink VAD Laplace webcam has the video endpoint on interface number 3 (which fortunately doesn't cause any trouble because ist uses bulk transfers only). We already consider the actual interface number for audio endpoints, so rename the the audio_ifnum variable and use it for all device types. Also get get rid of a pointless (ifnum < 0) in em28xx-audio. Signed-off-by: Frank Schäfer <fschaefer.oss@googlemail.com> Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
Diffstat (limited to 'drivers/media/usb/em28xx/em28xx.h')
-rw-r--r--drivers/media/usb/em28xx/em28xx.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/media/usb/em28xx/em28xx.h b/drivers/media/usb/em28xx/em28xx.h
index 10b8172..32d8a4b 100644
--- a/drivers/media/usb/em28xx/em28xx.h
+++ b/drivers/media/usb/em28xx/em28xx.h
@@ -549,8 +549,6 @@ struct em28xx {
unsigned int has_alsa_audio:1;
unsigned int is_audio_only:1;
- int audio_ifnum;
-
struct v4l2_device v4l2_dev;
struct v4l2_ctrl_handler ctrl_handler;
struct v4l2_clk *clk;
@@ -664,6 +662,7 @@ struct em28xx {
/* usb transfer */
struct usb_device *udev; /* the usb device */
+ u8 ifnum; /* number of the assigned usb interface */
u8 analog_ep_isoc; /* address of isoc endpoint for analog */
u8 analog_ep_bulk; /* address of bulk endpoint for analog */
u8 dvb_ep_isoc; /* address of isoc endpoint for DVB */