We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent ad40098 commit af2b588Copy full SHA for af2b588
drivers/gpu/drm/xe/xe_ggtt.c
@@ -201,6 +201,13 @@ static const struct xe_ggtt_pt_ops xelpg_pt_wa_ops = {
201
.ggtt_set_pte = xe_ggtt_set_pte_and_flush,
202
};
203
204
+static void dev_fini_ggtt(void *arg)
205
+{
206
+ struct xe_ggtt *ggtt = arg;
207
+
208
+ drain_workqueue(ggtt->wq);
209
+}
210
211
/**
212
* xe_ggtt_init_early - Early GGTT initialization
213
* @ggtt: the &xe_ggtt to be initialized
@@ -257,6 +264,10 @@ int xe_ggtt_init_early(struct xe_ggtt *ggtt)
257
264
if (err)
258
265
return err;
259
266
267
+ err = devm_add_action_or_reset(xe->drm.dev, dev_fini_ggtt, ggtt);
268
+ if (err)
269
+ return err;
270
260
271
if (IS_SRIOV_VF(xe)) {
261
272
err = xe_gt_sriov_vf_prepare_ggtt(xe_tile_get_gt(ggtt->tile, 0));
262
273
0 commit comments