Skip to content

Commit fc7984c

Browse files
committed
padata: Clean up in padata_do_multithreaded()
JIRA: https://issues.redhat.com/browse/RHEL-81522 commit e45f0ab Author: Zicheng Qu <quzicheng@huawei.com> Date: Fri, 1 Nov 2024 09:13:24 +0000 padata: Clean up in padata_do_multithreaded() In commit 24cc57d ("padata: Honor the caller's alignment in case of chunk_size 0"), the line 'ps.chunk_size = max(ps.chunk_size, 1ul)' was added, making 'ps.chunk_size = 1U' redundant and never executed. Signed-off-by: Zicheng Qu <quzicheng@huawei.com> Acked-by: Daniel Jordan <daniel.m.jordan@oracle.com> Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> Signed-off-by: Waiman Long <longman@redhat.com>
1 parent 5150d3a commit fc7984c

File tree

1 file changed

+0
-7
lines changed

1 file changed

+0
-7
lines changed

kernel/padata.c

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -521,13 +521,6 @@ void __init padata_do_multithreaded(struct padata_mt_job *job)
521521
ps.chunk_size = max(ps.chunk_size, 1ul);
522522
ps.chunk_size = roundup(ps.chunk_size, job->align);
523523

524-
/*
525-
* chunk_size can be 0 if the caller sets min_chunk to 0. So force it
526-
* to at least 1 to prevent divide-by-0 panic in padata_mt_helper().`
527-
*/
528-
if (!ps.chunk_size)
529-
ps.chunk_size = 1U;
530-
531524
list_for_each_entry(pw, &works, pw_list)
532525
if (job->numa_aware) {
533526
int old_node = atomic_read(&last_used_nid);

0 commit comments

Comments
 (0)