summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--drivers/gpu/drm/via/crtc_hw.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/drivers/gpu/drm/via/crtc_hw.h b/drivers/gpu/drm/via/crtc_hw.h
index da666e387402..23f0e0999c48 100644
--- a/drivers/gpu/drm/via/crtc_hw.h
+++ b/drivers/gpu/drm/via/crtc_hw.h
@@ -146,6 +146,20 @@ via_dvp1_set_io_pad_state(void __iomem *regs, u8 io_pad_state)
}
/*
+ * Sets the display source of DVP1 (Digital Video Port 1) interface.
+ */
+static inline void
+via_dvp1_set_display_source(void __iomem *regs, u8 display_source)
+{
+ /* 3X5.9B[4] - DVP1 Data Source Selection
+ * 0: Primary Display
+ * 1: Secondary Display */
+ svga_wcrt_mask(regs, 0x9B, display_source << 4, BIT(4));
+ DRM_DEBUG_KMS("DVP1 Display Source: IGA%d\n",
+ (display_source & 0x01) + 1);
+}
+
+/*
* Sets analog (VGA) DAC output state.
*/
static inline void