Skip to content

Commit

Permalink
lib/cpumask: drop always-true preprocessor guard
Browse files Browse the repository at this point in the history
Since lib/cpumask.o is only built for CONFIG_SMP=y, NR_CPUS will always
be greater than 1 at compile time.  This makes checking for that
condition unnecesarry, so it can be dropped.

Signed-off-by: Sander Vanheule <sander@svanheule.net>
Signed-off-by: Yury Norov <yury.norov@gmail.com>
  • Loading branch information
Sander Vanheule authored and Yury Norov committed Aug 15, 2022
1 parent 2248ccd commit 61b123f
Showing 1 changed file with 0 additions and 2 deletions.
2 changes: 0 additions & 2 deletions lib/cpumask.c
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,6 @@ void __init free_bootmem_cpumask_var(cpumask_var_t mask)
}
#endif

#if NR_CPUS > 1
/**
* cpumask_local_spread - select the i'th cpu with local numa cpu's first
* @i: index number
Expand Down Expand Up @@ -197,4 +196,3 @@ unsigned int cpumask_any_distribute(const struct cpumask *srcp)
return next;
}
EXPORT_SYMBOL(cpumask_any_distribute);
#endif /* NR_CPUS */

0 comments on commit 61b123f

Please sign in to comment.