summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/powerpc/beatnik/marvell/discovery.c
diff options
context:
space:
mode:
Diffstat (limited to 'c/src/lib/libbsp/powerpc/beatnik/marvell/discovery.c')
-rw-r--r--c/src/lib/libbsp/powerpc/beatnik/marvell/discovery.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/c/src/lib/libbsp/powerpc/beatnik/marvell/discovery.c b/c/src/lib/libbsp/powerpc/beatnik/marvell/discovery.c
index 801d2c99d1..c6f647581f 100644
--- a/c/src/lib/libbsp/powerpc/beatnik/marvell/discovery.c
+++ b/c/src/lib/libbsp/powerpc/beatnik/marvell/discovery.c
@@ -57,6 +57,7 @@
#include <bsp.h>
#include <bsp/gtreg.h>
#include <bsp/pci.h>
+#include <stdint.h>
#ifndef PCI_VENDOR_ID_MARVELL
#define PCI_VENDOR_ID_MARVELL 0x11ab
@@ -78,16 +79,16 @@
static unsigned long
pci_early_config_read(int offset, int width)
{
- out_be32((unsigned int*) pci.pci_config_addr,
+ out_be32((uint32_t*) pci.pci_config_addr,
0x80|(0<<8)|(PCI_DEVFN(0,0)<<16)|((offset&~3)<<24));
switch (width) {
default:
case 1:
- return in_8((unsigned char*)pci.pci_config_data + (offset&3));
+ return in_8((uint8_t*)pci.pci_config_data + (offset&3));
case 2:
- return in_le16((unsigned short*)pci.pci_config_data + (offset&3));
+ return in_le16((uint16_t*)pci.pci_config_data + (offset&3));
case 4:
- return in_le32((unsigned long *)pci.pci_config_data + (offset&3));
+ return in_le32((uint32_t *)pci.pci_config_data + (offset&3));
}
}
#endif