mirror of
https://github.com/torvalds/linux.git
synced 2026-09-24 06:24:02 +02:00
riscv: remove unreachable invalid range check in create_linear_mapping_page_table()
create_linear_mapping_page_table() iterates memblock regions with for_each_mem_range() and breaks the loop when start >= end. for_each_mem_range() never returns an invalid range, so start < end always. Therefore the start >= end check is unreachable, so remove it. No functional change. Signed-off-by: Sang-Heon Jeon <ekffu200098@gmail.com> Reviewed-by: Charlie Jenkins <thecharlesjenkins@gmail.com> Tested-by: Charlie Jenkins <thecharlesjenkins@gmail.com> Link: https://patch.msgid.link/20260630150413.1718632-4-ekffu200098@gmail.com Signed-off-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
This commit is contained in:
parent
68d3b7d582
commit
99e60ebe10
|
|
@ -1229,8 +1229,6 @@ static void __init create_linear_mapping_page_table(void)
|
|||
|
||||
/* Map all memory banks in the linear mapping */
|
||||
for_each_mem_range(i, &start, &end) {
|
||||
if (start >= end)
|
||||
break;
|
||||
if (start <= __pa(PAGE_OFFSET) &&
|
||||
__pa(PAGE_OFFSET) < end)
|
||||
start = __pa(PAGE_OFFSET);
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user