Commit 33e9e541 authored by Ville Syrjälä's avatar Ville Syrjälä

drm/i915: Introduce g4x_hdmi.c

Extract the g4x+ HDMI low level code to its own file,
leaving intel_hdmi.c to deal with higher level issues.

The infoframe support I decided to leave in intel_hdmi.c
since I think we need to move that as a whole to its own file.
It is after all used also for DP SDPs, so no longer HDMI
specific.
Acked-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210318161015.22070-7-ville.syrjala@linux.intel.com
parent 917c2899
......@@ -241,6 +241,7 @@ i915-y += \
display/dvo_sil164.o \
display/dvo_tfp410.o \
display/g4x_dp.o \
display/g4x_hdmi.o \
display/icl_dsi.o \
display/intel_crt.o \
display/intel_ddi.o \
......
This diff is collapsed.
/* SPDX-License-Identifier: MIT */
/*
* Copyright © 2020 Intel Corporation
*/
#ifndef _G4X_HDMI_H_
#define _G4X_HDMI_H_
#include <linux/types.h>
#include "i915_reg.h"
enum port;
struct drm_i915_private;
void intel_hdmi_init(struct drm_i915_private *dev_priv,
i915_reg_t hdmi_reg, enum port port);
#endif
......@@ -67,6 +67,7 @@
#include "gt/intel_rps.h"
#include "g4x_dp.h"
#include "g4x_hdmi.h"
#include "i915_drv.h"
#include "intel_acpi.h"
#include "intel_atomic.h"
......
......@@ -1770,6 +1770,18 @@ intel_attached_dig_port(struct intel_connector *connector)
return enc_to_dig_port(intel_attached_encoder(connector));
}
static inline struct intel_hdmi *
enc_to_intel_hdmi(struct intel_encoder *encoder)
{
return &enc_to_dig_port(encoder)->hdmi;
}
static inline struct intel_hdmi *
intel_attached_hdmi(struct intel_connector *connector)
{
return enc_to_intel_hdmi(intel_attached_encoder(connector));
}
static inline struct intel_dp *enc_to_intel_dp(struct intel_encoder *encoder)
{
return &enc_to_dig_port(encoder)->dp;
......
This diff is collapsed.
......@@ -23,11 +23,8 @@ struct drm_connector_state;
union hdmi_infoframe;
enum port;
void intel_hdmi_init(struct drm_i915_private *dev_priv, i915_reg_t hdmi_reg,
enum port port);
void intel_hdmi_init_connector(struct intel_digital_port *dig_port,
struct intel_connector *intel_connector);
struct intel_hdmi *enc_to_intel_hdmi(struct intel_encoder *encoder);
int intel_hdmi_compute_config(struct intel_encoder *encoder,
struct intel_crtc_state *pipe_config,
struct drm_connector_state *conn_state);
......
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