Lines Matching refs:gt
80 struct xe_gt *gt = parent->d_inode->i_private; in xe_gt_debugfs_simple_show() local
86 return print(gt, &p); in xe_gt_debugfs_simple_show()
89 static int hw_engines(struct xe_gt *gt, struct drm_printer *p) in hw_engines() argument
91 struct xe_device *xe = gt_to_xe(gt); in hw_engines()
98 fw_ref = xe_force_wake_get(gt_to_fw(gt), XE_FORCEWAKE_ALL); in hw_engines()
104 for_each_hw_engine(hwe, gt, id) in hw_engines()
108 xe_force_wake_put(gt_to_fw(gt), fw_ref); in hw_engines()
114 static int powergate_info(struct xe_gt *gt, struct drm_printer *p) in powergate_info() argument
118 xe_pm_runtime_get(gt_to_xe(gt)); in powergate_info()
119 ret = xe_gt_idle_pg_print(gt, p); in powergate_info()
120 xe_pm_runtime_put(gt_to_xe(gt)); in powergate_info()
125 static int sa_info(struct xe_gt *gt, struct drm_printer *p) in sa_info() argument
127 struct xe_tile *tile = gt_to_tile(gt); in sa_info()
129 xe_pm_runtime_get(gt_to_xe(gt)); in sa_info()
132 xe_pm_runtime_put(gt_to_xe(gt)); in sa_info()
137 static int topology(struct xe_gt *gt, struct drm_printer *p) in topology() argument
139 xe_pm_runtime_get(gt_to_xe(gt)); in topology()
140 xe_gt_topology_dump(gt, p); in topology()
141 xe_pm_runtime_put(gt_to_xe(gt)); in topology()
146 static int steering(struct xe_gt *gt, struct drm_printer *p) in steering() argument
148 xe_pm_runtime_get(gt_to_xe(gt)); in steering()
149 xe_gt_mcr_steering_dump(gt, p); in steering()
150 xe_pm_runtime_put(gt_to_xe(gt)); in steering()
155 static int ggtt(struct xe_gt *gt, struct drm_printer *p) in ggtt() argument
159 xe_pm_runtime_get(gt_to_xe(gt)); in ggtt()
160 ret = xe_ggtt_dump(gt_to_tile(gt)->mem.ggtt, p); in ggtt()
161 xe_pm_runtime_put(gt_to_xe(gt)); in ggtt()
166 static int register_save_restore(struct xe_gt *gt, struct drm_printer *p) in register_save_restore() argument
171 xe_pm_runtime_get(gt_to_xe(gt)); in register_save_restore()
173 xe_reg_sr_dump(>->reg_sr, p); in register_save_restore()
177 for_each_hw_engine(hwe, gt, id) in register_save_restore()
182 for_each_hw_engine(hwe, gt, id) in register_save_restore()
187 for_each_hw_engine(hwe, gt, id) in register_save_restore()
190 xe_pm_runtime_put(gt_to_xe(gt)); in register_save_restore()
195 static int workarounds(struct xe_gt *gt, struct drm_printer *p) in workarounds() argument
197 xe_pm_runtime_get(gt_to_xe(gt)); in workarounds()
198 xe_wa_dump(gt, p); in workarounds()
199 xe_pm_runtime_put(gt_to_xe(gt)); in workarounds()
204 static int tunings(struct xe_gt *gt, struct drm_printer *p) in tunings() argument
206 xe_pm_runtime_get(gt_to_xe(gt)); in tunings()
207 xe_tuning_dump(gt, p); in tunings()
208 xe_pm_runtime_put(gt_to_xe(gt)); in tunings()
213 static int pat(struct xe_gt *gt, struct drm_printer *p) in pat() argument
215 xe_pm_runtime_get(gt_to_xe(gt)); in pat()
216 xe_pat_dump(gt, p); in pat()
217 xe_pm_runtime_put(gt_to_xe(gt)); in pat()
222 static int mocs(struct xe_gt *gt, struct drm_printer *p) in mocs() argument
224 xe_pm_runtime_get(gt_to_xe(gt)); in mocs()
225 xe_mocs_dump(gt, p); in mocs()
226 xe_pm_runtime_put(gt_to_xe(gt)); in mocs()
231 static int rcs_default_lrc(struct xe_gt *gt, struct drm_printer *p) in rcs_default_lrc() argument
233 xe_pm_runtime_get(gt_to_xe(gt)); in rcs_default_lrc()
234 xe_lrc_dump_default(p, gt, XE_ENGINE_CLASS_RENDER); in rcs_default_lrc()
235 xe_pm_runtime_put(gt_to_xe(gt)); in rcs_default_lrc()
240 static int ccs_default_lrc(struct xe_gt *gt, struct drm_printer *p) in ccs_default_lrc() argument
242 xe_pm_runtime_get(gt_to_xe(gt)); in ccs_default_lrc()
243 xe_lrc_dump_default(p, gt, XE_ENGINE_CLASS_COMPUTE); in ccs_default_lrc()
244 xe_pm_runtime_put(gt_to_xe(gt)); in ccs_default_lrc()
249 static int bcs_default_lrc(struct xe_gt *gt, struct drm_printer *p) in bcs_default_lrc() argument
251 xe_pm_runtime_get(gt_to_xe(gt)); in bcs_default_lrc()
252 xe_lrc_dump_default(p, gt, XE_ENGINE_CLASS_COPY); in bcs_default_lrc()
253 xe_pm_runtime_put(gt_to_xe(gt)); in bcs_default_lrc()
258 static int vcs_default_lrc(struct xe_gt *gt, struct drm_printer *p) in vcs_default_lrc() argument
260 xe_pm_runtime_get(gt_to_xe(gt)); in vcs_default_lrc()
261 xe_lrc_dump_default(p, gt, XE_ENGINE_CLASS_VIDEO_DECODE); in vcs_default_lrc()
262 xe_pm_runtime_put(gt_to_xe(gt)); in vcs_default_lrc()
267 static int vecs_default_lrc(struct xe_gt *gt, struct drm_printer *p) in vecs_default_lrc() argument
269 xe_pm_runtime_get(gt_to_xe(gt)); in vecs_default_lrc()
270 xe_lrc_dump_default(p, gt, XE_ENGINE_CLASS_VIDEO_ENHANCE); in vecs_default_lrc()
271 xe_pm_runtime_put(gt_to_xe(gt)); in vecs_default_lrc()
276 static int hwconfig(struct xe_gt *gt, struct drm_printer *p) in hwconfig() argument
278 xe_pm_runtime_get(gt_to_xe(gt)); in hwconfig()
279 xe_guc_hwconfig_dump(>->uc.guc, p); in hwconfig()
280 xe_pm_runtime_put(gt_to_xe(gt)); in hwconfig()
316 void (*call)(struct xe_gt *), struct xe_gt *gt) in write_to_gt_call() argument
327 call(gt); in write_to_gt_call()
331 static void force_reset(struct xe_gt *gt) in force_reset() argument
333 struct xe_device *xe = gt_to_xe(gt); in force_reset()
336 xe_gt_reset_async(gt); in force_reset()
345 struct xe_gt *gt = s->private; in force_reset_write() local
347 return write_to_gt_call(userbuf, count, ppos, force_reset, gt); in force_reset_write()
352 struct xe_gt *gt = s->private; in force_reset_show() local
354 force_reset(gt); /* to be deprecated! */ in force_reset_show()
359 static void force_reset_sync(struct xe_gt *gt) in force_reset_sync() argument
361 struct xe_device *xe = gt_to_xe(gt); in force_reset_sync()
364 xe_gt_reset(gt); in force_reset_sync()
373 struct xe_gt *gt = s->private; in force_reset_sync_write() local
375 return write_to_gt_call(userbuf, count, ppos, force_reset_sync, gt); in force_reset_sync_write()
380 struct xe_gt *gt = s->private; in force_reset_sync_show() local
382 force_reset_sync(gt); /* to be deprecated! */ in force_reset_sync_show()
387 void xe_gt_debugfs_register(struct xe_gt *gt) in xe_gt_debugfs_register() argument
389 struct xe_device *xe = gt_to_xe(gt); in xe_gt_debugfs_register()
390 struct drm_minor *minor = gt_to_xe(gt)->drm.primary; in xe_gt_debugfs_register()
394 xe_gt_assert(gt, minor->debugfs_root); in xe_gt_debugfs_register()
396 snprintf(name, sizeof(name), "gt%d", gt->info.id); in xe_gt_debugfs_register()
408 root->d_inode->i_private = gt; in xe_gt_debugfs_register()
411 debugfs_create_file("force_reset", 0600, root, gt, &force_reset_fops); in xe_gt_debugfs_register()
412 debugfs_create_file("force_reset_sync", 0600, root, gt, &force_reset_sync_fops); in xe_gt_debugfs_register()
423 xe_uc_debugfs_register(>->uc, root); in xe_gt_debugfs_register()
426 xe_gt_sriov_pf_debugfs_register(gt, root); in xe_gt_debugfs_register()
428 xe_gt_sriov_vf_debugfs_register(gt, root); in xe_gt_debugfs_register()