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

Pedro Falcato <[email protected]> Fri, 31 Jul 2026 11:33:47 +0100
Newsgroups dev.linux.lists.linux-kernel-mentees,org.kernel.vger.linux-kernel,org.kvack.linux-mm
Message-ID <amx5XdMQ7S_krjNA@pedro-suse>
On Thu, Jul 30, 2026 at 10:47:24PM +0200, Jakov Novak wrote:
> Currently, khugepaged locks the khugepaged_mutex in two functions:
> start_stop_khugepaged and khugepaged_min_free_kbytes_update. Remove
> mutex_lock/mutex_unlock usage in these functions and replace it with the
> guard macro. This makes the code more readable (removing a goto statement)
> and makes it harder to introduce bugs in the future.
> No functional changes introduced.
> 
> Signed-off-by: Jakov Novak <[email protected]>
> Reviewed-by: Dev Jain <[email protected]>
> Reviewed-by: Lorenzo Stoakes (ARM) <[email protected]>
> Reviewed-by: Andrew Morton <[email protected]>

Hmm, did Andrew actually give this R-b tag out? I can't find it on-list. 

-- 
Pedro