]> git.karo-electronics.de Git - karo-tx-uboot.git/blobdiff - board/cmi/flash.c
Big white-space cleanup.
[karo-tx-uboot.git] / board / cmi / flash.c
index 9c802b9131dccb4649769cedc1138743e7a988e5..f57d8ecfe9027d7664ca499a3d620fc280cca3bf 100644 (file)
@@ -25,7 +25,7 @@
  * File:               flash.c
  *
  * Discription:                This Driver is for 28F320J3A, 28F640J3A and
- *                     28F128J3A Intel flashs working in 16 Bit mode.
+ *                     28F128J3A Intel flashs working in 16 Bit mode.
  *                     They are single bank flashs.
  *
  *                     Most of this code is taken from existing u-boot
@@ -67,9 +67,9 @@ flash_info_t  flash_info[CFG_MAX_FLASH_BANKS];
 /*
  * Local function prototypes
  */
-static ulong   flash_get_size          (vu_short *addr, flash_info_t *info);
-static int     write_short             (flash_info_t *info, ulong dest, ushort data);
-static void    flash_get_offsets       (ulong base, flash_info_t *info);
+static ulong   flash_get_size          (vu_short *addr, flash_info_t *info);
+static int     write_short             (flash_info_t *info, ulong dest, ushort data);
+static void    flash_get_offsets       (ulong base, flash_info_t *info);
 
 /*
  * Initialize flash
@@ -458,7 +458,7 @@ static int write_short (flash_info_t *info, ulong dest, ushort data)
        if (!(info->flash_id & FLASH_VENDMASK)) {
                return 4;
        }
-        *addr = FLASH_CMD_ERASE_CONFIRM;
+       *addr = FLASH_CMD_ERASE_CONFIRM;
        *addr = FLASH_CMD_WRITE;
 
        *((vu_short *)dest) = data;
@@ -474,7 +474,7 @@ static int write_short (flash_info_t *info, ulong dest, ushort data)
        /* wait for error or finish */
        while(!(addr[0] & FLASH_STATUS_DONE)){
                if (get_timer(start) > CFG_FLASH_WRITE_TOUT) {
-                       addr[0] = FLASH_CMD_RESET;
+                       addr[0] = FLASH_CMD_RESET;
                        return (1);
                }
        }
@@ -505,7 +505,7 @@ int flash_real_protect(flash_info_t *info, long sector, int prot)
        start = get_timer (0);
        while(!(addr[0] & FLASH_STATUS_DONE)){
                if (get_timer(start) > CFG_FLASH_ERASE_TOUT) {
-                       printf("Flash protect timeout at address %lx\n",  info->start[sector]);
+                       printf("Flash protect timeout at address %lx\n",  info->start[sector]);
                        addr[0] = FLASH_CMD_RESET;
                        return (1);
                }