Expose the number of display resets performed in a new
"display_reset_count" debugfs file. kms_busy can use this to
confirm that the kernel actually took the full display reset path.
v2: Give the file an "intel_" namespace (Jani)
Cc: Jouni Högander <jouni.hogander@intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Testcase: igt/kms_busy/*-with-reset
Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patch.msgid.link/20260415210411.24750-7-ville.syrjala@linux.intel.com
unsigned long mask;
} quirks;
+ struct {
+ u32 count;
+ } reset;
+
struct {
/* restore state for suspend/resume and display reset */
struct drm_atomic_state *modeset_state;
#include "intel_display_power.h"
#include "intel_display_power_well.h"
#include "intel_display_regs.h"
+#include "intel_display_reset.h"
#include "intel_display_rpm.h"
#include "intel_display_types.h"
#include "intel_dmc.h"
intel_bios_debugfs_register(display);
intel_cdclk_debugfs_register(display);
+ intel_display_reset_debugfs_register(display);
intel_dmc_debugfs_register(display);
intel_dp_test_debugfs_register(display);
intel_fbc_debugfs_register(display);
* Copyright © 2023 Intel Corporation
*/
+#include <linux/debugfs.h>
+
#include <drm/drm_atomic_helper.h>
#include <drm/drm_print.h>
return;
}
+ display->reset.count++;
display->restore.modeset_state = state;
state->acquire_ctx = ctx;
}
drm_modeset_acquire_fini(ctx);
mutex_unlock(&display->drm->mode_config.mutex);
}
+
+void intel_display_reset_debugfs_register(struct intel_display *display)
+{
+ debugfs_create_u32("intel_display_reset_count", 0400,
+ display->drm->debugfs_root,
+ &display->reset.count);
+}
void intel_display_reset_prepare(struct intel_display *display);
void intel_display_reset_finish(struct intel_display *display, bool test_only);
+void intel_display_reset_debugfs_register(struct intel_display *display);
+
#endif /* __INTEL_RESET_H__ */
i915-display/intel_display_power.o \
i915-display/intel_display_power_map.o \
i915-display/intel_display_power_well.o \
+ i915-display/intel_display_reset.o \
i915-display/intel_display_rpm.o \
i915-display/intel_display_rps.o \
i915-display/intel_display_trace.o \