Skip to content
Commit 1b0332a4 authored by Yu-Chun Lin's avatar Yu-Chun Lin Committed by Frederic Weisbecker
Browse files

kthread: Fix return value on kzalloc() failure in kthread_affine_preferred()



kthread_affine_preferred() incorrectly returns 0 instead of -ENOMEM
when kzalloc() fails. Return 'ret' to ensure the correct error code is
propagated.

Fixes: 4d13f430 ("kthread: Implement preferred affinity")
Reported-by: default avatarkernel test robot <lkp@intel.com>
Closes: https://lore.kernel.org/oe-kbuild-all/202501301528.t0cZVbnq-lkp@intel.com/


Signed-off-by: default avatarYu-Chun Lin <eleanor15x@gmail.com>
Signed-off-by: default avatarFrederic Weisbecker <frederic@kernel.org>
parent 2014c95a
Loading
Loading
Loading
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