From 3d78923bd07ad99a33b06eaa69194b35ac1637f1 Mon Sep 17 00:00:00 2001 From: Michal Wajdeczko Date: Wed, 15 Nov 2023 15:15:23 +0100 Subject: drm/xe/guc: Promote guc_to_gt/xe helpers to .h Duplicating these helpers in almost every .c file is a bad idea. Define them as inlines in .h file to allow proper reuse. Signed-off-by: Michal Wajdeczko Cc: Rodrigo Vivi Cc: Jani Nikula Reviewed-by: Matthew Brost Signed-off-by: Rodrigo Vivi --- drivers/gpu/drm/xe/xe_guc_debugfs.c | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'drivers/gpu/drm/xe/xe_guc_debugfs.c') diff --git a/drivers/gpu/drm/xe/xe_guc_debugfs.c b/drivers/gpu/drm/xe/xe_guc_debugfs.c index 167eb5593e03..ffd7d53bcc42 100644 --- a/drivers/gpu/drm/xe/xe_guc_debugfs.c +++ b/drivers/gpu/drm/xe/xe_guc_debugfs.c @@ -15,18 +15,6 @@ #include "xe_guc_log.h" #include "xe_macros.h" -static struct xe_gt * -guc_to_gt(struct xe_guc *guc) -{ - return container_of(guc, struct xe_gt, uc.guc); -} - -static struct xe_device * -guc_to_xe(struct xe_guc *guc) -{ - return gt_to_xe(guc_to_gt(guc)); -} - static struct xe_guc *node_to_guc(struct drm_info_node *node) { return node->info_ent->data; -- cgit