]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
media: aspeed: Allow to capture from SoC display (GFX)
authorJammy Huang <jammy_huang@aspeedtech.com>
Tue, 26 Aug 2025 02:25:01 +0000 (10:25 +0800)
committerHans Verkuil <hverkuil+cisco@kernel.org>
Fri, 29 Aug 2025 09:04:02 +0000 (11:04 +0200)
commit039b9302d64ec35f70c91919cd7bcdbc1aef3707
tree52a78ac83f69e8115bd6425bd6800eebcc1c50ff
parent9842379bf67bb49250e37d289d2f082975adb319
media: aspeed: Allow to capture from SoC display (GFX)

ASPEED BMC IC has 2 different display engines. Please find AST2600's
datasheet to get detailed information.

1. VGA on PCIe
2. SoC Display (GFX)

By default, video engine (VE) will capture video from VGA. This patch
adds an option to capture video from GFX with standard ioctl,
vidioc_s_input.

An enum, aspeed_video_input, is added for this purpose.
enum aspeed_video_input {
VIDEO_INPUT_VGA = 0,
VIDEO_INPUT_GFX,
VIDEO_INPUT_MAX
};

To test this feature, you will need to enable GFX first. Please refer to
ASPEED's SDK_User_Guide, 6.3.x Soc Display driver, for more information.
In your application, you will need to use v4l2 ioctl, VIDIOC_S_INPUT, as
below to select before start streaming.

int rc;
struct v4l2_input input;

input.index = VIDEO_INPUT_GFX;
rc = ioctl(fd, VIDIOC_S_INPUT, &input);
if (rc < 0)
{
...
}

Link: https://github.com/AspeedTech-BMC/openbmc/releases
Signed-off-by: Jammy Huang <jammy_huang@aspeedtech.com>
Signed-off-by: Hans Verkuil <hverkuil+cisco@kernel.org>
[hverkuil: split up three overly long lines]
drivers/media/platform/aspeed/aspeed-video.c
include/uapi/linux/aspeed-video.h