[U-Boot] [PATCH] arm: exynos: Squash bogus warnings in pinmux
Rajeshwari Birje
rajeshwari.birje at gmail.com
Tue Mar 11 08:38:58 CET 2014
Hi
Acked-by: Rajeshwari S Shinde <rajeshwari.s at samsung.com>
Regards,
Rajeshwari
On Tue, Mar 11, 2014 at 12:56 AM, Simon Glass <sjg at chromium.org> wrote:
> Hi Marek,
>
> On 10 March 2014 13:04, Marek Vasut <marex at denx.de> wrote:
>> Squash these warnings in pinmux.c found with GCC 4.8:
>>
>> /arch/arm/cpu/armv7/exynos/pinmux.c: In function 'exynos_pinmux_config':
>> /arch/arm/cpu/armv7/exynos/pinmux.c:687:28: warning: 'count' may be used uninitialized in this function [-Wmaybe-uninitialized]
>> for (i = start; i < start + count; i++) {
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:663:16: note: 'count' was declared here
>> int i, start, count;
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:687:28: warning: 'start' may be used uninitialized in this function [-Wmaybe-uninitialized]
>> for (i = start; i < start + count; i++) {
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:663:9: note: 'start' was declared here
>> int i, start, count;
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:689:19: warning: 'bank' may be used uninitialized in this function [-Wmaybe-uninitialized]
>> s5p_gpio_cfg_pin(bank, i, GPIO_FUNC(0x2));
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:662:24: note: 'bank' was declared here
>> struct s5p_gpio_bank *bank;
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c: In function 'exynos_pinmux_config':
>> /arch/arm/cpu/armv7/exynos/pinmux.c:687:28: warning: 'count' may be used uninitialized in this function [-Wmaybe-uninitialized]
>> for (i = start; i < start + count; i++) {
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:663:16: note: 'count' was declared here
>> int i, start, count;
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:687:28: warning: 'start' may be used uninitialized in this function [-Wmaybe-uninitialized]
>> for (i = start; i < start + count; i++) {
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:663:9: note: 'start' was declared here
>> int i, start, count;
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:689:19: warning: 'bank' may be used uninitialized in this function [-Wmaybe-uninitialized]
>> s5p_gpio_cfg_pin(bank, i, GPIO_FUNC(0x2));
>> ^
>> /arch/arm/cpu/armv7/exynos/pinmux.c:662:24: note: 'bank' was declared here
>> struct s5p_gpio_bank *bank;
>> ^
>>
>> Note that the warning is bogus, the function can never be called with invalid
>> 'peripheral' argument. GCC just cannot analyze this.
>>
>> Signed-off-by: Marek Vasut <marex at denx.de>
>> Cc: Naveen Krishna Chatradhi <ch.naveen at samsung.com>
>> Cc: Akshay Saraswat <akshay.s at samsung.com>
>> Cc: Rajeshwari S Shinde <rajeshwari.s at samsung.com>
>> Cc: Simon Glass <sjg at chromium.org>
>> Cc: Minkyu Kang <mk7.kang at samsung.com>
>> Cc: Tom Rini <trini at ti.com>
>
> Acked-by: Simon Glass <sjg at chromium.org>
>
> Thanks Marek, great to get that annoyance fixed.
>
> Regards,
> Simon
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> http://lists.denx.de/mailman/listinfo/u-boot
--
Regards,
Rajeshwari Shinde
More information about the U-Boot
mailing list