aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/x86/mm/ioremap_32.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/x86/mm/ioremap_32.c b/arch/x86/mm/ioremap_32.c
index 7f7daf50efed..b743de841f68 100644
--- a/arch/x86/mm/ioremap_32.c
+++ b/arch/x86/mm/ioremap_32.c
@@ -311,6 +311,22 @@ static inline void __init early_clear_fixmap(enum fixed_addresses idx)
311 311
312int __initdata early_ioremap_nested; 312int __initdata early_ioremap_nested;
313 313
314static int __init check_early_ioremap_leak(void)
315{
316 if (!early_ioremap_nested)
317 return 0;
318
319 printk(KERN_WARNING
320 "Debug warning: early ioremap leak of %d areas detected.\n",
321 early_ioremap_nested);
322 printk(KERN_WARNING
323 "please boot with early_ioremap_debug and report the dmesg.\n");
324 WARN_ON(1);
325
326 return 1;
327}
328late_initcall(check_early_ioremap_leak);
329
314void __init *early_ioremap(unsigned long phys_addr, unsigned long size) 330void __init *early_ioremap(unsigned long phys_addr, unsigned long size)
315{ 331{
316 unsigned long offset, last_addr; 332 unsigned long offset, last_addr;