]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
mm/memblock: pass size instead of end to memblock_set_node()
authorWei Yang <richard.weiyang@gmail.com>
Tue, 18 Mar 2025 07:19:46 +0000 (07:19 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 9 May 2025 07:43:51 +0000 (09:43 +0200)
commitc0fabecd65103550a1967c236d7c483d3c5368e1
tree80218ace1740516a0dee03529269cd7c9adfb24f
parentdfbaecf7e38f5e9bfa5e47a1e525ffbb58bab8cf
mm/memblock: pass size instead of end to memblock_set_node()

commit 06eaa824fd239edd1eab2754f29b2d03da313003 upstream.

The second parameter of memblock_set_node() is size instead of end.

Since it iterates from lower address to higher address, finally the node
id is correct. But during the process, some of them are wrong.

Pass size instead of end.

Fixes: 61167ad5fecd ("mm: pass nid to reserve_bootmem_region()")
Signed-off-by: Wei Yang <richard.weiyang@gmail.com>
CC: Mike Rapoport <rppt@kernel.org>
CC: Yajun Deng <yajun.deng@linux.dev>
CC: stable@vger.kernel.org
Reviewed-by: Anshuman Khandual <anshuman.khandual@arm.com>
Link: https://lore.kernel.org/r/20250318071948.23854-2-richard.weiyang@gmail.com
Signed-off-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
mm/memblock.c