Skip to content

Commit 0d08e7b

Browse files
osctobeRussell King (Oracle)
authored andcommitted
ARM: 9155/1: fix early early_iounmap()
Currently __set_fixmap() bails out with a warning when called in early boot from early_iounmap(). Fix it, and while at it, make the comment a bit easier to understand. Cc: <[email protected]> Fixes: b089c31 ("ARM: 8667/3: Fix memory attribute inconsistencies when using fixmap") Acked-by: Ard Biesheuvel <[email protected]> Signed-off-by: Michał Mirosław <[email protected]> Signed-off-by: Russell King (Oracle) <[email protected]>
1 parent 00568b8 commit 0d08e7b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

arch/arm/mm/mmu.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -390,9 +390,9 @@ void __set_fixmap(enum fixed_addresses idx, phys_addr_t phys, pgprot_t prot)
390390
BUILD_BUG_ON(__fix_to_virt(__end_of_fixed_addresses) < FIXADDR_START);
391391
BUG_ON(idx >= __end_of_fixed_addresses);
392392

393-
/* we only support device mappings until pgprot_kernel has been set */
393+
/* We support only device mappings before pgprot_kernel is set. */
394394
if (WARN_ON(pgprot_val(prot) != pgprot_val(FIXMAP_PAGE_IO) &&
395-
pgprot_val(pgprot_kernel) == 0))
395+
pgprot_val(prot) && pgprot_val(pgprot_kernel) == 0))
396396
return;
397397

398398
if (pgprot_val(prot))

0 commit comments

Comments
 (0)