lkml.org 
[lkml]   [2022]   [Jul]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] drm/i915/gem: Really move i915_gem_context.link under ref protection
Hi,

[...]

> @@ -1265,10 +1264,15 @@ static void i915_gem_context_release_work(struct work_struct *work)
> struct i915_gem_context *ctx = container_of(work, typeof(*ctx),
> release_work);
> struct i915_address_space *vm;
> + unsigned long flags;
>
> trace_i915_context_free(ctx);
> GEM_BUG_ON(!i915_gem_context_is_closed(ctx));
>
> + spin_lock_irqsave(&ctx->i915->gem.contexts.lock, flags);
> + list_del(&ctx->link);
> + spin_unlock_irqrestore(&ctx->i915->gem.contexts.lock, flags);
> +

yah! this can't work from a worker.

Andi

\
 
 \ /
  Last update: 2022-07-07 00:37    [W:0.066 / U:0.072 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site