Merge tag 'nvme-6.5-2023-06-30' of git://git.infradead.org/nvme into block-6.5
[platform/kernel/linux-starfive.git] / mm / early_ioremap.c
index 9bc12e5..ce06b28 100644 (file)
@@ -72,12 +72,10 @@ void __init early_ioremap_setup(void)
 {
        int i;
 
-       for (i = 0; i < FIX_BTMAPS_SLOTS; i++)
-               if (WARN_ON(prev_map[i]))
-                       break;
-
-       for (i = 0; i < FIX_BTMAPS_SLOTS; i++)
+       for (i = 0; i < FIX_BTMAPS_SLOTS; i++) {
+               WARN_ON_ONCE(prev_map[i]);
                slot_virt[i] = __fix_to_virt(FIX_BTMAP_BEGIN - NR_FIX_BTMAPS*i);
+       }
 }
 
 static int __init check_early_ioremap_leak(void)