mtd: denali: change the type of iterators to int
authorMasahiro Yamada <yamada.m@jp.panasonic.com>
Tue, 9 Sep 2014 02:01:54 +0000 (11:01 +0900)
committerBrian Norris <computersforpeace@gmail.com>
Mon, 15 Sep 2014 23:31:19 +0000 (16:31 -0700)
We should rathar use "int" type for loop iterators.

Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com>
Signed-off-by: Brian Norris <computersforpeace@gmail.com>
drivers/mtd/nand/denali.c

index 60134394bae4ea2f197554b91fe8073e2905b686..4cb1497fe1c08bebf450ec2a87565fd7a43a70fe 100644 (file)
@@ -178,7 +178,7 @@ static void reset_bank(struct denali_nand_info *denali)
 /* Reset the flash controller */
 static uint16_t denali_nand_reset(struct denali_nand_info *denali)
 {
-       uint32_t i;
+       int i;
 
        dev_dbg(denali->dev, "%s, Line %d, Function: %s\n",
                       __FILE__, __LINE__, __func__);
@@ -499,7 +499,8 @@ static uint16_t denali_nand_timing_set(struct denali_nand_info *denali)
 {
        uint16_t status = PASS;
        uint32_t id_bytes[8], addr;
-       uint8_t i, maf_id, device_id;
+       uint8_t maf_id, device_id;
+       int i;
 
        dev_dbg(denali->dev,
                        "%s, Line %d, Function: %s\n",
@@ -830,7 +831,8 @@ static int write_data_to_flash_mem(struct denali_nand_info *denali,
                                                        const uint8_t *buf,
                                                        int len)
 {
-       uint32_t i, *buf32;
+       uint32_t *buf32;
+       int i;
 
        /*
         * verify that the len is a multiple of 4.
@@ -850,7 +852,8 @@ static int read_data_from_flash_mem(struct denali_nand_info *denali,
                                                                uint8_t *buf,
                                                                int len)
 {
-       uint32_t i, *buf32;
+       uint32_t *buf32;
+       int i;
 
        /*
         * we assume that len will be a multiple of 4, if not it would be nice