s390x/kvm: help valgrind in several places
PATCH v2 1/1 s390x/kvm: help valgrind in several places
We need some little help in the code to reduce the valgrind noise. This patch does this with some designated initializers for the cpu model features and subfunctions.
Reviewed-by Philippe Mathieu-Daudé <[email protected]>
Signed-off-by Christian Borntraeger <[email protected]>
--- target/s390x/kvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
target/s390x/kvm.c +2 -2
@@ -2165,7 +2165,7 @@ int kvm_arch_msi_data_to_gsi(uint32_t data)static int query_cpu_subfunc (S390FeatBitmap features) { -struct kvm_s390_vm_cpu_subfunc prop; +struct kvm_s390_vm_cpu_subfunc prop = {};struct kvm_device_attr attr = { .group =KVM_S390_VM_CPU_MODEL , .attr =KVM_S390_VM_CPU_MACHINE_SUBFUNC ,
@@ -2292,7 +2292,7 @@ static int kvm_to_feat[][2] = {static int query_cpu_feat (S390FeatBitmap features) { -struct kvm_s390_vm_cpu_feat prop; +struct kvm_s390_vm_cpu_feat prop = {};struct kvm_device_attr attr = { .group =KVM_S390_VM_CPU_MODEL , .attr =KVM_S390_VM_CPU_MACHINE_FEAT ,
Signature · 1 line
2.25.1
Quoted 25 lines · Christian Borntraeger
We need some little help in the code to reduce the valgrind noise. This patch does this with some designated initializers for the cpu model features and subfunctions.
Reviewed-by Philippe Mathieu-Daudé <[email protected]>Signed-off-by Christian Borntraeger <[email protected]>--- target/s390x/kvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)target/s390x/kvm.c +1
-1@@ -2165,7 +2165,7 @@ int kvm_arch_msi_data_to_gsi(uint32_t data)static int query_cpu_subfunc (S390FeatBitmap features) { -struct kvm_s390_vm_cpu_subfunc prop; +struct kvm_s390_vm_cpu_subfunc prop = {};struct kvm_device_attr attr = { .group =KVM_S390_VM_CPU_MODEL , .attr =KVM_S390_VM_CPU_MACHINE_SUBFUNC ,
target/s390x/kvm.c static int kvm_to_feat[][2] = { · line 2298
Quoted 8 lines
target/s390x/kvm.c +1
-1@@ -2292,7 +2292,7 @@ static int kvm_to_feat[][2] = {static int query_cpu_feat (S390FeatBitmap features) { -struct kvm_s390_vm_cpu_feat prop; +struct kvm_s390_vm_cpu_feat prop = {};struct kvm_device_attr attr = { .group =KVM_S390_VM_CPU_MODEL , .attr =KVM_S390_VM_CPU_MACHINE_FEAT ,
Reviewed-by David Hildenbrand <[email protected]>
Signature · 3 lines
Thanks, David / dhildenb
Cornelia Huck
AppliedQuoted 9 lines · On Wed, 29 Apr 2020 03:42:01 -0400 Christian Borntraeger…
We need some little help in the code to reduce the valgrind noise. This patch does this with some designated initializers for the cpu model features and subfunctions.
Reviewed-by Philippe Mathieu-Daudé <[email protected]>Signed-off-by Christian Borntraeger <[email protected]>--- target/s390x/kvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
Thanks, applied.