@@ -32,6 +32,10 @@ struct drm_printer;
func(overlay_needs_physical); \
func(supports_tv);
+#define _DISPLAY_INFO(display) ((display)->info.__device_info)
+#define _DISPLAY_RUNTIME_INFO(display) (&(display)->info.__runtime_info)
+#define _HAS_DDI(display) (_DISPLAY_INFO(display)->has_ddi)
+
#define HAS_4TILE(i915) (IS_DG2(i915) || DISPLAY_VER(i915) >= 14)
#define HAS_ASYNC_FLIPS(i915) (DISPLAY_VER(i915) >= 5)
#define HAS_CDCLK_CRAWL(i915) (DISPLAY_INFO(i915)->has_cdclk_crawl)
@@ -2583,9 +2583,9 @@ static const struct drm_connector_funcs intel_hdmi_connector_funcs = {
static int intel_hdmi_connector_atomic_check(struct drm_connector *connector,
struct drm_atomic_state *state)
{
- struct drm_i915_private *i915 = to_i915(state->dev);
+ struct intel_display *display = to_intel_display(state->dev);
- if (HAS_DDI(i915))
+ if (_HAS_DDI(display))
return intel_digital_connector_atomic_check(connector, state);
else
return g4x_hdmi_connector_atomic_check(connector, state);
Obviously they'd be without underscore prefix. Signed-off-by: Jani Nikula <jani.nikula@intel.com> --- drivers/gpu/drm/i915/display/intel_display_device.h | 4 ++++ drivers/gpu/drm/i915/display/intel_hdmi.c | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-)