s390x: pv: Fix KVM_PV_PREP_RESET command wrapper name
PATCH 1/1 s390x: pv: Fix KVM_PV_PREP_RESET command wrapper name
s390_pv_perf_clear_reset() is not a very helpful name since that function needs to be called for a normal and a clear reset via diag308.
Let's instead name it s390_pv_prep_reset() which reflects the purpose of the function a bit better.
--- hw/s390x/pv.c | 2 +- hw/s390x/s390-virtio-ccw.c | 2 +- include/hw/s390x/pv.h | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-)
hw/s390x/pv.c +1 -1
@@ -88,7 +88,7 @@ int s390_pv_unpack(uint64_t addr, uint64_t size, uint64_t tweak)return s390_pv_cmd (KVM_PV_UNPACK , &args); } -void s390_pv_perf_clear_reset (void ) +void s390_pv_prep_reset (void ) {s390_pv_cmd_exit (KVM_PV_PREP_RESET ,NULL ); }
hw/s390x/s390-virtio-ccw.c +1 -1
@@ -401,7 +401,7 @@ static void s390_pv_prepare_reset(S390CcwMachineState *ms)s390_cpu_set_state (S390_CPU_STATE_STOPPED ,S390_CPU (cs)); }s390_pv_unshare (); -s390_pv_perf_clear_reset (); +s390_pv_prep_reset (); }static void s390_machine_reset (MachineState *machine)
include/hw/s390x/pv.h +2 -2
@@ -39,7 +39,7 @@ int s390_pv_vm_enable(void);void s390_pv_vm_disable (void );int s390_pv_set_sec_parms (uint64_t origin,uint64_t length);int s390_pv_unpack (uint64_t addr,uint64_t size,uint64_t tweak); -void s390_pv_perf_clear_reset (void ); +void s390_pv_prep_reset (void );int s390_pv_verify (void );void s390_pv_unshare (void );void s390_pv_inject_reset_error (CPUState *cs);
@@ -49,7 +49,7 @@ static inline int s390_pv_vm_enable(void) { return 0; }static inline void s390_pv_vm_disable (void ) {}static inline int s390_pv_set_sec_parms (uint64_t origin,uint64_t length) {return 0 ; }static inline int s390_pv_unpack (uint64_t addr,uint64_t size,uint64_t tweak) {return 0 ; } -static inline void s390_pv_perf_clear_reset (void ) {} +static inline void s390_pv_prep_reset (void ) {}static inline int s390_pv_verify (void ) {return 0 ; }static inline void s390_pv_unshare (void ) {}static inline void s390_pv_inject_reset_error (CPUState *cs) {};
Signature · 1 line
2.25.1
Quoted 55 lines · Janosch Frank
s390_pv_perf_clear_reset()is not a very helpful name since that function needs to be called for a normal and a clear reset via diag308.Let's instead name it
s390_pv_prep_reset()which reflects the purpose of the function a bit better.Signed-off-by Janosch Frank <[email protected]>--- hw/s390x/pv.c | 2 +- hw/s390x/s390-virtio-ccw.c | 2 +- include/hw/s390x/pv.h | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-)hw/s390x/pv.c +1
-1@@ -88,7 +88,7 @@ int s390_pv_unpack(uint64_t addr, uint64_t size, uint64_t tweak)return s390_pv_cmd (KVM_PV_UNPACK , &args); } -void s390_pv_perf_clear_reset (void ) +void s390_pv_prep_reset (void ) {s390_pv_cmd_exit (KVM_PV_PREP_RESET ,NULL ); }hw/s390x/s390-virtio-ccw.c +1
-1@@ -401,7 +401,7 @@ static void s390_pv_prepare_reset(S390CcwMachineState *ms)s390_cpu_set_state (S390_CPU_STATE_STOPPED ,S390_CPU (cs)); }s390_pv_unshare (); -s390_pv_perf_clear_reset (); +s390_pv_prep_reset (); }static void s390_machine_reset (MachineState *machine)include/hw/s390x/pv.h +1
-1@@ -39,7 +39,7 @@ int s390_pv_vm_enable(void);void s390_pv_vm_disable (void );int s390_pv_set_sec_parms (uint64_t origin,uint64_t length);int s390_pv_unpack (uint64_t addr,uint64_t size,uint64_t tweak); -void s390_pv_perf_clear_reset (void ); +void s390_pv_prep_reset (void );int s390_pv_verify (void );void s390_pv_unshare (void );void s390_pv_inject_reset_error (CPUState *cs);
include/hw/s390x/pv.h static inline int s390_pv_vm_enable(void) { return 0; } · line 55
Quoted 8 lines
include/hw/s390x/pv.h +1
-1@@ -49,7 +49,7 @@ static inline int s390_pv_vm_enable(void) { return 0; }static inline void s390_pv_vm_disable (void ) {}static inline int s390_pv_set_sec_parms (uint64_t origin,uint64_t length) {return 0 ; }static inline int s390_pv_unpack (uint64_t addr,uint64_t size,uint64_t tweak) {return 0 ; } -static inline void s390_pv_perf_clear_reset (void ) {} +static inline void s390_pv_prep_reset (void ) {}static inline int s390_pv_verify (void ) {return 0 ; }static inline void s390_pv_unshare (void ) {}static inline void s390_pv_inject_reset_error (CPUState *cs) {};
Signature · 3 lines
Thanks, David / dhildenb
Cornelia Huck
AppliedQuoted 7 lines · On Tue, 5 May 2020 08:41:59 -0400 Janosch Frank <[email protected]> wrote:
s390_pv_perf_clear_reset()is not a very helpful name since that function needs to be called for a normal and a clear reset via diag308.Let's instead name it
s390_pv_prep_reset()which reflects the purpose of the function a bit better.
Quoted 6 lines
Signed-off-by Janosch Frank <[email protected]>--- hw/s390x/pv.c | 2 +- hw/s390x/s390-virtio-ccw.c | 2 +- include/hw/s390x/pv.h | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-)
Thanks, applied.