mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] probe_roms.c: quiet sparse noise and fix return type of pci_map_biosrom
@ 2011-09-09 21:42 H Hartley Sweeten
  0 siblings, 0 replies; only message in thread
From: H Hartley Sweeten @ 2011-09-09 21:42 UTC (permalink / raw)
  To: Linux Kernel
  Cc: x86, tglx, mingo, hpa, paul.gortmaker, jkosina, dave.jiang, joe,
	dan.j.williams

The function pci_map_biosrom is declared in <asm/probe_roms.h> as returning
a void __iomem * but is implemented in the code to return a void *.

Include <asm/probe_roms.h> to pick up the declarations and fix the return
type of pci_map_biosrom to match the declaration.  This quiets the following
sparse noise:

warning: incorrect type in return expression (different address spaces)
   expected void *
   got void [noderef] <asn:2>*
warning: symbol 'pci_map_biosrom' was not declared. Should it be static?
warning: symbol 'pci_unmap_biosrom' was not declared. Should it be static?
warning: symbol 'pci_biosrom_size' was not declared. Should it be static?

Signed-off-by: H Hartley Sweeten <hsweeten@visionengravers.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Paul Gortmaker <paul.gortmaker@windriver.com>
Cc: Jiri Kosina <jkosina@suse.cz>
Cc: Dave Jiang <dave.jiang@intel.com>
Cc: Joe Perches <joe@perches.com>
Cc: Dan Williams <dan.j.williams@intel.com>

---

diff --git a/arch/x86/kernel/probe_roms.c b/arch/x86/kernel/probe_roms.c
index 34e06e8..c0a8915 100644
--- a/arch/x86/kernel/probe_roms.c
+++ b/arch/x86/kernel/probe_roms.c
@@ -19,6 +19,7 @@
 #include <asm/sections.h>
 #include <asm/io.h>
 #include <asm/setup_arch.h>
+#include <asm/probe_roms.h>
 
 static struct resource system_rom_resource = {
 	.name	= "System ROM",
@@ -149,7 +150,7 @@ static struct resource *find_oprom(struct pci_dev *pdev)
 	return oprom;
 }
 
-void *pci_map_biosrom(struct pci_dev *pdev)
+void __iomem *pci_map_biosrom(struct pci_dev *pdev)
 {
 	struct resource *oprom = find_oprom(pdev);
 

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2011-09-09 21:42 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-09-09 21:42 [PATCH] probe_roms.c: quiet sparse noise and fix return type of pci_map_biosrom H Hartley Sweeten

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®