]> www.infradead.org Git - users/jedix/linux-maple.git/commit
media: videobuf2-v4l2: drop WARN_ON in vb2_warn_zero_bytesused()
authorHans Verkuil <hverkuil-cisco@xs4all.nl>
Mon, 19 Nov 2018 15:33:44 +0000 (10:33 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 23 Mar 2019 13:35:17 +0000 (14:35 +0100)
commit8d6df5097c0005320ab6f3cd8dda2ef31db6c6d1
tree97cb037d4fd573dc97e2273894444230aeff6435
parent4cf6ad0bf823a1acac199a976719278b7e30892d
media: videobuf2-v4l2: drop WARN_ON in vb2_warn_zero_bytesused()

commit 5e99456c20f712dcc13d9f6ca4278937d5367355 upstream.

Userspace shouldn't set bytesused to 0 for output buffers.
vb2_warn_zero_bytesused() warns about this (only once!), but it also
calls WARN_ON(1), which is confusing since it is not immediately clear
that it warns about a 0 value for bytesused.

Just drop the WARN_ON as it serves no purpose.

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Acked-by: Ezequiel Garcia <ezequiel@collabora.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
Cc: Matthias Maennich <maennich@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/media/v4l2-core/videobuf2-v4l2.c