]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
ARM: MXS: fix Uninitialized variable error
authorWolfgang Denk <wd@denx.de>
Thu, 6 Nov 2014 13:03:04 +0000 (14:03 +0100)
committerTom Rini <trini@ti.com>
Mon, 10 Nov 2014 21:25:27 +0000 (16:25 -0500)
cppcheck reports:

[arch/arm/cpu/arm926ejs/mxs/timer.c:96]: (error) Uninitialized
variable: now

Signed-off-by: Wolfgang Denk <wd@denx.de>
Cc: Marek Vasut <marex@denx.de>
Cc: Stefano Babic <sbabic@denx.de>
arch/arm/cpu/arm926ejs/mxs/timer.c

index 99d3fb8731f3e0b9d2ac6589ae60b3a3086115b0..f2e72257d15b5d77fb7d583152f2b19b1f32a95f 100644 (file)
@@ -91,6 +91,8 @@ unsigned long long get_ticks(void)
                TIMROT_RUNNING_COUNTn_RUNNING_COUNT_OFFSET;
 #elif defined(CONFIG_MX28)
        now = readl(&timrot_regs->hw_timrot_running_count0);
+#else
+#error "Don't know how to read timrot_regs"
 #endif
 
        if (lastdec >= now) {