Skip to content
Snippets Groups Projects
Commit 8b20280b authored by Zbigniew Kempczyński's avatar Zbigniew Kempczyński
Browse files

lib/igt_core: reinitialize log_buffer_mutex in child process


For multi-process scenario intel-allocator is dedicated thread which
handles clients (children processes) allocations. Main thread which
spawns children may hit point of time where allocator thread locked
some mutex. One of it is log_buffer_mutex used in igt_log(). Children
which would try to call igt_info/warn/debug() family will stuck as
this mutex is already locked.

Reinitialize this mutex in igt_fork() to avoid deadlocks in allocator
scenarios.

Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Cc: Dominik Karol Piątkowski <dominik.karol.piatkowski@intel.com>
Cc: Kamil Konieczny <kamil.konieczny@linux.intel.com>
Reviewed-by: default avatarDominik Karol Piątkowski <dominik.karol.piatkowski@intel.com>
Reviewed-by: default avatarKamil Konieczny <kamil.konieczny@linux.intel.com>
Link: https://lore.kernel.org/r/20250317113146.560156-1-zbigniew.kempczynski@intel.com


Signed-off-by: default avatarZbigniew Kempczyński <zbigniew.kempczynski@intel.com>
parent 534d7519
No related branches found
No related tags found
No related merge requests found
Pipeline #1385527 passed
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment