]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
arm: zynq: Fix types in ps7_spl_init
authorMichal Simek <michal.simek@xilinx.com>
Fri, 12 Jan 2018 13:24:50 +0000 (14:24 +0100)
committerMichal Simek <michal.simek@xilinx.com>
Tue, 30 Jan 2018 13:28:31 +0000 (14:28 +0100)
The patch is fixing the following Warning:
arch/arm/mach-zynq/ps7_spl_init.c:133:24: warning: comparison between
signed and unsigned integer expressions [-Wsign-compare]
    while (ioread(addr) < delay)
                        ^

Signed-off-by: Michal Simek <michal.simek@xilinx.com>
arch/arm/mach-zynq/ps7_spl_init.c

index 6dc4e0364d8b25f38dfb7ba3097d80e50e542233..ba2dad759ca8e08041cb1e4e5e92443bb0b77a3f 100644 (file)
@@ -58,7 +58,7 @@ static void perf_start_clock(void)
 }
 
 /* Compute mask for given delay in miliseconds*/
-static int get_number_of_cycles_for_delay(unsigned int delay)
+static unsigned long get_number_of_cycles_for_delay(unsigned long delay)
 {
        return (APU_FREQ / (2 * 1000)) * delay;
 }
@@ -92,7 +92,7 @@ int __weak ps7_config(unsigned long *ps7_config_init)
        unsigned long mask;
        unsigned int numargs;
        int i;
-       int delay;
+       unsigned long delay;
 
        for (;;) {
                opcode = ptr[0];