summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHuang Ying <ying.huang@intel.com>2008-08-15 09:40:20 +0200
committerLinus Torvalds <torvalds@linux-foundation.org>2008-08-15 17:35:42 +0200
commit4cd69b986ebf0f8da93f82ffbb89c032ee09c2e1 (patch)
treecb4085d0b8f18e86b892c5bd88a5d6280c698300
parentsuspend: fix section mismatch warning - register_nosave_region (diff)
downloadlinux-4cd69b986ebf0f8da93f82ffbb89c032ee09c2e1.tar.xz
linux-4cd69b986ebf0f8da93f82ffbb89c032ee09c2e1.zip
kexec: fix compilation warning on xchg(&kexec_lock, 0) in kernel_kexec()
kernel/kexec.c: In function 'kernel_kexec': kernel/kexec.c:1506: warning: value computed is not used Signed-off-by: Huang Ying <ying.huang@intel.com> Cc: "Eric W. Biederman" <ebiederm@xmission.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
-rw-r--r--kernel/kexec.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/kernel/kexec.c b/kernel/kexec.c
index c8a4370e2a34..cf3797b76786 100644
--- a/kernel/kexec.c
+++ b/kernel/kexec.c
@@ -1503,7 +1503,8 @@ int kernel_kexec(void)
}
Unlock:
- xchg(&kexec_lock, 0);
+ if (!xchg(&kexec_lock, 0))
+ BUG();
return error;
}