]> git.karo-electronics.de Git - karo-tx-linux.git/commit
frv: kill used but uninitialized variable
authorGeert Uytterhoeven <geert@linux-m68k.org>
Tue, 14 Aug 2012 03:22:38 +0000 (13:22 +1000)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 22 Aug 2012 06:01:32 +0000 (16:01 +1000)
commit1cf2e3ac8780d705bd79ad602aa574ab426bc793
treec7d8adfe1241a1f98a275a895887257b12d99597
parent8ec49338d511031618f87412b2c19d2f65cde6ed
frv: kill used but uninitialized variable

Commit 6afe1a1fe8ff83f6a ("PM: Remove legacy PM") removed the
initialization of retval, causing:

arch/frv/kernel/pm.c: In function 'sysctl_pm_do_suspend':
arch/frv/kernel/pm.c:165:5: warning: 'retval' may be used uninitialized in this function [-Wuninitialized]

Remove the variable completely to fix this, and convert to a proper
switch (...) { ... } construct to improve readability.

Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: David Howells <dhowells@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/frv/kernel/pm.c