diff options
Diffstat (limited to 'board')
-rw-r--r-- | board/mpl/common/flash.c | 10 | ||||
-rw-r--r-- | board/mpl/pati/cmd_pati.c | 2 | ||||
-rw-r--r-- | board/mpl/pati/pati.c | 4 |
3 files changed, 10 insertions, 6 deletions
diff --git a/board/mpl/common/flash.c b/board/mpl/common/flash.c index 302d7a3..355608c 100644 --- a/board/mpl/common/flash.c +++ b/board/mpl/common/flash.c @@ -819,13 +819,17 @@ static FLASH_WORD_SIZE *read_val = (FLASH_WORD_SIZE *)0x200000; static int write_word (flash_info_t *info, ulong dest, ulong data) { - volatile FLASH_WORD_SIZE *addr2 = (FLASH_WORD_SIZE *)(info->start[0]); - volatile FLASH_WORD_SIZE *dest2 = (FLASH_WORD_SIZE *)dest; - volatile FLASH_WORD_SIZE *data2 = (FLASH_WORD_SIZE *)&data; + volatile FLASH_WORD_SIZE *addr2 = (volatile FLASH_WORD_SIZE *)(info->start[0]); + volatile FLASH_WORD_SIZE *dest2 = (volatile FLASH_WORD_SIZE *)dest; + volatile FLASH_WORD_SIZE *data2; ulong start; + ulong *data_p; int flag; int i; + data_p = &data; + data2 = (volatile FLASH_WORD_SIZE *)data_p; + /* Check if Flash is (sufficiently) erased */ if ((*((volatile FLASH_WORD_SIZE *)dest) & (FLASH_WORD_SIZE)data) != (FLASH_WORD_SIZE)data) { diff --git a/board/mpl/pati/cmd_pati.c b/board/mpl/pati/cmd_pati.c index 0682323..740881e 100644 --- a/board/mpl/pati/cmd_pati.c +++ b/board/mpl/pati/cmd_pati.c @@ -276,7 +276,7 @@ static int pati_pci_eeprom_write(unsigned short offset, unsigned long addr, unsi static int pati_pci_eeprom_read(unsigned short offset, unsigned long addr, unsigned short size) { int i; - unsigned short value; + unsigned short value = 0; unsigned short *buffer =(unsigned short *)addr; if((offset + size) > PATI_EEPROM_LAST_OFFSET) { size = PATI_EEPROM_LAST_OFFSET - offset; diff --git a/board/mpl/pati/pati.c b/board/mpl/pati/pati.c index 8f23d2d..1b3b698 100644 --- a/board/mpl/pati/pati.c +++ b/board/mpl/pati/pati.c @@ -347,8 +347,8 @@ int last_stage_init (void) int checkboard (void) { - unsigned char s[50]; - unsigned long reg; + char s[50]; + ulong reg; char rev; int i; |