]> asedeno.scripts.mit.edu Git - linux.git/commit
media: venus: vdec: fix decoded data size
authorVikash Garodia <vgarodia@codeaurora.org>
Mon, 8 Oct 2018 11:09:04 +0000 (07:09 -0400)
committerMauro Carvalho Chehab <mchehab+samsung@kernel.org>
Tue, 9 Oct 2018 12:07:07 +0000 (08:07 -0400)
commitce32c0a530bd955206fe45c2eff77e581202d699
tree7c79197fa331ced650b868af9e39829c79c5156b
parent32ae592036d7aeaabcccb2b1715373a68639a768
media: venus: vdec: fix decoded data size

Existing code returns the max of the decoded size and buffer size.
It turns out that buffer size is always greater due to hardware
alignment requirement. As a result, payload size given to client
is incorrect. This change ensures that the bytesused is assigned
to actual payload size, when available.

Signed-off-by: Vikash Garodia <vgarodia@codeaurora.org>
Acked-by: Stanimir Varbanov <stanimir.varbanov@linaro.org>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab+samsung@kernel.org>
drivers/media/platform/qcom/venus/vdec.c