diff options
author | Thomas Huth <thuth@linux.vnet.ibm.com> | 2011-11-28 11:35:08 +0100 |
---|---|---|
committer | Thomas Huth <thuth@linux.vnet.ibm.com> | 2011-12-20 17:56:34 +0100 |
commit | 33bb95bab24d2dca03ee9e641d0e98d9fbd86fdd (patch) | |
tree | eca73c12131b0765e3dfb9fe33a4df2397e932bd /board-js2x/rtas/rtas_board.c | |
parent | ec10f8af354266ba2576cfcc7d0c443a0cdbd7e9 (diff) | |
download | SLOF-33bb95bab24d2dca03ee9e641d0e98d9fbd86fdd.zip SLOF-33bb95bab24d2dca03ee9e641d0e98d9fbd86fdd.tar.gz SLOF-33bb95bab24d2dca03ee9e641d0e98d9fbd86fdd.tar.bz2 |
Silenced some compiler warnings that occur when compiling with prototype checks
The compiler flags -Wmissing-prototypes and -Wstrict-prototypes generally help
to write code with proper prototypes. This way one can avoid some ugly bugs
because it helps to identify functions that do not have prototypes in headers.
It also helps to improve performance since local functions then have to be
declared "static", so the compiler can do better optimizations.
Signed-off-by: Thomas Huth <thuth@linux.vnet.ibm.com>
Diffstat (limited to 'board-js2x/rtas/rtas_board.c')
-rw-r--r-- | board-js2x/rtas/rtas_board.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/board-js2x/rtas/rtas_board.c b/board-js2x/rtas/rtas_board.c index 9b20566..7f7409d 100644 --- a/board-js2x/rtas/rtas_board.c +++ b/board-js2x/rtas/rtas_board.c @@ -20,6 +20,8 @@ #include <hw.h> void io_init(void); +short reg_get_flashside(void); +void rtas_init(void); typedef struct { uint64_t r3; @@ -29,7 +31,7 @@ typedef struct { volatile slave_t rtas_slave_interface; -void +static void rtas_slave_loop(volatile slave_t * pIface) { uint64_t mask = pIface->id; @@ -39,8 +41,8 @@ rtas_slave_loop(volatile slave_t * pIface) while (dly--); } pIface->id = 0; - asm(" mr 3,%0 ; mtctr %1 ; bctr "::"r"(pIface->r3), "r"(pIface->addr)); - + asm volatile (" mr 3,%0 ; mtctr %1 ; bctr " + ::"r"(pIface->r3), "r"(pIface->addr)); } void @@ -162,7 +164,7 @@ rtas_get_blade_descr(rtas_args_t * pArgs) } // for JS20 cannot read blade descr -uint32_t +static uint32_t dummy_get_blade_descr(uint8_t *dst, uint32_t maxlen, uint32_t *len) { // to not have a warning we need to do _something_ with *dst and maxlen... |