]> www.infradead.org Git - users/jedix/linux-maple.git/commit
mm/mm_init.c: use round_up() to calculate usermap size
authorWei Yang <richard.weiyang@gmail.com>
Wed, 12 Feb 2025 01:38:18 +0000 (01:38 +0000)
committerAndrew Morton <akpm@linux-foundation.org>
Mon, 17 Mar 2025 05:06:14 +0000 (22:06 -0700)
commitbf40aa214195864eeb63165cfb02e959c464d409
tree271cd6115d130c52e5f0fbbde8a58b4b1e34ea73
parent85968b6a2042cd19c6afd1fb49b64bd32f3a4d07
mm/mm_init.c: use round_up() to calculate usermap size

Since pageblock_nr_pages and BITS_PER_LONG are power of 2, we could use
round_up() to calculate it.

Also we have renamed blockflags to pageblock_flags, adjust the comment
accordingly.

Link: https://lkml.kernel.org/r/20250212013818.873-1-richard.weiyang@gmail.com
Signed-off-by: Wei Yang <richard.weiyang@gmail.com>
Suggested-by: Shivank Garg <shivankg@amd.com>
Reviewed-by: Shivank Garg <shivankg@amd.com>
Acked-by: David Hildenbrand <david@redhat.com>
Reviewed-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
Reviewed-by: Anshuman Khandual <anshuman.khandual@arm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/mm_init.c