mirror of
https://github.com/raspberrypi/linux.git
synced 2025-12-25 19:42:19 +00:00
drm/i915/display: remove the loop in fifo underrun debugfs file creation
No need for the loop for a single file, and no more files should be added here, but rather in functionality specific source files. Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/bd74ff250075c599163c988ae6fb5316f92bf192.1726833193.git.jani.nikula@intel.com Signed-off-by: Jani Nikula <jani.nikula@intel.com>
This commit is contained in:
@@ -866,26 +866,13 @@ static const struct drm_info_list intel_display_debugfs_list[] = {
|
||||
{"i915_lpsp_status", i915_lpsp_status, 0},
|
||||
};
|
||||
|
||||
static const struct {
|
||||
const char *name;
|
||||
const struct file_operations *fops;
|
||||
} intel_display_debugfs_files[] = {
|
||||
{"i915_fifo_underrun_reset", &i915_fifo_underrun_reset_ops},
|
||||
};
|
||||
|
||||
void intel_display_debugfs_register(struct drm_i915_private *i915)
|
||||
{
|
||||
struct intel_display *display = &i915->display;
|
||||
struct drm_minor *minor = i915->drm.primary;
|
||||
int i;
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(intel_display_debugfs_files); i++) {
|
||||
debugfs_create_file(intel_display_debugfs_files[i].name,
|
||||
0644,
|
||||
minor->debugfs_root,
|
||||
to_i915(minor->dev),
|
||||
intel_display_debugfs_files[i].fops);
|
||||
}
|
||||
debugfs_create_file("i915_fifo_underrun_reset", 0644, minor->debugfs_root,
|
||||
to_i915(minor->dev), &i915_fifo_underrun_reset_ops);
|
||||
|
||||
drm_debugfs_create_files(intel_display_debugfs_list,
|
||||
ARRAY_SIZE(intel_display_debugfs_list),
|
||||
|
||||
Reference in New Issue
Block a user