OSDN Git Service

drm: bridge: dw-hdmi: Pass private data pointer to .mode_valid()
authorLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Tue, 26 May 2020 01:14:49 +0000 (04:14 +0300)
committerSam Ravnborg <sam@ravnborg.org>
Tue, 23 Jun 2020 17:54:32 +0000 (19:54 +0200)
commit96591a4b93fb8b335941783dd6e7ded9d6d49f09
treeb76c5023046a4e4aa1d5be15d486bc6de223acad
parent12c683e12cd8e2dcf7b7143bebceae484d17727a
drm: bridge: dw-hdmi: Pass private data pointer to .mode_valid()

Platform glue drivers for dw_hdmi may need to access device-specific
data from their .mode_valid() implementation. They currently have no
clean way to do so, and one driver hacks around it by accessing the
dev_private data of the drm_device retrieved from the connector.

Add a priv_data void pointer to the dw_hdmi_plat_data structure, and
pass it to the .mode_valid() function.

Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
Reviewed-by: Neil Armstrong <narmstrong@baylibre.com>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20200526011505.31884-12-laurent.pinchart+renesas@ideasonboard.com
drivers/gpu/drm/bridge/synopsys/dw-hdmi.c
drivers/gpu/drm/imx/dw_hdmi-imx.c
drivers/gpu/drm/meson/meson_dw_hdmi.c
drivers/gpu/drm/rcar-du/rcar_dw_hdmi.c
drivers/gpu/drm/rockchip/dw_hdmi-rockchip.c
drivers/gpu/drm/sun4i/sun8i_dw_hdmi.c
drivers/gpu/drm/sun4i/sun8i_dw_hdmi.h
include/drm/bridge/dw_hdmi.h