From da3b8d3ef859b19983c22113f6b783c666a7bbc0 Mon Sep 17 00:00:00 2001 From: Joel Sherrill Date: Fri, 5 Mar 2004 18:09:14 +0000 Subject: 2004-03-05 Joel Sherrill * bootloader/pci.c: Remove warnings by adding include . * irq/irq.c: Clean up includes to remove warnings. * pci/pci.c, pci/pci.h, startup/bspstart.c: Better use of const on struct _int_map. --- c/src/lib/libbsp/powerpc/shared/ChangeLog | 7 +++++++ c/src/lib/libbsp/powerpc/shared/bootloader/pci.c | 1 + c/src/lib/libbsp/powerpc/shared/irq/irq.c | 6 +++--- c/src/lib/libbsp/powerpc/shared/pci/pci.c | 5 +++-- c/src/lib/libbsp/powerpc/shared/pci/pci.h | 2 +- c/src/lib/libbsp/powerpc/shared/startup/bspstart.c | 2 +- 6 files changed, 16 insertions(+), 7 deletions(-) diff --git a/c/src/lib/libbsp/powerpc/shared/ChangeLog b/c/src/lib/libbsp/powerpc/shared/ChangeLog index b06df3dd2d..d599b8a3d1 100644 --- a/c/src/lib/libbsp/powerpc/shared/ChangeLog +++ b/c/src/lib/libbsp/powerpc/shared/ChangeLog @@ -1,3 +1,10 @@ +2004-03-05 Joel Sherrill + + * bootloader/pci.c: Remove warnings by adding include . + * irq/irq.c: Clean up includes to remove warnings. + * pci/pci.c, pci/pci.h, startup/bspstart.c: Better use of const + on struct _int_map. + 2004-03-03 Joel Sherrill * vectors/vectors.h, vectors/vectors_init.c: Undo previous change. diff --git a/c/src/lib/libbsp/powerpc/shared/bootloader/pci.c b/c/src/lib/libbsp/powerpc/shared/bootloader/pci.c index fb82168320..b23e12d7c9 100644 --- a/c/src/lib/libbsp/powerpc/shared/bootloader/pci.c +++ b/c/src/lib/libbsp/powerpc/shared/bootloader/pci.c @@ -25,6 +25,7 @@ #include #include +#include typedef unsigned int u32; diff --git a/c/src/lib/libbsp/powerpc/shared/irq/irq.c b/c/src/lib/libbsp/powerpc/shared/irq/irq.c index 2ff8ab2197..0f7d50fa9b 100644 --- a/c/src/lib/libbsp/powerpc/shared/irq/irq.c +++ b/c/src/lib/libbsp/powerpc/shared/irq/irq.c @@ -10,14 +10,14 @@ * * $Id$ */ + +#include -#include #include #include #include #include -#include -#include +#include /* for post ISR signal processing */ #include #include #include diff --git a/c/src/lib/libbsp/powerpc/shared/pci/pci.c b/c/src/lib/libbsp/powerpc/shared/pci/pci.c index cd4af5a321..ff81df8d65 100644 --- a/c/src/lib/libbsp/powerpc/shared/pci/pci.c +++ b/c/src/lib/libbsp/powerpc/shared/pci/pci.c @@ -236,7 +236,8 @@ const pci_config_access_functions pci_direct_functions = { ** Validate a test interrupt name and print a warning if its not one of ** the names defined in the routing record. */ -static int test_intname( struct _int_map *row, int pbus, int pslot, int int_pin, int int_name ) +static int test_intname( + const struct _int_map *row, int pbus, int pslot, int int_pin, int int_name ) { int j,k; int _nopin= -1, _noname= -1; @@ -333,7 +334,7 @@ static int FindPCIbridge( int mybus, struct pcibridge *pb ) -void FixupPCI( struct _int_map *bspmap, int (*swizzler)(int,int) ) +void FixupPCI( const struct _int_map *bspmap, int (*swizzler)(int,int) ) { unsigned char cvalue; unsigned16 devid; diff --git a/c/src/lib/libbsp/powerpc/shared/pci/pci.h b/c/src/lib/libbsp/powerpc/shared/pci/pci.h index bacf8d51b5..0971a0ec48 100644 --- a/c/src/lib/libbsp/powerpc/shared/pci/pci.h +++ b/c/src/lib/libbsp/powerpc/shared/pci/pci.h @@ -1164,7 +1164,7 @@ struct _int_map struct _pin_routes pin_route[5]; }; -void FixupPCI( struct _int_map *, int (*swizzler)(int,int) ); +void FixupPCI( const struct _int_map *, int (*swizzler)(int,int) ); /* scan for a specific device */ diff --git a/c/src/lib/libbsp/powerpc/shared/startup/bspstart.c b/c/src/lib/libbsp/powerpc/shared/startup/bspstart.c index 1927ea96db..79d2786d06 100644 --- a/c/src/lib/libbsp/powerpc/shared/startup/bspstart.c +++ b/c/src/lib/libbsp/powerpc/shared/startup/bspstart.c @@ -309,7 +309,7 @@ void bsp_start( void ) InitializePCI(); { - struct _int_map *bspmap = motorolaIntMap(currentBoard); + const struct _int_map *bspmap = motorolaIntMap(currentBoard); if( bspmap ) { printk("pci : Configuring interrupt routing for '%s'\n", motorolaBoardToString(currentBoard)); -- cgit v1.2.3