Commit 335e3713 authored by Neil Armstrong's avatar Neil Armstrong

drm/meson: Add support for HDMI venc modes and settings

This patch adds support for the supported HDMI Venc modes and add the VPP mux
value to switch to ENCP encoder.
Acked-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: default avatarNeil Armstrong <narmstrong@baylibre.com>
parent 2f4c95dc
This diff is collapsed.
...@@ -30,6 +30,7 @@ enum { ...@@ -30,6 +30,7 @@ enum {
MESON_VENC_MODE_NONE = 0, MESON_VENC_MODE_NONE = 0,
MESON_VENC_MODE_CVBS_PAL, MESON_VENC_MODE_CVBS_PAL,
MESON_VENC_MODE_CVBS_NTSC, MESON_VENC_MODE_CVBS_NTSC,
MESON_VENC_MODE_HDMI,
}; };
struct meson_cvbs_enci_mode { struct meson_cvbs_enci_mode {
...@@ -56,12 +57,18 @@ struct meson_cvbs_enci_mode { ...@@ -56,12 +57,18 @@ struct meson_cvbs_enci_mode {
unsigned int analog_sync_adj; unsigned int analog_sync_adj;
}; };
/* HDMI Clock parameters */
bool meson_venc_hdmi_supported_vic(int vic);
bool meson_venc_hdmi_venc_repeat(int vic);
/* CVBS Timings and Parameters */ /* CVBS Timings and Parameters */
extern struct meson_cvbs_enci_mode meson_cvbs_enci_pal; extern struct meson_cvbs_enci_mode meson_cvbs_enci_pal;
extern struct meson_cvbs_enci_mode meson_cvbs_enci_ntsc; extern struct meson_cvbs_enci_mode meson_cvbs_enci_ntsc;
void meson_venci_cvbs_mode_set(struct meson_drm *priv, void meson_venci_cvbs_mode_set(struct meson_drm *priv,
struct meson_cvbs_enci_mode *mode); struct meson_cvbs_enci_mode *mode);
void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic,
struct drm_display_mode *mode);
unsigned int meson_venci_get_field(struct meson_drm *priv); unsigned int meson_venci_get_field(struct meson_drm *priv);
void meson_venc_enable_vsync(struct meson_drm *priv); void meson_venc_enable_vsync(struct meson_drm *priv);
......
...@@ -23,6 +23,8 @@ ...@@ -23,6 +23,8 @@
/* Mux VIU/VPP to ENCI */ /* Mux VIU/VPP to ENCI */
#define MESON_VIU_VPP_MUX_ENCI 0x5 #define MESON_VIU_VPP_MUX_ENCI 0x5
/* Mux VIU/VPP to ENCP */
#define MESON_VIU_VPP_MUX_ENCP 0xA
void meson_vpp_setup_mux(struct meson_drm *priv, unsigned int mux); void meson_vpp_setup_mux(struct meson_drm *priv, unsigned int mux);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment