Lines Matching +full:- +full:gt

1 /* SPDX-License-Identifier: MIT */
9 #include <linux/fault-inject.h>
18 for ((id__) = 0; (id__) < ARRAY_SIZE((gt__)->hw_engines); (id__)++) \
19 for_each_if(((hwe__) = (gt__)->hw_engines + (id__)) && \
22 #define CCS_MASK(gt) (((gt)->info.engine_mask & XE_HW_ENGINE_CCS_MASK) >> XE_HW_ENGINE_CCS0) argument
31 int xe_gt_init_early(struct xe_gt *gt);
32 int xe_gt_init(struct xe_gt *gt);
33 void xe_gt_mmio_init(struct xe_gt *gt);
34 void xe_gt_declare_wedged(struct xe_gt *gt);
35 int xe_gt_record_default_lrcs(struct xe_gt *gt);
38 * xe_gt_record_user_engines - save data related to engines available to
40 * @gt: GT structure
42 * Walk the available HW engines from gt->info.engine_mask and calculate data
47 void xe_gt_record_user_engines(struct xe_gt *gt);
49 void xe_gt_suspend_prepare(struct xe_gt *gt);
50 int xe_gt_suspend(struct xe_gt *gt);
51 void xe_gt_shutdown(struct xe_gt *gt);
52 int xe_gt_resume(struct xe_gt *gt);
53 void xe_gt_reset_async(struct xe_gt *gt);
54 void xe_gt_sanitize(struct xe_gt *gt);
55 int xe_gt_sanitize_freq(struct xe_gt *gt);
58 * xe_gt_wait_for_reset - wait for gt's async reset to finalize.
59 * @gt: GT structure
64 static inline bool xe_gt_wait_for_reset(struct xe_gt *gt) in xe_gt_wait_for_reset() argument
66 return flush_work(&gt->reset.worker); in xe_gt_wait_for_reset()
70 * xe_gt_reset - perform synchronous reset
71 * @gt: GT structure
76 static inline bool xe_gt_reset(struct xe_gt *gt) in xe_gt_reset() argument
78 xe_gt_reset_async(gt); in xe_gt_reset()
79 return xe_gt_wait_for_reset(gt); in xe_gt_reset()
83 * xe_gt_any_hw_engine_by_reset_domain - scan the list of engines and return the
85 * @gt: GT structure
89 xe_gt_any_hw_engine_by_reset_domain(struct xe_gt *gt, enum xe_engine_class class);
92 * xe_gt_any_hw_engine - scan the list of engines and return the
94 * @gt: GT structure
96 struct xe_hw_engine *xe_gt_any_hw_engine(struct xe_gt *gt);
98 struct xe_hw_engine *xe_gt_hw_engine(struct xe_gt *gt,
103 static inline bool xe_gt_has_indirect_ring_state(struct xe_gt *gt) in xe_gt_has_indirect_ring_state() argument
105 return gt->info.has_indirect_ring_state && in xe_gt_has_indirect_ring_state()
106 xe_device_uc_enabled(gt_to_xe(gt)); in xe_gt_has_indirect_ring_state()
109 static inline bool xe_gt_is_main_type(struct xe_gt *gt) in xe_gt_is_main_type() argument
111 return gt->info.type == XE_GT_TYPE_MAIN; in xe_gt_is_main_type()
114 static inline bool xe_gt_is_media_type(struct xe_gt *gt) in xe_gt_is_media_type() argument
116 return gt->info.type == XE_GT_TYPE_MEDIA; in xe_gt_is_media_type()
119 static inline bool xe_gt_is_usm_hwe(struct xe_gt *gt, struct xe_hw_engine *hwe) in xe_gt_is_usm_hwe() argument
121 struct xe_device *xe = gt_to_xe(gt); in xe_gt_is_usm_hwe()
123 return xe->info.has_usm && hwe->class == XE_ENGINE_CLASS_COPY && in xe_gt_is_usm_hwe()
124 hwe->instance == gt->usm.reserved_bcs_instance; in xe_gt_is_usm_hwe()