]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
drm/{i915, xe}: add shared header for VLV IOSF sideband units and registers
authorJani Nikula <jani.nikula@intel.com>
Tue, 31 Mar 2026 11:40:58 +0000 (14:40 +0300)
committerJani Nikula <jani.nikula@intel.com>
Wed, 1 Apr 2026 09:29:21 +0000 (12:29 +0300)
Move vlv_iosf_sb_reg.h to include/drm/intel/vlv_iosf_sb_regs.h. Use
_regs.h suffix to align better with other register headers. Move enum
vlv_iosf_sb_unit there as well, breaking the final include tie related
to IOSF sideband between display and i915 core.

With this, we can completely remove the xe compat vls_iosf_sb*.h
headers.

Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patch.msgid.link/41b060b0d6453de39ca775eab10ee12b25c45b7d.1774957233.git.jani.nikula@intel.com
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/display/intel_display_power_map.c
drivers/gpu/drm/i915/display/intel_display_power_well.c
drivers/gpu/drm/i915/display/intel_parent.c
drivers/gpu/drm/i915/display/vlv_sideband.h
drivers/gpu/drm/i915/vlv_iosf_sb.h
drivers/gpu/drm/xe/compat-i915-headers/vlv_iosf_sb.h [deleted file]
drivers/gpu/drm/xe/compat-i915-headers/vlv_iosf_sb_reg.h [deleted file]
include/drm/intel/vlv_iosf_sb_regs.h [moved from drivers/gpu/drm/i915/vlv_iosf_sb_reg.h with 95% similarity]

index 65204d68a75986497007b666662304a42cf4689d..3400080d78d2a3a164cd7eac1ba2d56b614efab0 100644 (file)
@@ -4,13 +4,13 @@
  */
 
 #include <drm/drm_print.h>
+#include <drm/intel/vlv_iosf_sb_regs.h>
 
 #include "intel_display_core.h"
 #include "intel_display_power_map.h"
 #include "intel_display_power_well.h"
 #include "intel_display_regs.h"
 #include "intel_display_types.h"
-#include "vlv_iosf_sb_reg.h"
 
 #define __LIST_INLINE_ELEMS(__elem_type, ...) \
        ((__elem_type[]) { __VA_ARGS__ })
index f96a5088d138c955a2c7cd44d7b91853c20ce657..6fbfd46461b08b1cd520795c206dc08cc319873d 100644 (file)
@@ -34,7 +34,6 @@
 #include "intel_vga.h"
 #include "skl_watermark.h"
 #include "vlv_dpio_phy_regs.h"
-#include "vlv_iosf_sb_reg.h"
 #include "vlv_sideband.h"
 
 /*
index 4e01423a03922f56b42dba8fbf9ff63bbf8ac282..47ce3b6fdd5bdc94a099efc5eb54e700051ef953 100644 (file)
 
 #include <drm/drm_print.h>
 #include <drm/intel/display_parent_interface.h>
+#include <drm/intel/vlv_iosf_sb_regs.h>
 
 #include "intel_display_core.h"
 #include "intel_parent.h"
-#include "vlv_iosf_sb.h"
 
 /* dpt */
 struct intel_dpt *intel_parent_dpt_create(struct intel_display *display,
index 8751a070b0ae8879d0994f3c1723c18e35f3fb79..60a66abc1649c1176f8a06f05a4bf24ebc7330a9 100644 (file)
@@ -6,8 +6,7 @@
 
 #include <linux/types.h>
 
-#include "vlv_iosf_sb.h"
-#include "vlv_iosf_sb_reg.h"
+#include <drm/intel/vlv_iosf_sb_regs.h>
 
 enum dpio_phy;
 struct intel_display;
index e4002d5b5a2e09d8c2aebfb584e8c383540ac37d..8129ba11c7509f50abc74c4c8c1afd1c4d2a413f 100644 (file)
@@ -8,23 +8,11 @@
 
 #include <linux/types.h>
 
-#include "vlv_iosf_sb_reg.h"
+#include <drm/intel/vlv_iosf_sb_regs.h>
 
 struct drm_device;
 struct drm_i915_private;
 
-enum vlv_iosf_sb_unit {
-       VLV_IOSF_SB_BUNIT,
-       VLV_IOSF_SB_CCK,
-       VLV_IOSF_SB_CCU,
-       VLV_IOSF_SB_DPIO,
-       VLV_IOSF_SB_DPIO_2,
-       VLV_IOSF_SB_FLISDSI,
-       VLV_IOSF_SB_GPIO,
-       VLV_IOSF_SB_NC,
-       VLV_IOSF_SB_PUNIT,
-};
-
 void vlv_iosf_sb_init(struct drm_i915_private *i915);
 void vlv_iosf_sb_fini(struct drm_i915_private *i915);
 
diff --git a/drivers/gpu/drm/xe/compat-i915-headers/vlv_iosf_sb.h b/drivers/gpu/drm/xe/compat-i915-headers/vlv_iosf_sb.h
deleted file mode 100644 (file)
index 69e1935..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/* SPDX-License-Identifier: MIT */
-/*
- * Copyright © 2013-2021 Intel Corporation
- */
-
-#ifndef _VLV_IOSF_SB_H_
-#define _VLV_IOSF_SB_H_
-
-#include <linux/types.h>
-
-#include "vlv_iosf_sb_reg.h"
-
-struct drm_device;
-
-enum vlv_iosf_sb_unit {
-       VLV_IOSF_SB_BUNIT,
-       VLV_IOSF_SB_CCK,
-       VLV_IOSF_SB_CCU,
-       VLV_IOSF_SB_DPIO,
-       VLV_IOSF_SB_DPIO_2,
-       VLV_IOSF_SB_FLISDSI,
-       VLV_IOSF_SB_GPIO,
-       VLV_IOSF_SB_NC,
-       VLV_IOSF_SB_PUNIT,
-};
-
-static inline void vlv_iosf_sb_get(struct drm_device *drm, unsigned long ports)
-{
-}
-static inline u32 vlv_iosf_sb_read(struct drm_device *drm, enum vlv_iosf_sb_unit unit, u32 addr)
-{
-       return 0;
-}
-static inline int vlv_iosf_sb_write(struct drm_device *drm, enum vlv_iosf_sb_unit unit, u32 addr, u32 val)
-{
-       return 0;
-}
-static inline void vlv_iosf_sb_put(struct drm_device *drm, unsigned long ports)
-{
-}
-
-#endif /* _VLV_IOSF_SB_H_ */
diff --git a/drivers/gpu/drm/xe/compat-i915-headers/vlv_iosf_sb_reg.h b/drivers/gpu/drm/xe/compat-i915-headers/vlv_iosf_sb_reg.h
deleted file mode 100644 (file)
index cb7fa8e..0000000
+++ /dev/null
@@ -1,6 +0,0 @@
-/* SPDX-License-Identifier: MIT */
-/*
- * Copyright © 2023 Intel Corporation
- */
-
-#include "../../i915/vlv_iosf_sb_reg.h"
similarity index 95%
rename from drivers/gpu/drm/i915/vlv_iosf_sb_reg.h
rename to include/drm/intel/vlv_iosf_sb_regs.h
index f977fb3b6e1738f023bb9605c44fe0319119709f..42d1def5534b1c3b7cd220959f096060c991e434 100644 (file)
@@ -3,8 +3,20 @@
  * Copyright © 2022 Intel Corporation
  */
 
-#ifndef _VLV_IOSF_SB_REG_H_
-#define _VLV_IOSF_SB_REG_H_
+#ifndef _VLV_IOSF_SB_REGS_H_
+#define _VLV_IOSF_SB_REGS_H_
+
+enum vlv_iosf_sb_unit {
+       VLV_IOSF_SB_BUNIT,
+       VLV_IOSF_SB_CCK,
+       VLV_IOSF_SB_CCU,
+       VLV_IOSF_SB_DPIO,
+       VLV_IOSF_SB_DPIO_2,
+       VLV_IOSF_SB_FLISDSI,
+       VLV_IOSF_SB_GPIO,
+       VLV_IOSF_SB_NC,
+       VLV_IOSF_SB_PUNIT,
+};
 
 /* See configdb bunit SB addr map */
 #define BUNIT_REG_BISOC                                0x11
 #define  CCK_FREQUENCY_STATUS_SHIFT            8
 #define  CCK_FREQUENCY_VALUES                  (0x1f << 0)
 
-#endif /* _VLV_IOSF_SB_REG_H_ */
+#endif /* _VLV_IOSF_SB_REGS_H_ */