From: Scott Jiang <scott.jiang.linux@gmail.com>
To: Hans Verkuil <hans.verkuil@cisco.com>,
Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: <linux-media@vger.kernel.org>, Scott Jiang <scott.jiang.linux@gmail.com>
Subject: [PATCH] v4l2: don't warn before we release buffer
Date: Thu, 24 Jul 2014 11:53:31 +0800 [thread overview]
Message-ID: <1406174011-13600-1-git-send-email-scott.jiang.linux@gmail.com> (raw)
In fact we only need to give a warning if the driver still use the
buffer after we release all queued buffers.
Signed-off-by: Scott Jiang <scott.jiang.linux@gmail.com>
---
drivers/media/v4l2-core/videobuf2-core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/media/v4l2-core/videobuf2-core.c b/drivers/media/v4l2-core/videobuf2-core.c
index 7c4489c..fa5dd73 100644
--- a/drivers/media/v4l2-core/videobuf2-core.c
+++ b/drivers/media/v4l2-core/videobuf2-core.c
@@ -2112,7 +2112,7 @@ static void __vb2_queue_cancel(struct vb2_queue *q)
if (q->start_streaming_called)
call_void_qop(q, stop_streaming, q);
- if (WARN_ON(atomic_read(&q->owned_by_drv_count))) {
+ if (atomic_read(&q->owned_by_drv_count)) {
for (i = 0; i < q->num_buffers; ++i)
if (q->bufs[i]->state == VB2_BUF_STATE_ACTIVE)
vb2_buffer_done(q->bufs[i], VB2_BUF_STATE_ERROR);
--
1.7.9.5
next reply other threads:[~2014-07-23 3:57 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-24 3:53 Scott Jiang [this message]
2014-07-23 6:00 ` [PATCH] v4l2: don't warn before we release buffer Hans Verkuil
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=1406174011-13600-1-git-send-email-scott.jiang.linux@gmail.com \
--to=scott.jiang.linux@gmail.com \
--cc=hans.verkuil@cisco.com \
--cc=laurent.pinchart@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