* [PATCH] s390x/kvm: remove unused gs handling
@ 2021-06-02 12:50 Cornelia Huck
2021-06-02 13:07 ` Thomas Huth
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: Cornelia Huck @ 2021-06-02 12:50 UTC (permalink / raw)
To: Halil Pasic, Christian Borntraeger, Thomas Huth
Cc: qemu-s390x, Cornelia Huck, qemu-devel
With commit 0280b3eb7c05 ("s390x/kvm: use cpu model for gscb on
compat machines"), we removed any calls to kvm_s390_get_gs()
in favour of a different mechanism.
Let's remove the unused kvm_s390_get_gs(), and with it the now
unneeded cap_gs as well.
Signed-off-by: Cornelia Huck <cohuck@redhat.com>
---
target/s390x/kvm-stub.c | 5 -----
target/s390x/kvm.c | 10 +---------
target/s390x/kvm_s390x.h | 1 -
3 files changed, 1 insertion(+), 15 deletions(-)
diff --git a/target/s390x/kvm-stub.c b/target/s390x/kvm-stub.c
index 9970b5a8c705..8a308cfebb68 100644
--- a/target/s390x/kvm-stub.c
+++ b/target/s390x/kvm-stub.c
@@ -49,11 +49,6 @@ int kvm_s390_get_ri(void)
return 0;
}
-int kvm_s390_get_gs(void)
-{
- return 0;
-}
-
int kvm_s390_get_clock(uint8_t *tod_high, uint64_t *tod_low)
{
return -ENOSYS;
diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c
index 4fb3bbfef506..23889245877a 100644
--- a/target/s390x/kvm.c
+++ b/target/s390x/kvm.c
@@ -154,7 +154,6 @@ static int cap_async_pf;
static int cap_mem_op;
static int cap_s390_irq;
static int cap_ri;
-static int cap_gs;
static int cap_hpage_1m;
static int cap_vcpu_resets;
static int cap_protected;
@@ -369,9 +368,7 @@ int kvm_arch_init(MachineState *ms, KVMState *s)
}
}
if (cpu_model_allowed()) {
- if (kvm_vm_enable_cap(s, KVM_CAP_S390_GS, 0) == 0) {
- cap_gs = 1;
- }
+ kvm_vm_enable_cap(s, KVM_CAP_S390_GS, 0);
}
/*
@@ -2039,11 +2036,6 @@ int kvm_s390_get_ri(void)
return cap_ri;
}
-int kvm_s390_get_gs(void)
-{
- return cap_gs;
-}
-
int kvm_s390_set_cpu_state(S390CPU *cpu, uint8_t cpu_state)
{
struct kvm_mp_state mp_state = {};
diff --git a/target/s390x/kvm_s390x.h b/target/s390x/kvm_s390x.h
index 25bbe98b2514..05a5e1e6f46d 100644
--- a/target/s390x/kvm_s390x.h
+++ b/target/s390x/kvm_s390x.h
@@ -27,7 +27,6 @@ void kvm_s390_vcpu_interrupt_pre_save(S390CPU *cpu);
int kvm_s390_vcpu_interrupt_post_load(S390CPU *cpu);
int kvm_s390_get_hpage_1m(void);
int kvm_s390_get_ri(void);
-int kvm_s390_get_gs(void);
int kvm_s390_get_clock(uint8_t *tod_high, uint64_t *tod_clock);
int kvm_s390_get_clock_ext(uint8_t *tod_high, uint64_t *tod_clock);
int kvm_s390_set_clock(uint8_t tod_high, uint64_t tod_clock);
--
2.31.1
^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH] s390x/kvm: remove unused gs handling
2021-06-02 12:50 [PATCH] s390x/kvm: remove unused gs handling Cornelia Huck
@ 2021-06-02 13:07 ` Thomas Huth
2021-06-02 15:13 ` Philippe Mathieu-Daudé
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: Thomas Huth @ 2021-06-02 13:07 UTC (permalink / raw)
To: Cornelia Huck, Halil Pasic, Christian Borntraeger; +Cc: qemu-s390x, qemu-devel
On 02/06/2021 14.50, Cornelia Huck wrote:
> With commit 0280b3eb7c05 ("s390x/kvm: use cpu model for gscb on
> compat machines"), we removed any calls to kvm_s390_get_gs()
> in favour of a different mechanism.
>
> Let's remove the unused kvm_s390_get_gs(), and with it the now
> unneeded cap_gs as well.
>
> Signed-off-by: Cornelia Huck <cohuck@redhat.com>
> ---
> target/s390x/kvm-stub.c | 5 -----
> target/s390x/kvm.c | 10 +---------
> target/s390x/kvm_s390x.h | 1 -
> 3 files changed, 1 insertion(+), 15 deletions(-)
Reviewed-by: Thomas Huth <thuth@redhat.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] s390x/kvm: remove unused gs handling
2021-06-02 12:50 [PATCH] s390x/kvm: remove unused gs handling Cornelia Huck
2021-06-02 13:07 ` Thomas Huth
@ 2021-06-02 15:13 ` Philippe Mathieu-Daudé
2021-06-07 8:11 ` Christian Borntraeger
2021-06-08 7:40 ` Cornelia Huck
3 siblings, 0 replies; 5+ messages in thread
From: Philippe Mathieu-Daudé @ 2021-06-02 15:13 UTC (permalink / raw)
To: Cornelia Huck, Halil Pasic, Christian Borntraeger, Thomas Huth
Cc: qemu-s390x, qemu-devel
On 6/2/21 2:50 PM, Cornelia Huck wrote:
> With commit 0280b3eb7c05 ("s390x/kvm: use cpu model for gscb on
> compat machines"), we removed any calls to kvm_s390_get_gs()
> in favour of a different mechanism.
>
> Let's remove the unused kvm_s390_get_gs(), and with it the now
> unneeded cap_gs as well.
>
> Signed-off-by: Cornelia Huck <cohuck@redhat.com>
> ---
> target/s390x/kvm-stub.c | 5 -----
> target/s390x/kvm.c | 10 +---------
> target/s390x/kvm_s390x.h | 1 -
> 3 files changed, 1 insertion(+), 15 deletions(-)
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] s390x/kvm: remove unused gs handling
2021-06-02 12:50 [PATCH] s390x/kvm: remove unused gs handling Cornelia Huck
2021-06-02 13:07 ` Thomas Huth
2021-06-02 15:13 ` Philippe Mathieu-Daudé
@ 2021-06-07 8:11 ` Christian Borntraeger
2021-06-08 7:40 ` Cornelia Huck
3 siblings, 0 replies; 5+ messages in thread
From: Christian Borntraeger @ 2021-06-07 8:11 UTC (permalink / raw)
To: Cornelia Huck, Halil Pasic, Thomas Huth; +Cc: qemu-s390x, qemu-devel
On 02.06.21 14:50, Cornelia Huck wrote:
> With commit 0280b3eb7c05 ("s390x/kvm: use cpu model for gscb on
> compat machines"), we removed any calls to kvm_s390_get_gs()
> in favour of a different mechanism.
>
> Let's remove the unused kvm_s390_get_gs(), and with it the now
> unneeded cap_gs as well.
>
> Signed-off-by: Cornelia Huck <cohuck@redhat.com>
Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>
> ---
> target/s390x/kvm-stub.c | 5 -----
> target/s390x/kvm.c | 10 +---------
> target/s390x/kvm_s390x.h | 1 -
> 3 files changed, 1 insertion(+), 15 deletions(-)
>
> diff --git a/target/s390x/kvm-stub.c b/target/s390x/kvm-stub.c
> index 9970b5a8c705..8a308cfebb68 100644
> --- a/target/s390x/kvm-stub.c
> +++ b/target/s390x/kvm-stub.c
> @@ -49,11 +49,6 @@ int kvm_s390_get_ri(void)
> return 0;
> }
>
> -int kvm_s390_get_gs(void)
> -{
> - return 0;
> -}
> -
> int kvm_s390_get_clock(uint8_t *tod_high, uint64_t *tod_low)
> {
> return -ENOSYS;
> diff --git a/target/s390x/kvm.c b/target/s390x/kvm.c
> index 4fb3bbfef506..23889245877a 100644
> --- a/target/s390x/kvm.c
> +++ b/target/s390x/kvm.c
> @@ -154,7 +154,6 @@ static int cap_async_pf;
> static int cap_mem_op;
> static int cap_s390_irq;
> static int cap_ri;
> -static int cap_gs;
> static int cap_hpage_1m;
> static int cap_vcpu_resets;
> static int cap_protected;
> @@ -369,9 +368,7 @@ int kvm_arch_init(MachineState *ms, KVMState *s)
> }
> }
> if (cpu_model_allowed()) {
> - if (kvm_vm_enable_cap(s, KVM_CAP_S390_GS, 0) == 0) {
> - cap_gs = 1;
> - }
> + kvm_vm_enable_cap(s, KVM_CAP_S390_GS, 0);
> }
>
> /*
> @@ -2039,11 +2036,6 @@ int kvm_s390_get_ri(void)
> return cap_ri;
> }
>
> -int kvm_s390_get_gs(void)
> -{
> - return cap_gs;
> -}
> -
> int kvm_s390_set_cpu_state(S390CPU *cpu, uint8_t cpu_state)
> {
> struct kvm_mp_state mp_state = {};
> diff --git a/target/s390x/kvm_s390x.h b/target/s390x/kvm_s390x.h
> index 25bbe98b2514..05a5e1e6f46d 100644
> --- a/target/s390x/kvm_s390x.h
> +++ b/target/s390x/kvm_s390x.h
> @@ -27,7 +27,6 @@ void kvm_s390_vcpu_interrupt_pre_save(S390CPU *cpu);
> int kvm_s390_vcpu_interrupt_post_load(S390CPU *cpu);
> int kvm_s390_get_hpage_1m(void);
> int kvm_s390_get_ri(void);
> -int kvm_s390_get_gs(void);
> int kvm_s390_get_clock(uint8_t *tod_high, uint64_t *tod_clock);
> int kvm_s390_get_clock_ext(uint8_t *tod_high, uint64_t *tod_clock);
> int kvm_s390_set_clock(uint8_t tod_high, uint64_t tod_clock);
>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] s390x/kvm: remove unused gs handling
2021-06-02 12:50 [PATCH] s390x/kvm: remove unused gs handling Cornelia Huck
` (2 preceding siblings ...)
2021-06-07 8:11 ` Christian Borntraeger
@ 2021-06-08 7:40 ` Cornelia Huck
3 siblings, 0 replies; 5+ messages in thread
From: Cornelia Huck @ 2021-06-08 7:40 UTC (permalink / raw)
To: Halil Pasic, Christian Borntraeger, Thomas Huth; +Cc: qemu-s390x, qemu-devel
On Wed, Jun 02 2021, Cornelia Huck <cohuck@redhat.com> wrote:
> With commit 0280b3eb7c05 ("s390x/kvm: use cpu model for gscb on
> compat machines"), we removed any calls to kvm_s390_get_gs()
> in favour of a different mechanism.
>
> Let's remove the unused kvm_s390_get_gs(), and with it the now
> unneeded cap_gs as well.
>
> Signed-off-by: Cornelia Huck <cohuck@redhat.com>
> ---
> target/s390x/kvm-stub.c | 5 -----
> target/s390x/kvm.c | 10 +---------
> target/s390x/kvm_s390x.h | 1 -
> 3 files changed, 1 insertion(+), 15 deletions(-)
Queued to s390-next.
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2021-06-08 7:41 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-06-02 12:50 [PATCH] s390x/kvm: remove unused gs handling Cornelia Huck
2021-06-02 13:07 ` Thomas Huth
2021-06-02 15:13 ` Philippe Mathieu-Daudé
2021-06-07 8:11 ` Christian Borntraeger
2021-06-08 7:40 ` Cornelia Huck
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).