[Intel-gfx] [PATCH v2] drm/i915: avoid flush_scheduled_work() usage

Luca Coelho luca at coelho.fi
Wed Mar 15 10:47:38 UTC 2023


On Tue, 2023-03-14 at 20:21 +0900, Tetsuo Handa wrote:
> Like commit c4f135d643823a86 ("workqueue: Wrap flush_workqueue() using a
> macro") says, flush_scheduled_work() is dangerous and will be forbidden.
> 
> Now that i915 is the last flush_scheduled_work() user, for now let's
> start with blind conversion inside the whole drivers/gpu/drm/i915/
> directory. Jani Nikula wants to use two workqueues in order to avoid
> adding new module globals, but I'm not familiar enough to audit and
> split into two workqueues.
> 
> Link: https://lkml.kernel.org/r/87sfeita1p.fsf@intel.com
> Signed-off-by: Tetsuo Handa <penguin-kernel at I-love.SAKURA.ne.jp>
> Cc: Tvrtko Ursulin <tvrtko.ursulin at intel.com>
> Cc: Jani Nikula <jani.nikula at intel.com>
> Cc: Ville Syrjälä <ville.syrjala at linux.intel.com>
> ---
> Changes in v2:
>   Add missing alloc_workqueue() failure check.

Hi,

Thanks for your patch! But it seems that you only fixed that failure
check, without making the other change Jani proposed, namely, move the
work to the i915 struct instead of making it a global.

I'm working on that now.

--
Cheers,
Luca.


More information about the dri-devel mailing list