Re: [PATCH v2] mm/khugepaged: replace mutex_lock/mutex_unlock usage with guard macro

"David Hildenbrand (Arm)" <[email protected]> Thu, 30 Jul 2026 16:01:52 +0200
Newsgroups dev.linux.lists.linux-kernel-mentees,org.kernel.vger.linux-kernel,org.kvack.linux-mm
Message-ID <[email protected]>
On 7/29/26 13:56, jakov novak wrote:
> I guess the error checking could be moved inside the if
> (!khugepaged_thread) block like:
> 
> if (!khugepaged_thread) {
>   struct task_struct *new_thread = kthread_run...
> 
>   if (IS_ERR(new_thread)) {
>     pr_err...
>     return PTR_ERR(new_thread);
>   }
> 
>   khugepaged_thread = new_thread;
> }
> 
> I can send a v3 with these changes if this looks good to everybody.
>

Yes, please so so.

-- 
Cheers,

David