]> git.ipfire.org Git - thirdparty/kernel/linux.git/commitdiff
drm/i915/wm: make struct intel_dbuf_state opaque type
authorJani Nikula <jani.nikula@intel.com>
Wed, 25 Jun 2025 10:32:21 +0000 (13:32 +0300)
committerJani Nikula <jani.nikula@intel.com>
Thu, 26 Jun 2025 08:55:53 +0000 (11:55 +0300)
With all the code touching struct intel_dbuf_state moved inside
skl_watermark.c, we move the struct definition there too, and make the
type opaque. This nicely reduces includes from skl_watermark.h.

Reviewed-by: Imre Deak <imre.deak@intel.com>
Link: https://lore.kernel.org/r/83ae5f022a1d6d83c031e5c079b04dc739102565.1750847509.git.jani.nikula@intel.com
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/display/skl_watermark.c
drivers/gpu/drm/i915/display/skl_watermark.h

index 3574df9b1df7d39845e66218db18bddefdf1057b..8b8cf74e64a7ae08d990de70d43623400532ea70 100644 (file)
  */
 #define DSB_EXE_TIME 100
 
+struct intel_dbuf_state {
+       struct intel_global_state base;
+
+       struct skl_ddb_entry ddb[I915_MAX_PIPES];
+       unsigned int weight[I915_MAX_PIPES];
+       u8 slices[I915_MAX_PIPES];
+       u8 enabled_slices;
+       u8 active_pipes;
+       u8 mdclk_cdclk_ratio;
+       bool joined_mbus;
+};
+
 #define to_intel_dbuf_state(global_state) \
        container_of_const((global_state), struct intel_dbuf_state, base)
 
index a1993ded034af6698cf9d06a7d77a19b6a104468..87d052b640b39e7bb6ff8b668fb33073e6ceff33 100644 (file)
@@ -8,17 +8,16 @@
 
 #include <linux/types.h>
 
-#include "intel_display_limits.h"
-#include "intel_global_state.h"
-#include "intel_wm_types.h"
-
+enum plane_id;
 struct intel_atomic_state;
 struct intel_bw_state;
 struct intel_crtc;
 struct intel_crtc_state;
+struct intel_dbuf_state;
 struct intel_display;
 struct intel_plane;
 struct intel_plane_state;
+struct skl_ddb_entry;
 struct skl_pipe_wm;
 struct skl_wm_level;
 
@@ -63,18 +62,6 @@ unsigned int skl_plane_relative_data_rate(const struct intel_crtc_state *crtc_st
                                          struct intel_plane *plane, int width,
                                          int height, int cpp);
 
-struct intel_dbuf_state {
-       struct intel_global_state base;
-
-       struct skl_ddb_entry ddb[I915_MAX_PIPES];
-       unsigned int weight[I915_MAX_PIPES];
-       u8 slices[I915_MAX_PIPES];
-       u8 enabled_slices;
-       u8 active_pipes;
-       u8 mdclk_cdclk_ratio;
-       bool joined_mbus;
-};
-
 struct intel_dbuf_state *
 intel_atomic_get_dbuf_state(struct intel_atomic_state *state);