]> git.baikalelectronics.ru Git - kernel.git/commit
frv: kill used but uninitialized variable
authorGeert Uytterhoeven <geert@linux-m68k.org>
Fri, 5 Oct 2012 00:12:16 +0000 (17:12 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 5 Oct 2012 18:04:46 +0000 (03:04 +0900)
commit5017d1385f675c74d74613f7b7dc826740097992
treedb6989ffd6d68cf25ae3e1e87b941776055cd057
parent4195102eb1ac65bed474680ef9046a4da0f6702a
frv: kill used but uninitialized variable

Commit aa451ec2e64a ("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>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
arch/frv/kernel/pm.c