[U-Boot] [PATCH V2 1/7] mips: ath79: ar933x: Avoid warning with gcc5

GCC 5.3 report a warning: 'upper' and 'lower' may be used uninitialized in this function [-Wmaybe-uninitialized]. Compiler might need explicit initializer.
Signed-off-by: Wills Wang wills.wang@live.com ---
arch/mips/mach-ath79/ar933x/ddr.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/arch/mips/mach-ath79/ar933x/ddr.c b/arch/mips/mach-ath79/ar933x/ddr.c index 91452bc..7f20d34 100644 --- a/arch/mips/mach-ath79/ar933x/ddr.c +++ b/arch/mips/mach-ath79/ar933x/ddr.c @@ -268,6 +268,8 @@ void ddr_tap_tuning(void) dir = 1; tap = readl(regs + AR71XX_DDR_REG_TAP_CTRL0); val = tap; + upper = tap; + lower = tap; while (!done) { err = 0;

On 05/22/2016 05:59 AM, Wills Wang wrote:
GCC 5.3 report a warning: 'upper' and 'lower' may be used uninitialized in this function [-Wmaybe-uninitialized]. Compiler might need explicit initializer.
Signed-off-by: Wills Wang wills.wang@live.com
arch/mips/mach-ath79/ar933x/ddr.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/arch/mips/mach-ath79/ar933x/ddr.c b/arch/mips/mach-ath79/ar933x/ddr.c index 91452bc..7f20d34 100644 --- a/arch/mips/mach-ath79/ar933x/ddr.c +++ b/arch/mips/mach-ath79/ar933x/ddr.c @@ -268,6 +268,8 @@ void ddr_tap_tuning(void) dir = 1; tap = readl(regs + AR71XX_DDR_REG_TAP_CTRL0); val = tap;
- upper = tap;
- lower = tap; while (!done) { err = 0;
So what's new in V2 here ?

On 05/22/2016 07:15 PM, Marek Vasut wrote:
On 05/22/2016 05:59 AM, Wills Wang wrote:
GCC 5.3 report a warning: 'upper' and 'lower' may be used uninitialized in this function [-Wmaybe-uninitialized]. Compiler might need explicit initializer.
Signed-off-by: Wills Wang wills.wang@live.com
arch/mips/mach-ath79/ar933x/ddr.c | 2 ++ 1 file changed, 2 insertions(+)
diff --git a/arch/mips/mach-ath79/ar933x/ddr.c b/arch/mips/mach-ath79/ar933x/ddr.c index 91452bc..7f20d34 100644 --- a/arch/mips/mach-ath79/ar933x/ddr.c +++ b/arch/mips/mach-ath79/ar933x/ddr.c @@ -268,6 +268,8 @@ void ddr_tap_tuning(void) dir = 1; tap = readl(regs + AR71XX_DDR_REG_TAP_CTRL0); val = tap;
- upper = tap;
- lower = tap; while (!done) { err = 0;
So what's new in V2 here ?
Capitalize the first letter in the sentence.

Am 22.05.2016 um 05:59 schrieb Wills Wang:
GCC 5.3 report a warning: 'upper' and 'lower' may be used uninitialized in this function [-Wmaybe-uninitialized]. Compiler might need explicit initializer.
Signed-off-by: Wills Wang wills.wang@live.com
arch/mips/mach-ath79/ar933x/ddr.c | 2 ++ 1 file changed, 2 insertions(+)
applied to u-boot-mips, thanks.
participants (3)
-
Daniel Schwierzeck
-
Marek Vasut
-
Wills Wang