* [PATCH] powerpc/mce: Remove unused but set variable
@ 2016-11-17 16:19 Tobias Klauser
2016-11-22 0:34 ` Michael Ellerman
0 siblings, 1 reply; 2+ messages in thread
From: Tobias Klauser @ 2016-11-17 16:19 UTC (permalink / raw)
To: linuxppc-dev
Remove the unused but set variable srr1 in save_mce_event() to
fix the following GCC warning when building with 'W=1':
arch/powerpc/kernel/mce.c:75:11: warning: variable 'srr1' set but not used [-Wunused-but-set-variable]
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
---
arch/powerpc/kernel/mce.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/arch/powerpc/kernel/mce.c b/arch/powerpc/kernel/mce.c
index 5e7ece0fda9f..c6923ff45131 100644
--- a/arch/powerpc/kernel/mce.c
+++ b/arch/powerpc/kernel/mce.c
@@ -72,7 +72,6 @@ void save_mce_event(struct pt_regs *regs, long handled,
struct mce_error_info *mce_err,
uint64_t nip, uint64_t addr)
{
- uint64_t srr1;
int index = __this_cpu_inc_return(mce_nest_count) - 1;
struct machine_check_event *mce = this_cpu_ptr(&mce_event[index]);
@@ -99,8 +98,6 @@ void save_mce_event(struct pt_regs *regs, long handled,
mce->disposition = MCE_DISPOSITION_NOT_RECOVERED;
mce->severity = MCE_SEV_ERROR_SYNC;
- srr1 = regs->msr;
-
/*
* Populate the mce error_type and type-specific error_type.
*/
--
2.11.0.rc0.7.gbe5a750
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: powerpc/mce: Remove unused but set variable
2016-11-17 16:19 [PATCH] powerpc/mce: Remove unused but set variable Tobias Klauser
@ 2016-11-22 0:34 ` Michael Ellerman
0 siblings, 0 replies; 2+ messages in thread
From: Michael Ellerman @ 2016-11-22 0:34 UTC (permalink / raw)
To: Tobias Klauser, linuxppc-dev
On Thu, 2016-11-17 at 16:19:21 UTC, Tobias Klauser wrote:
> Remove the unused but set variable srr1 in save_mce_event() to
> fix the following GCC warning when building with 'W=1':
>
> arch/powerpc/kernel/mce.c:75:11: warning: variable 'srr1' set but not used [-Wunused-but-set-variable]
>
> Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Applied to powerpc next, thanks.
https://git.kernel.org/powerpc/c/d6d56ec738dcac4ac7716ccb7a08a4
cheers
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-11-22 0:34 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-11-17 16:19 [PATCH] powerpc/mce: Remove unused but set variable Tobias Klauser
2016-11-22 0:34 ` Michael Ellerman
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.