From: Lucas De Marchi Date: Thu, 2 Mar 2023 01:34:05 +0000 (-0800) Subject: drm/xe: Fix typo persitent->persistent X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=541623a406fe1fd516ac9564b2388a3ec31610fe;p=linux.git drm/xe: Fix typo persitent->persistent Fix typo as noticed by Matt Roper: git grep -l persitent | xargs sed -i 's/persitent/persistent/g' ... and then fix coding style issues. Signed-off-by: Lucas De Marchi Reviewed-by: Maarten Lankhorst Link: https://lore.kernel.org/r/20230302013411.3262608-2-lucas.demarchi@intel.com Signed-off-by: Rodrigo Vivi --- diff --git a/drivers/gpu/drm/xe/xe_device.c b/drivers/gpu/drm/xe/xe_device.c index 8a9f1e5ce34d8..49ce11fc1174f 100644 --- a/drivers/gpu/drm/xe/xe_device.c +++ b/drivers/gpu/drm/xe/xe_device.c @@ -51,8 +51,8 @@ static int xe_file_open(struct drm_device *dev, struct drm_file *file) return 0; } -static void device_kill_persitent_engines(struct xe_device *xe, - struct xe_file *xef); +static void device_kill_persistent_engines(struct xe_device *xe, + struct xe_file *xef); static void xe_file_close(struct drm_device *dev, struct drm_file *file) { @@ -69,7 +69,7 @@ static void xe_file_close(struct drm_device *dev, struct drm_file *file) } mutex_unlock(&xef->engine.lock); mutex_destroy(&xef->engine.lock); - device_kill_persitent_engines(xe, xef); + device_kill_persistent_engines(xe, xef); mutex_lock(&xef->vm.lock); xa_for_each(&xef->vm.xa, idx, vm) @@ -189,8 +189,8 @@ struct xe_device *xe_device_create(struct pci_dev *pdev, drmm_mutex_init(&xe->drm, &xe->usm.lock); xa_init_flags(&xe->usm.asid_to_vm, XA_FLAGS_ALLOC1); - drmm_mutex_init(&xe->drm, &xe->persitent_engines.lock); - INIT_LIST_HEAD(&xe->persitent_engines.list); + drmm_mutex_init(&xe->drm, &xe->persistent_engines.lock); + INIT_LIST_HEAD(&xe->persistent_engines.list); spin_lock_init(&xe->pinned.lock); INIT_LIST_HEAD(&xe->pinned.kernel_bo_present); @@ -305,35 +305,35 @@ void xe_device_shutdown(struct xe_device *xe) { } -void xe_device_add_persitent_engines(struct xe_device *xe, struct xe_engine *e) +void xe_device_add_persistent_engines(struct xe_device *xe, struct xe_engine *e) { - mutex_lock(&xe->persitent_engines.lock); - list_add_tail(&e->persitent.link, &xe->persitent_engines.list); - mutex_unlock(&xe->persitent_engines.lock); + mutex_lock(&xe->persistent_engines.lock); + list_add_tail(&e->persistent.link, &xe->persistent_engines.list); + mutex_unlock(&xe->persistent_engines.lock); } -void xe_device_remove_persitent_engines(struct xe_device *xe, - struct xe_engine *e) +void xe_device_remove_persistent_engines(struct xe_device *xe, + struct xe_engine *e) { - mutex_lock(&xe->persitent_engines.lock); - if (!list_empty(&e->persitent.link)) - list_del(&e->persitent.link); - mutex_unlock(&xe->persitent_engines.lock); + mutex_lock(&xe->persistent_engines.lock); + if (!list_empty(&e->persistent.link)) + list_del(&e->persistent.link); + mutex_unlock(&xe->persistent_engines.lock); } -static void device_kill_persitent_engines(struct xe_device *xe, - struct xe_file *xef) +static void device_kill_persistent_engines(struct xe_device *xe, + struct xe_file *xef) { struct xe_engine *e, *next; - mutex_lock(&xe->persitent_engines.lock); - list_for_each_entry_safe(e, next, &xe->persitent_engines.list, - persitent.link) - if (e->persitent.xef == xef) { + mutex_lock(&xe->persistent_engines.lock); + list_for_each_entry_safe(e, next, &xe->persistent_engines.list, + persistent.link) + if (e->persistent.xef == xef) { xe_engine_kill(e); - list_del_init(&e->persitent.link); + list_del_init(&e->persistent.link); } - mutex_unlock(&xe->persitent_engines.lock); + mutex_unlock(&xe->persistent_engines.lock); } void xe_device_wmb(struct xe_device *xe) diff --git a/drivers/gpu/drm/xe/xe_device.h b/drivers/gpu/drm/xe/xe_device.h index 263620953c3b3..25c5087f5aad1 100644 --- a/drivers/gpu/drm/xe/xe_device.h +++ b/drivers/gpu/drm/xe/xe_device.h @@ -37,9 +37,9 @@ int xe_device_probe(struct xe_device *xe); void xe_device_remove(struct xe_device *xe); void xe_device_shutdown(struct xe_device *xe); -void xe_device_add_persitent_engines(struct xe_device *xe, struct xe_engine *e); -void xe_device_remove_persitent_engines(struct xe_device *xe, - struct xe_engine *e); +void xe_device_add_persistent_engines(struct xe_device *xe, struct xe_engine *e); +void xe_device_remove_persistent_engines(struct xe_device *xe, + struct xe_engine *e); void xe_device_wmb(struct xe_device *xe); diff --git a/drivers/gpu/drm/xe/xe_device_types.h b/drivers/gpu/drm/xe/xe_device_types.h index c9f74dc4c9fda..00b1db28a4b47 100644 --- a/drivers/gpu/drm/xe/xe_device_types.h +++ b/drivers/gpu/drm/xe/xe_device_types.h @@ -138,13 +138,13 @@ struct xe_device { struct mutex lock; } usm; - /** @persitent_engines: engines that are closed but still running */ + /** @persistent_engines: engines that are closed but still running */ struct { - /** @lock: protects persitent engines */ + /** @lock: protects persistent engines */ struct mutex lock; - /** @list: list of persitent engines */ + /** @list: list of persistent engines */ struct list_head list; - } persitent_engines; + } persistent_engines; /** @pinned: pinned BO state */ struct { diff --git a/drivers/gpu/drm/xe/xe_engine.c b/drivers/gpu/drm/xe/xe_engine.c index 519fbbcabdb9a..3e40fb6d3f98f 100644 --- a/drivers/gpu/drm/xe/xe_engine.c +++ b/drivers/gpu/drm/xe/xe_engine.c @@ -47,7 +47,7 @@ static struct xe_engine *__xe_engine_create(struct xe_device *xe, e->fence_irq = >->fence_irq[hwe->class]; e->ring_ops = gt->ring_ops[hwe->class]; e->ops = gt->engine_ops; - INIT_LIST_HEAD(&e->persitent.link); + INIT_LIST_HEAD(&e->persistent.link); INIT_LIST_HEAD(&e->compute.link); INIT_LIST_HEAD(&e->multi_gt_link); @@ -620,7 +620,7 @@ int xe_engine_create_ioctl(struct drm_device *dev, void *data, goto put_engine; } - e->persitent.xef = xef; + e->persistent.xef = xef; mutex_lock(&xef->engine.lock); err = xa_alloc(&xef->engine.xa, &id, e, xa_limit_32b, GFP_KERNEL); @@ -716,7 +716,7 @@ int xe_engine_destroy_ioctl(struct drm_device *dev, void *data, if (!(e->flags & ENGINE_FLAG_PERSISTENT)) xe_engine_kill(e); else - xe_device_add_persitent_engines(xe, e); + xe_device_add_persistent_engines(xe, e); trace_xe_engine_close(e); xe_engine_put(e); diff --git a/drivers/gpu/drm/xe/xe_engine_types.h b/drivers/gpu/drm/xe/xe_engine_types.h index 3dfa1c14e181a..2f6f0f2a0a8bf 100644 --- a/drivers/gpu/drm/xe/xe_engine_types.h +++ b/drivers/gpu/drm/xe/xe_engine_types.h @@ -94,14 +94,14 @@ struct xe_engine { }; /** - * @persitent: persitent engine state + * @persistent: persistent engine state */ struct { /** @xef: file which this engine belongs to */ struct xe_file *xef; - /** @link: link in list of persitent engines */ + /** @link: link in list of persistent engines */ struct list_head link; - } persitent; + } persistent; union { /** diff --git a/drivers/gpu/drm/xe/xe_execlist.c b/drivers/gpu/drm/xe/xe_execlist.c index ae7ee56f1b1b7..e540e5d287a07 100644 --- a/drivers/gpu/drm/xe/xe_execlist.c +++ b/drivers/gpu/drm/xe/xe_execlist.c @@ -400,7 +400,7 @@ static void execlist_engine_fini_async(struct work_struct *w) spin_unlock_irqrestore(&exl->port->lock, flags); if (e->flags & ENGINE_FLAG_PERSISTENT) - xe_device_remove_persitent_engines(gt_to_xe(e->gt), e); + xe_device_remove_persistent_engines(gt_to_xe(e->gt), e); drm_sched_entity_fini(&exl->entity); drm_sched_fini(&exl->sched); kfree(exl); diff --git a/drivers/gpu/drm/xe/xe_guc_submit.c b/drivers/gpu/drm/xe/xe_guc_submit.c index 0ba6f5dcd029f..d0b48c885fda1 100644 --- a/drivers/gpu/drm/xe/xe_guc_submit.c +++ b/drivers/gpu/drm/xe/xe_guc_submit.c @@ -890,7 +890,7 @@ static void __guc_engine_fini_async(struct work_struct *w) trace_xe_engine_destroy(e); if (e->flags & ENGINE_FLAG_PERSISTENT) - xe_device_remove_persitent_engines(gt_to_xe(e->gt), e); + xe_device_remove_persistent_engines(gt_to_xe(e->gt), e); release_guc_id(guc, e); xe_sched_entity_fini(&ge->entity); xe_sched_fini(&ge->sched);