x86/mm: Drop WARN from multi-BAR check
PATCH 1/1 x86/mm: Drop WARN from multi-BAR check
ioremapping multiple BARs produces a warning with a message "Your kernel is fine". This message mostly serves to comfort kernel developers. Users do not read the message, they only see the big scary warning which means something must be horribly broken with their system. Less dramatically, the warn also sets the taint flag which makes it difficult to differentiate problems. If the kernel is actually fine as the warning claims it doesn't make sense for it to be tainted. Change the WARN_ONCE to a pr_warn with the caller of the ioremap.
--- arch/x86/mm/ioremap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/mm/ioremap.c +2 -2
@@ -194,8 +194,8 @@ static void __iomem *__ioremap_caller(resource_size_t phys_addr,* Check if the request spans more than any BAR in the iomem resource * tree. */ -WARN_ONCE (iomem_map_sanity_check (unaligned_phys_addr, unaligned_size), -KERN_INFO "Info: mapping multiple BARs. Your kernel is fine." ); +if (iomem_map_sanity_check (unaligned_phys_addr, unaligned_size)) +pr_warn ("caller %pS mapping multiple BARs\n" , caller);return ret_addr; err_free_area:
Signature · 1 line
2.5.0
tip-bot for Laura Abbott
merge botx86/mm: Drop WARN from multi-BAR check
Commit-ID: 9abb0ecdee69a2577560cc283368e490da974934 Gitweb: http://git.kernel.org/tip/9abb0ecdee69a2577560cc283368e490da974934 Author: Laura Abbott <[email protected]> AuthorDate: Mon, 21 Dec 2015 12:01:14 -0800 Committer: Thomas Gleixner <[email protected]> CommitDate: Tue, 29 Dec 2015 12:34:38 +0100
x86/mm: Drop WARN from multi-BAR check
ioremapping multiple BARs produces a warning with a message "Your kernel is fine". This message mostly serves to comfort kernel developers. Users do not read the message, they only see the big scary warning which means something must be horribly broken with their system. Less dramatically, the warn also sets the taint flag which makes it difficult to differentiate problems. If the kernel is actually fine as the warning claims it doesn't make sense for it to be tainted. Change the WARN_ONCE to a pr_warn with the caller of the ioremap.
--- arch/x86/mm/ioremap.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/mm/ioremap.c +2 -2
@@ -194,8 +194,8 @@ static void __iomem *__ioremap_caller(resource_size_t phys_addr,* Check if the request spans more than any BAR in the iomem resource * tree. */ -WARN_ONCE (iomem_map_sanity_check (unaligned_phys_addr, unaligned_size), -KERN_INFO "Info: mapping multiple BARs. Your kernel is fine." ); +if (iomem_map_sanity_check (unaligned_phys_addr, unaligned_size)) +pr_warn ("caller %pS mapping multiple BARs\n" , caller);return ret_addr; err_free_area: