Skip to content

Commit

Permalink
media: platform: synopsys: Add support for HDMI input driver
Browse files Browse the repository at this point in the history
Add initial support for the Synopsys DesignWare HDMI RX
Controller Driver used by Rockchip RK3588. The driver
supports:
 - HDMI 1.4b and 2.0 modes (HDMI 4k@60Hz)
 - RGB888, YUV422, YUV444 and YCC420 pixel formats
 - CEC
 - EDID configuration

The hardware also has Audio and HDCP capabilities, but these are
not yet supported by the driver.

Co-developed-by: Dingxian Wen <shawn.wen@rock-chips.com>
Signed-off-by: Dingxian Wen <shawn.wen@rock-chips.com>
Signed-off-by: Shreeya Patel <shreeya.patel@collabora.com>
Signed-off-by: Dmitry Osipenko <dmitry.osipenko@collabora.com>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
  • Loading branch information
Shreeya Patel authored and Hans Verkuil committed Mar 5, 2025
1 parent 9436332 commit 7b59b13
Show file tree
Hide file tree
Showing 10 changed files with 3,508 additions and 0 deletions.
1 change: 1 addition & 0 deletions drivers/media/platform/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -85,6 +85,7 @@ source "drivers/media/platform/rockchip/Kconfig"
source "drivers/media/platform/samsung/Kconfig"
source "drivers/media/platform/st/Kconfig"
source "drivers/media/platform/sunxi/Kconfig"
source "drivers/media/platform/synopsys/Kconfig"
source "drivers/media/platform/ti/Kconfig"
source "drivers/media/platform/verisilicon/Kconfig"
source "drivers/media/platform/via/Kconfig"
Expand Down
1 change: 1 addition & 0 deletions drivers/media/platform/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ obj-y += rockchip/
obj-y += samsung/
obj-y += st/
obj-y += sunxi/
obj-y += synopsys/
obj-y += ti/
obj-y += verisilicon/
obj-y += via/
Expand Down
3 changes: 3 additions & 0 deletions drivers/media/platform/synopsys/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# SPDX-License-Identifier: GPL-2.0-only

source "drivers/media/platform/synopsys/hdmirx/Kconfig"
2 changes: 2 additions & 0 deletions drivers/media/platform/synopsys/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# SPDX-License-Identifier: GPL-2.0-only
obj-y += hdmirx/
35 changes: 35 additions & 0 deletions drivers/media/platform/synopsys/hdmirx/Kconfig
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
# SPDX-License-Identifier: GPL-2.0

config VIDEO_SYNOPSYS_HDMIRX
tristate "Synopsys DesignWare HDMI Receiver driver"
depends on VIDEO_DEV
select MEDIA_CONTROLLER
select VIDEO_V4L2_SUBDEV_API
select VIDEOBUF2_DMA_CONTIG
select CEC_CORE
select HDMI
help
Support for Synopsys HDMI HDMI RX Controller.
This driver supports HDMI 2.0 version.

To compile this driver as a module, choose M here. The module
will be called synopsys_hdmirx.

config VIDEO_SYNOPSYS_HDMIRX_LOAD_DEFAULT_EDID
bool "Load default EDID"
depends on VIDEO_SYNOPSYS_HDMIRX
help
Preload default EDID (Extended Display Identification Data)
branded by Linux Foundation that exposes display modes up
to 4k@30Hz, which have best compatibility with HDMI transmitters.

Enabling this option is recommended for a non-production use-cases.
It will make driver usable out-of-the-box.

For a higher display modes you will need to load customized EDID
from userspace using v4l2-ctl tool or by other means.

Without enabling this option driver will be practically
non-functional until EDID will be loaded from userspace.
Which is a wanted behavior when using this driver in a
commercial product that should utilize own branded EDID.
4 changes: 4 additions & 0 deletions drivers/media/platform/synopsys/hdmirx/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# SPDX-License-Identifier: GPL-2.0
synopsys-hdmirx-objs := snps_hdmirx.o snps_hdmirx_cec.o

obj-$(CONFIG_VIDEO_SYNOPSYS_HDMIRX) += synopsys-hdmirx.o
Loading

0 comments on commit 7b59b13

Please sign in to comment.