]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
media: rockchip: rga: avoid odd frame sizes for YUV formats
authorSven Püschel <s.pueschel@pengutronix.de>
Wed, 20 May 2026 22:44:17 +0000 (00:44 +0200)
committerHans Verkuil <hverkuil+cisco@kernel.org>
Thu, 21 May 2026 10:32:19 +0000 (12:32 +0200)
commit92f50870ae987b8e2e5334e4ee38f82f6f405d78
treef371fc66e5a9031704581903b39c8521b93cd479
parent0fab01bb159a3c0cf79f44a7126987548e001a5c
media: rockchip: rga: avoid odd frame sizes for YUV formats

Avoid odd frame sizes for YUV formats, as they may cause undefined
behavior. This is done in preparation for the RGA3, which hangs when the
output format is set to 129x129 pixel YUV420 SP (NV12).

This requirement is documented explicitly for the RGA3 in  section 5.6.3
of the RK3588 TRM Part 2. For the RGA2 the RK3588 TRM Part 2
(section 6.1.2) and RK3568 TRM Part 2 (section 14.2) only mentions the
x/y offsets and stride aligning requirements. But the vendor driver for
the RGA2 also contains checks for the width and height to be aligned to
2 bytes.

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.c