1 // SPDX-License-Identifier: MIT
4 * Copyright © 2019 Intel Corporation
7 #include <drm/drm_print.h>
9 #include "debugfs_engines.h"
10 #include "debugfs_gt.h"
11 #include "i915_drv.h" /* for_each_engine! */
12 #include "intel_engine.h"
14 static int engines_show(struct seq_file
*m
, void *data
)
16 struct intel_gt
*gt
= m
->private;
17 struct intel_engine_cs
*engine
;
18 enum intel_engine_id id
;
21 p
= drm_seq_file_printer(m
);
22 for_each_engine(engine
, gt
, id
)
23 intel_engine_dump(engine
, &p
, "%s\n", engine
->name
);
27 DEFINE_GT_DEBUGFS_ATTRIBUTE(engines
);
29 void debugfs_engines_register(struct intel_gt
*gt
, struct dentry
*root
)
31 static const struct debugfs_gt_file files
[] = {
32 { "engines", &engines_fops
},
35 intel_gt_debugfs_register_files(root
, files
, ARRAY_SIZE(files
), gt
);