aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorMárton Németh <nm127@freemail.hu>2009-11-09 05:08:04 -0500
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-12-05 15:41:47 -0500
commit4d0fc03a76d96fff0cf6c815702ae04896b74cde (patch)
treed5883fe52865b0557f92aa5d487c96ea16a02bb0 /drivers
parentf8b0bca1a7ea8479490bcc06835ccbf590ba2c4e (diff)
V4L/DVB (13418): gspca - pac7311: Stop sending URBs on first error.
Signed-off-by: Márton Németh <nm127@freemail.hu> Signed-off-by: Jean-Francois Moine <moinejf@free.fr> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/media/video/gspca/pac7311.c31
1 files changed, 21 insertions, 10 deletions
diff --git a/drivers/media/video/gspca/pac7311.c b/drivers/media/video/gspca/pac7311.c
index c3e1f80351ad..1a27da00ccc1 100644
--- a/drivers/media/video/gspca/pac7311.c
+++ b/drivers/media/video/gspca/pac7311.c
@@ -569,16 +569,27 @@ static int sd_start(struct gspca_dev *gspca_dev)
569 569
570static void sd_stopN(struct gspca_dev *gspca_dev) 570static void sd_stopN(struct gspca_dev *gspca_dev)
571{ 571{
572 reg_w(gspca_dev, 0xff, 0x04); 572 int ret;
573 reg_w(gspca_dev, 0x27, 0x80); 573
574 reg_w(gspca_dev, 0x28, 0xca); 574 ret = reg_w(gspca_dev, 0xff, 0x04);
575 reg_w(gspca_dev, 0x29, 0x53); 575 if (0 <= ret)
576 reg_w(gspca_dev, 0x2a, 0x0e); 576 ret = reg_w(gspca_dev, 0x27, 0x80);
577 reg_w(gspca_dev, 0xff, 0x01); 577 if (0 <= ret)
578 reg_w(gspca_dev, 0x3e, 0x20); 578 ret = reg_w(gspca_dev, 0x28, 0xca);
579 reg_w(gspca_dev, 0x78, 0x44); /* Bit_0=start stream, Bit_6=LED */ 579 if (0 <= ret)
580 reg_w(gspca_dev, 0x78, 0x44); /* Bit_0=start stream, Bit_6=LED */ 580 ret = reg_w(gspca_dev, 0x29, 0x53);
581 reg_w(gspca_dev, 0x78, 0x44); /* Bit_0=start stream, Bit_6=LED */ 581 if (0 <= ret)
582 ret = reg_w(gspca_dev, 0x2a, 0x0e);
583 if (0 <= ret)
584 ret = reg_w(gspca_dev, 0xff, 0x01);
585 if (0 <= ret)
586 ret = reg_w(gspca_dev, 0x3e, 0x20);
587 if (0 <= ret)
588 ret = reg_w(gspca_dev, 0x78, 0x44); /* Bit_0=start stream, Bit_6=LED */
589 if (0 <= ret)
590 ret = reg_w(gspca_dev, 0x78, 0x44); /* Bit_0=start stream, Bit_6=LED */
591 if (0 <= ret)
592 ret = reg_w(gspca_dev, 0x78, 0x44); /* Bit_0=start stream, Bit_6=LED */
582} 593}
583 594
584/* called on streamoff with alt 0 and on disconnect for 7311 */ 595/* called on streamoff with alt 0 and on disconnect for 7311 */