linux-media.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Andreas Pape <ap@ca-pape.de>
To: linux-media@vger.kernel.org, kieran.bingham@ideasonboard.com
Cc: Andreas Pape <ap@ca-pape.de>
Subject: [PATCH 2/3] media: stkwebcam: Bugfix for not correctly initialized camera
Date: Fri, 23 Nov 2018 17:14:53 +0100	[thread overview]
Message-ID: <20181123161454.3215-3-ap@ca-pape.de> (raw)
In-Reply-To: <20181123161454.3215-1-ap@ca-pape.de>

stk_start_stream can only be called successfully if stk_initialise and
stk_setup_format are called before. When using e.g. cheese it was observed
that stk_initialise and stk_setup_format have not been called before which
leads to no picture in that software whereas other tools like guvcview
worked flawlessly. This patch solves the issue when using e.g. cheese.

Signed-off-by: Andreas Pape <ap@ca-pape.de>
---
 drivers/media/usb/stkwebcam/stk-webcam.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/media/usb/stkwebcam/stk-webcam.c b/drivers/media/usb/stkwebcam/stk-webcam.c
index e61427e50525..c64928e36a5a 100644
--- a/drivers/media/usb/stkwebcam/stk-webcam.c
+++ b/drivers/media/usb/stkwebcam/stk-webcam.c
@@ -1155,6 +1155,8 @@ static int stk_vidioc_streamon(struct file *filp,
 	if (dev->sio_bufs == NULL)
 		return -EINVAL;
 	dev->sequence = 0;
+	stk_initialise(dev);
+	stk_setup_format(dev);
 	return stk_start_stream(dev);
 }
 
-- 
2.17.1

  parent reply	other threads:[~2018-11-24  3:00 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-23 16:14 [PATCH 0/3] Fix for webcam issues with ASUS A6VM Andreas Pape
2018-11-23 16:14 ` [PATCH 1/3] media: stkwebcam: Support for ASUS A6VM notebook added Andreas Pape
2018-11-26 12:48   ` Kieran Bingham
2018-11-30 15:07     ` Andreas Pape
2018-11-23 16:14 ` Andreas Pape [this message]
2018-11-26 12:48   ` [PATCH 2/3] media: stkwebcam: Bugfix for not correctly initialized camera Kieran Bingham
2018-11-30 14:58     ` Andreas Pape
2018-12-05 18:56       ` Mauro Carvalho Chehab
2018-12-05 19:08         ` Mauro Carvalho Chehab
2018-11-23 16:14 ` [PATCH 3/3] media: stkwebcam: Bugfix for wrong return values Andreas Pape
2018-11-26 12:33   ` Kieran Bingham

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=20181123161454.3215-3-ap@ca-pape.de \
    --to=ap@ca-pape.de \
    --cc=kieran.bingham@ideasonboard.com \
    --cc=linux-media@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).