diff options
author | 2024-06-19 01:06:09 +0000 | |
---|---|---|
committer | 2024-07-03 19:30:19 -0700 | |
commit | 861dd8b9e34fc3fc05762a952ad8dd701dc0f0f1 (patch) | |
tree | ecbe4cb37b865314ed1bd54ad87d28ac4e336246 /mm/memory.c | |
parent | mm/memory-failure: refactor log format in unpoison_memory (diff) | |
download | wireguard-linux-861dd8b9e34fc3fc05762a952ad8dd701dc0f0f1.tar.xz wireguard-linux-861dd8b9e34fc3fc05762a952ad8dd701dc0f0f1.zip |
mm/sparse: nr_pages won't be 0
Function subsection_map_init() is only used in free_area_init() in the
loop of for_each_mem_pfn_range(). And we are sure in each iteration of
for_each_mem_pfn_range(), start_pfn < end_pfn.
So nr_pages is not possible to be 0 and we can remove the check.
Link: https://lkml.kernel.org/r/20240619010612.20740-1-richard.weiyang@gmail.com
Signed-off-by: Wei Yang <richard.weiyang@gmail.com>
Cc: Mike Rapoport (IBM) <rppt@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'mm/memory.c')
0 files changed, 0 insertions, 0 deletions