* [PATCH] target/ppc: Clean up local variable shadowing in kvm_arch_*_registers()
@ 2023-10-06 5:35 Cédric Le Goater
2023-10-06 9:55 ` Thomas Huth
2023-10-06 10:45 ` Markus Armbruster
0 siblings, 2 replies; 3+ messages in thread
From: Cédric Le Goater @ 2023-10-06 5:35 UTC (permalink / raw)
To: qemu-ppc, qemu-devel
Cc: Daniel Henrique Barboza, Nicholas Piggin, Markus Armbruster,
Cédric Le Goater
Remove extra 'i' variable to fix this warning :
../target/ppc/kvm.c: In function ‘kvm_arch_put_registers’:
../target/ppc/kvm.c:963:13: warning: declaration of ‘i’ shadows a previous local [-Wshadow=compatible-local]
963 | int i;
| ^
../target/ppc/kvm.c:906:9: note: shadowed declaration is here
906 | int i;
| ^
../target/ppc/kvm.c: In function ‘kvm_arch_get_registers’:
../target/ppc/kvm.c:1265:13: warning: declaration of ‘i’ shadows a previous local [-Wshadow=compatible-local]
1265 | int i;
| ^
../target/ppc/kvm.c:1212:9: note: shadowed declaration is here
1212 | int i, ret;
| ^
Signed-off-by: Cédric Le Goater <clg@kaod.org>
---
target/ppc/kvm.c | 4 ----
1 file changed, 4 deletions(-)
diff --git a/target/ppc/kvm.c b/target/ppc/kvm.c
index 51112bd3670d..d0e2dcdc7734 100644
--- a/target/ppc/kvm.c
+++ b/target/ppc/kvm.c
@@ -960,8 +960,6 @@ int kvm_arch_put_registers(CPUState *cs, int level)
}
if (cap_one_reg) {
- int i;
-
/*
* We deliberately ignore errors here, for kernels which have
* the ONE_REG calls, but don't support the specific
@@ -1262,8 +1260,6 @@ int kvm_arch_get_registers(CPUState *cs)
}
if (cap_one_reg) {
- int i;
-
/*
* We deliberately ignore errors here, for kernels which have
* the ONE_REG calls, but don't support the specific
--
2.41.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] target/ppc: Clean up local variable shadowing in kvm_arch_*_registers()
2023-10-06 5:35 [PATCH] target/ppc: Clean up local variable shadowing in kvm_arch_*_registers() Cédric Le Goater
@ 2023-10-06 9:55 ` Thomas Huth
2023-10-06 10:45 ` Markus Armbruster
1 sibling, 0 replies; 3+ messages in thread
From: Thomas Huth @ 2023-10-06 9:55 UTC (permalink / raw)
To: Cédric Le Goater, qemu-ppc, qemu-devel
Cc: Daniel Henrique Barboza, Nicholas Piggin, Markus Armbruster
On 06/10/2023 07.35, Cédric Le Goater wrote:
> Remove extra 'i' variable to fix this warning :
>
> ../target/ppc/kvm.c: In function ‘kvm_arch_put_registers’:
> ../target/ppc/kvm.c:963:13: warning: declaration of ‘i’ shadows a previous local [-Wshadow=compatible-local]
> 963 | int i;
> | ^
> ../target/ppc/kvm.c:906:9: note: shadowed declaration is here
> 906 | int i;
> | ^
> ../target/ppc/kvm.c: In function ‘kvm_arch_get_registers’:
> ../target/ppc/kvm.c:1265:13: warning: declaration of ‘i’ shadows a previous local [-Wshadow=compatible-local]
> 1265 | int i;
> | ^
> ../target/ppc/kvm.c:1212:9: note: shadowed declaration is here
> 1212 | int i, ret;
> | ^
>
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
> ---
> target/ppc/kvm.c | 4 ----
> 1 file changed, 4 deletions(-)
Reviewed-by: Thomas Huth <thuth@redhat.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] target/ppc: Clean up local variable shadowing in kvm_arch_*_registers()
2023-10-06 5:35 [PATCH] target/ppc: Clean up local variable shadowing in kvm_arch_*_registers() Cédric Le Goater
2023-10-06 9:55 ` Thomas Huth
@ 2023-10-06 10:45 ` Markus Armbruster
1 sibling, 0 replies; 3+ messages in thread
From: Markus Armbruster @ 2023-10-06 10:45 UTC (permalink / raw)
To: Cédric Le Goater
Cc: qemu-ppc, qemu-devel, Daniel Henrique Barboza, Nicholas Piggin
Cédric Le Goater <clg@kaod.org> writes:
> Remove extra 'i' variable to fix this warning :
>
> ../target/ppc/kvm.c: In function ‘kvm_arch_put_registers’:
> ../target/ppc/kvm.c:963:13: warning: declaration of ‘i’ shadows a previous local [-Wshadow=compatible-local]
> 963 | int i;
> | ^
> ../target/ppc/kvm.c:906:9: note: shadowed declaration is here
> 906 | int i;
> | ^
> ../target/ppc/kvm.c: In function ‘kvm_arch_get_registers’:
> ../target/ppc/kvm.c:1265:13: warning: declaration of ‘i’ shadows a previous local [-Wshadow=compatible-local]
> 1265 | int i;
> | ^
> ../target/ppc/kvm.c:1212:9: note: shadowed declaration is here
> 1212 | int i, ret;
> | ^
>
> Signed-off-by: Cédric Le Goater <clg@kaod.org>
Queued, thanks!
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2023-10-06 10:46 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-10-06 5:35 [PATCH] target/ppc: Clean up local variable shadowing in kvm_arch_*_registers() Cédric Le Goater
2023-10-06 9:55 ` Thomas Huth
2023-10-06 10:45 ` Markus Armbruster
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).