]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
media: rockchip: rga: use stride for offset calculation
authorSven Püschel <s.pueschel@pengutronix.de>
Wed, 20 May 2026 22:44:13 +0000 (00:44 +0200)
committerHans Verkuil <hverkuil+cisco@kernel.org>
Thu, 21 May 2026 10:32:19 +0000 (12:32 +0200)
commit74d010fbdc4478293ceb96eed7f6609fe6c7529c
tree201fb2a0d015e3fe2bae6b5b8d1fe670500d9152
parenta2a4f69fd2e333bacd17d1788eb5211cb6f373cc
media: rockchip: rga: use stride for offset calculation

Use the stride instead of the width for the offset calculation. This
ensures that the bytesperline value doesn't need to match the width
value of the image.

Furthermore this patch removes the dependency on the uv_factor property
and instead reuses the v4l2_format_info to determine the correct
division factor.

Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Signed-off-by: Sven Püschel <s.pueschel@pengutronix.de>
Signed-off-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
drivers/media/platform/rockchip/rga/rga-buf.c
drivers/media/platform/rockchip/rga/rga.c
drivers/media/platform/rockchip/rga/rga.h