]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
media: mexon-ge2d: fixup frames size in registers
authorNeil Armstrong <narmstrong@baylibre.com>
Thu, 3 Jun 2021 08:42:15 +0000 (10:42 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 8 Apr 2022 12:05:49 +0000 (14:05 +0200)
commit7ed1bd0a9d2dde442183e84cce0acfb83ca8c881
tree2ac1021b74eced9e5be95ed5815334acc6963cb6
parent5176d48dde2b8abe84ea0b8f5286381541f9bd2e
media: mexon-ge2d: fixup frames size in registers

[ Upstream commit 79e8c421a099bfbcebe59740153e55aa0442ced6 ]

The CLIP, SRC & DST registers are coded to take the pixel/line start & end,
starting from 0. Thus the end should be the width/height minus 1.

It can be an issue with clipping and rotation, where it will add spurious
lines from uninitialized or unwanted data with a shift in the result.

Fixes: 59a635327ca7 ("media: meson: Add M2M driver for the Amlogic GE2D Accelerator Unit")
Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/media/platform/meson/ge2d/ge2d.c