[U-Boot] [PATCH 1/2] drivers/pci/pci_rom.c: fix compile warning under 64bit mode
Minghuan Lian
Minghuan.Lian at freescale.com
Thu Jan 22 06:21:55 CET 2015
Fix this:
drivers/pci/pci_rom.c:95:15: warning: cast to pointer from
integer of different size [-Wint-to-pointer-cast]
rom_header = (struct pci_rom_header *)rom_address;
Signed-off-by: Minghuan Lian <Minghuan.Lian at freescale.com>
---
drivers/pci/pci_rom.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/pci/pci_rom.c b/drivers/pci/pci_rom.c
index 7d25cc9..1ac3f3f 100644
--- a/drivers/pci/pci_rom.c
+++ b/drivers/pci/pci_rom.c
@@ -92,7 +92,7 @@ static int pci_rom_probe(pci_dev_t dev, uint class,
rom_address | PCI_ROM_ADDRESS_ENABLE);
#endif
debug("Option ROM address %x\n", rom_address);
- rom_header = (struct pci_rom_header *)rom_address;
+ rom_header = (struct pci_rom_header *)(unsigned long)rom_address;
debug("PCI expansion ROM, signature %#04x, INIT size %#04x, data ptr %#04x\n",
le32_to_cpu(rom_header->signature),
--
1.9.1
More information about the U-Boot
mailing list