Merge branches 'core/softlockup', 'core/softirq', 'core/resources', 'core/printk...
[pandora-kernel.git] / arch / x86 / mm / ioremap.c
index e4c43ec..ae71e11 100644 (file)
@@ -219,6 +219,12 @@ static void __iomem *__ioremap_caller(resource_size_t phys_addr,
        if (is_ISA_range(phys_addr, last_addr))
                return (__force void __iomem *)phys_to_virt(phys_addr);
 
+       /*
+        * Check if the request spans more than any BAR in the iomem resource
+        * tree.
+        */
+       WARN_ON(iomem_map_sanity_check(phys_addr, size));
+
        /*
         * Don't allow anybody to remap normal RAM that we're using..
         */