[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <iqhynhx6xx67b2jpjazmzufh63nh24uqsawn7thlvlo4ezb3pp@rtvz6u5cc4ug>
Date: Thu, 22 Aug 2024 20:50:20 -0400
From: Daniel Jordan <daniel.m.jordan@...cle.com>
To: Kamlesh Gurudasani <kamlesh@...com>
Cc: Steffen Klassert <steffen.klassert@...unet.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Waiman Long <longman@...hat.com>,
Herbert Xu <herbert@...dor.apana.org.au>, linux-crypto@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] padata: Honor the caller's alignment in case of
chunk_size 0
On Thu, Aug 22, 2024 at 02:32:52AM GMT, Kamlesh Gurudasani wrote:
> In the case where we are forcing the ps.chunk_size to be at least 1,
> we are ignoring the caller's alignment.
>
> Move the forcing of ps.chunk_size to be at least 1 before rounding it
> up to caller's alignment, so that caller's alignment is honored.
>
> While at it, use max() to force the ps.chunk_size to be at least 1 to
> improve readability.
>
> Fixes: 6d45e1c948a8 ("padata: Fix possible divide-by-0 panic in padata_mt_helper()")
Looks fine.
Acked-by: Daniel Jordan <daniel.m.jordan@...cle.com>
> Signed-off-by: Kamlesh Gurudasani <kamlesh@...com>
> ---
> kernel/padata.c | 12 ++++--------
> 1 file changed, 4 insertions(+), 8 deletions(-)
>
> diff --git a/kernel/padata.c b/kernel/padata.c
> index 0fa6c2895460..d8a51eff1581 100644
> --- a/kernel/padata.c
> +++ b/kernel/padata.c
> @@ -509,21 +509,17 @@ void __init padata_do_multithreaded(struct padata_mt_job *job)
>
> /*
> * Chunk size is the amount of work a helper does per call to the
> - * thread function. Load balance large jobs between threads by
> + * thread function. Load balance large jobs between threads by
Though whitespace changes like these just add noise...
Powered by blists - more mailing lists