m68k: mm: Fix systems with memory at end of 32-bit address space
authorKars de Jong <jongk@linux-m68k.org>
Thu, 23 Feb 2023 11:23:49 +0000 (12:23 +0100)
committerGeert Uytterhoeven <geert@linux-m68k.org>
Mon, 6 Mar 2023 13:09:42 +0000 (14:09 +0100)
commit0d9fad91abfd723ea5070a46d98a9f4496c93ba9
tree1f8ef0fd73d1370c937ae79ffa0ca76c535b17dd
parentfe15c26ee26efa11741a7b632e9f23b01aca4cc6
m68k: mm: Fix systems with memory at end of 32-bit address space

The calculation of end addresses of memory chunks overflowed to 0 when
a memory chunk is located at the end of 32-bit address space.
This is the case for the HP300 architecture.

Link: https://lore.kernel.org/linux-m68k/CACz-3rhUo5pgNwdWHaPWmz+30Qo9xCg70wNxdf7o5x-6tXq8QQ@mail.gmail.com/
Signed-off-by: Kars de Jong <jongk@linux-m68k.org>
Reviewed-by: Geert Uytterhoeven <geert@linux-m68k.org>
Link: https://lore.kernel.org/r/20230223112349.26675-1-jongk@linux-m68k.org
Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
arch/m68k/mm/motorola.c