All of lore.kernel.org
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later
@ 2019-02-08 22:11 Collin Walling
  2019-02-08 22:11 ` [Qemu-devel] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model Collin Walling
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Collin Walling @ 2019-02-08 22:11 UTC (permalink / raw)
  To: qemu-devel, qemu-s390x; +Cc: david, borntraeger, cohuck, pasic, rth

Latest systems and host kernels support mepoch, which is a
feature that was meant to be supported for z14 GA1 from the
get-go. Let's copy it to the z14 GA1 default CPU model.

Machines s390-ccw-virtio-3.1 and older will retain the old CPU
models and will not provide this bit in the default model.

Signed-off-by: Collin Walling <walling@linux.ibm.com>
---
 hw/s390x/s390-virtio-ccw.c  | 1 +
 target/s390x/gen-features.c | 1 +
 2 files changed, 2 insertions(+)

diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
index fd9d0b0542..32c5027345 100644
--- a/hw/s390x/s390-virtio-ccw.c
+++ b/hw/s390x/s390-virtio-ccw.c
@@ -757,6 +757,7 @@ DEFINE_CCW_MACHINE(4_0, "4.0", true);
 static void ccw_machine_3_1_instance_options(MachineState *machine)
 {
     ccw_machine_4_0_instance_options(machine);
+    s390_cpudef_featoff_greater(14, 1, S390_FEAT_MULTIPLE_EPOCH);
 }
 
 static void ccw_machine_3_1_class_options(MachineClass *mc)
diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
index 70015eaaf5..d258d67dca 100644
--- a/target/s390x/gen-features.c
+++ b/target/s390x/gen-features.c
@@ -550,6 +550,7 @@ static uint16_t default_GEN14_GA1[] = {
     S390_FEAT_GROUP_MSA_EXT_6,
     S390_FEAT_GROUP_MSA_EXT_7,
     S390_FEAT_GROUP_MSA_EXT_8,
+    S390_FEAT_MULTIPLE_EPOCH,
 };
 
 /* QEMU (CPU model) features */
-- 
2.20.1

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* [Qemu-devel] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model
  2019-02-08 22:11 [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later Collin Walling
@ 2019-02-08 22:11 ` Collin Walling
  2019-02-11  8:19   ` [Qemu-devel] [qemu-s390x] " Christian Borntraeger
  2019-02-11  8:50   ` [Qemu-devel] " David Hildenbrand
  2019-02-11  8:14 ` [Qemu-devel] [qemu-s390x] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later Christian Borntraeger
  2019-02-11  8:23 ` [Qemu-devel] " Cornelia Huck
  2 siblings, 2 replies; 9+ messages in thread
From: Collin Walling @ 2019-02-08 22:11 UTC (permalink / raw)
  To: qemu-devel, qemu-s390x; +Cc: david, borntraeger, cohuck, pasic, rth

Introduce the z14 GA2 cpu model for QEMU. There are no new features
introduced with this model, and will inherit the same feature set as
z14 GA1.

Signed-off-by: Collin Walling <walling@linux.ibm.com>
---
 target/s390x/cpu_models.c   | 1 +
 target/s390x/gen-features.c | 7 +++++++
 2 files changed, 8 insertions(+)

diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c
index 7c253ff308..968c21cd47 100644
--- a/target/s390x/cpu_models.c
+++ b/target/s390x/cpu_models.c
@@ -79,6 +79,7 @@ static S390CPUDef s390_cpu_defs[] = {
     CPUDEF_INIT(0x2964, 13, 2, 47, 0x08000000U, "z13.2", "IBM z13 GA2"),
     CPUDEF_INIT(0x2965, 13, 2, 47, 0x08000000U, "z13s", "IBM z13s GA1"),
     CPUDEF_INIT(0x3906, 14, 1, 47, 0x08000000U, "z14", "IBM z14 GA1"),
+    CPUDEF_INIT(0x3906, 14, 2, 47, 0x08000000U, "z14.2", "IBM z14 GA2"),
     CPUDEF_INIT(0x3907, 14, 1, 47, 0x08000000U, "z14ZR1", "IBM z14 Model ZR1 GA1"),
 };
 
diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
index d258d67dca..3026fbd88e 100644
--- a/target/s390x/gen-features.c
+++ b/target/s390x/gen-features.c
@@ -353,6 +353,8 @@ static uint16_t base_GEN14_GA1[] = {
     S390_FEAT_ORDER_PRESERVING_COMPRESSION,
 };
 
+#define base_GEN14_GA2 EmptyFeat
+
 /* Full features (in order of release)
  * Automatically includes corresponding base features.
  * Full features are all features this hardware supports even if kvm/QEMU do not
@@ -480,6 +482,8 @@ static uint16_t full_GEN14_GA1[] = {
     S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF,
 };
 
+#define full_GEN14_GA2 EmptyFeat
+
 /* Default features (in order of release)
  * Automatically includes corresponding base features.
  * Default features are all features this version of QEMU supports for this
@@ -553,6 +557,8 @@ static uint16_t default_GEN14_GA1[] = {
     S390_FEAT_MULTIPLE_EPOCH,
 };
 
+#define default_GEN14_GA2 EmptyFeat
+
 /* QEMU (CPU model) features */
 
 static uint16_t qemu_V2_11[] = {
@@ -661,6 +667,7 @@ static CpuFeatDefSpec CpuFeatDef[] = {
     CPU_FEAT_INITIALIZER(GEN13_GA1),
     CPU_FEAT_INITIALIZER(GEN13_GA2),
     CPU_FEAT_INITIALIZER(GEN14_GA1),
+    CPU_FEAT_INITIALIZER(GEN14_GA2),
 };
 
 #define FEAT_GROUP_INITIALIZER(_name)                  \
-- 
2.20.1

^ permalink raw reply related	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] [qemu-s390x] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later
  2019-02-08 22:11 [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later Collin Walling
  2019-02-08 22:11 ` [Qemu-devel] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model Collin Walling
@ 2019-02-11  8:14 ` Christian Borntraeger
  2019-02-11  8:23 ` [Qemu-devel] " Cornelia Huck
  2 siblings, 0 replies; 9+ messages in thread
From: Christian Borntraeger @ 2019-02-11  8:14 UTC (permalink / raw)
  To: Collin Walling, qemu-devel, qemu-s390x; +Cc: pasic, rth, cohuck, david



On 08.02.2019 23:11, Collin Walling wrote:
> Latest systems and host kernels support mepoch, which is a
> feature that was meant to be supported for z14 GA1 from the
> get-go. Let's copy it to the z14 GA1 default CPU model.
> 
> Machines s390-ccw-virtio-3.1 and older will retain the old CPU
> models and will not provide this bit in the default model.
> 
> Signed-off-by: Collin Walling <walling@linux.ibm.com>

Yes, we missed that back then for the intial z14 version as the kernel
and qemu parts were added later. 

Reviewed-by: Christian Borntraeger <borntraeger@de.ibm.com>


> ---
>  hw/s390x/s390-virtio-ccw.c  | 1 +
>  target/s390x/gen-features.c | 1 +
>  2 files changed, 2 insertions(+)
> 
> diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
> index fd9d0b0542..32c5027345 100644
> --- a/hw/s390x/s390-virtio-ccw.c
> +++ b/hw/s390x/s390-virtio-ccw.c
> @@ -757,6 +757,7 @@ DEFINE_CCW_MACHINE(4_0, "4.0", true);
>  static void ccw_machine_3_1_instance_options(MachineState *machine)
>  {
>      ccw_machine_4_0_instance_options(machine);
> +    s390_cpudef_featoff_greater(14, 1, S390_FEAT_MULTIPLE_EPOCH);
>  }
>  
>  static void ccw_machine_3_1_class_options(MachineClass *mc)
> diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
> index 70015eaaf5..d258d67dca 100644
> --- a/target/s390x/gen-features.c
> +++ b/target/s390x/gen-features.c
> @@ -550,6 +550,7 @@ static uint16_t default_GEN14_GA1[] = {
>      S390_FEAT_GROUP_MSA_EXT_6,
>      S390_FEAT_GROUP_MSA_EXT_7,
>      S390_FEAT_GROUP_MSA_EXT_8,
> +    S390_FEAT_MULTIPLE_EPOCH,
>  };
>  
>  /* QEMU (CPU model) features */
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] [qemu-s390x] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model
  2019-02-08 22:11 ` [Qemu-devel] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model Collin Walling
@ 2019-02-11  8:19   ` Christian Borntraeger
  2019-02-11  8:50   ` [Qemu-devel] " David Hildenbrand
  1 sibling, 0 replies; 9+ messages in thread
From: Christian Borntraeger @ 2019-02-11  8:19 UTC (permalink / raw)
  To: Collin Walling, qemu-devel, qemu-s390x; +Cc: pasic, rth, cohuck, david



On 08.02.2019 23:11, Collin Walling wrote:
> Introduce the z14 GA2 cpu model for QEMU. There are no new features
> introduced with this model, and will inherit the same feature set as
> z14 GA1.
> 
> Signed-off-by: Collin Walling <walling@linux.ibm.com>

Acked-by: Christian Borntraeger <borntraeger@de.ibm.com>

> ---
>  target/s390x/cpu_models.c   | 1 +
>  target/s390x/gen-features.c | 7 +++++++
>  2 files changed, 8 insertions(+)
> 
> diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c
> index 7c253ff308..968c21cd47 100644
> --- a/target/s390x/cpu_models.c
> +++ b/target/s390x/cpu_models.c
> @@ -79,6 +79,7 @@ static S390CPUDef s390_cpu_defs[] = {
>      CPUDEF_INIT(0x2964, 13, 2, 47, 0x08000000U, "z13.2", "IBM z13 GA2"),
>      CPUDEF_INIT(0x2965, 13, 2, 47, 0x08000000U, "z13s", "IBM z13s GA1"),
>      CPUDEF_INIT(0x3906, 14, 1, 47, 0x08000000U, "z14", "IBM z14 GA1"),
> +    CPUDEF_INIT(0x3906, 14, 2, 47, 0x08000000U, "z14.2", "IBM z14 GA2"),
>      CPUDEF_INIT(0x3907, 14, 1, 47, 0x08000000U, "z14ZR1", "IBM z14 Model ZR1 GA1"),
>  };
>  
> diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
> index d258d67dca..3026fbd88e 100644
> --- a/target/s390x/gen-features.c
> +++ b/target/s390x/gen-features.c
> @@ -353,6 +353,8 @@ static uint16_t base_GEN14_GA1[] = {
>      S390_FEAT_ORDER_PRESERVING_COMPRESSION,
>  };
>  
> +#define base_GEN14_GA2 EmptyFeat
> +
>  /* Full features (in order of release)
>   * Automatically includes corresponding base features.
>   * Full features are all features this hardware supports even if kvm/QEMU do not
> @@ -480,6 +482,8 @@ static uint16_t full_GEN14_GA1[] = {
>      S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF,
>  };
>  
> +#define full_GEN14_GA2 EmptyFeat
> +
>  /* Default features (in order of release)
>   * Automatically includes corresponding base features.
>   * Default features are all features this version of QEMU supports for this
> @@ -553,6 +557,8 @@ static uint16_t default_GEN14_GA1[] = {
>      S390_FEAT_MULTIPLE_EPOCH,
>  };
>  
> +#define default_GEN14_GA2 EmptyFeat
> +
>  /* QEMU (CPU model) features */
>  
>  static uint16_t qemu_V2_11[] = {
> @@ -661,6 +667,7 @@ static CpuFeatDefSpec CpuFeatDef[] = {
>      CPU_FEAT_INITIALIZER(GEN13_GA1),
>      CPU_FEAT_INITIALIZER(GEN13_GA2),
>      CPU_FEAT_INITIALIZER(GEN14_GA1),
> +    CPU_FEAT_INITIALIZER(GEN14_GA2),
>  };
>  
>  #define FEAT_GROUP_INITIALIZER(_name)                  \
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later
  2019-02-08 22:11 [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later Collin Walling
  2019-02-08 22:11 ` [Qemu-devel] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model Collin Walling
  2019-02-11  8:14 ` [Qemu-devel] [qemu-s390x] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later Christian Borntraeger
@ 2019-02-11  8:23 ` Cornelia Huck
  2019-02-11  8:28   ` Christian Borntraeger
  2 siblings, 1 reply; 9+ messages in thread
From: Cornelia Huck @ 2019-02-11  8:23 UTC (permalink / raw)
  To: Collin Walling; +Cc: qemu-devel, qemu-s390x, david, borntraeger, pasic, rth

On Fri,  8 Feb 2019 17:11:10 -0500
Collin Walling <walling@linux.ibm.com> wrote:

> Latest systems and host kernels support mepoch, which is a
> feature that was meant to be supported for z14 GA1 from the
> get-go. Let's copy it to the z14 GA1 default CPU model.

Do older kernels simply not support it, or was there something actively
missing? IOW, is it fine to turn this on with older kernels?

[It's probably all good, although I like to wait for David's ack for
any cpu model patches :)]

> 
> Machines s390-ccw-virtio-3.1 and older will retain the old CPU
> models and will not provide this bit in the default model.
> 
> Signed-off-by: Collin Walling <walling@linux.ibm.com>
> ---
>  hw/s390x/s390-virtio-ccw.c  | 1 +
>  target/s390x/gen-features.c | 1 +
>  2 files changed, 2 insertions(+)
> 
> diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
> index fd9d0b0542..32c5027345 100644
> --- a/hw/s390x/s390-virtio-ccw.c
> +++ b/hw/s390x/s390-virtio-ccw.c
> @@ -757,6 +757,7 @@ DEFINE_CCW_MACHINE(4_0, "4.0", true);
>  static void ccw_machine_3_1_instance_options(MachineState *machine)
>  {
>      ccw_machine_4_0_instance_options(machine);
> +    s390_cpudef_featoff_greater(14, 1, S390_FEAT_MULTIPLE_EPOCH);
>  }
>  
>  static void ccw_machine_3_1_class_options(MachineClass *mc)
> diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
> index 70015eaaf5..d258d67dca 100644
> --- a/target/s390x/gen-features.c
> +++ b/target/s390x/gen-features.c
> @@ -550,6 +550,7 @@ static uint16_t default_GEN14_GA1[] = {
>      S390_FEAT_GROUP_MSA_EXT_6,
>      S390_FEAT_GROUP_MSA_EXT_7,
>      S390_FEAT_GROUP_MSA_EXT_8,
> +    S390_FEAT_MULTIPLE_EPOCH,
>  };
>  
>  /* QEMU (CPU model) features */

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later
  2019-02-11  8:23 ` [Qemu-devel] " Cornelia Huck
@ 2019-02-11  8:28   ` Christian Borntraeger
  2019-02-11  8:55     ` David Hildenbrand
  0 siblings, 1 reply; 9+ messages in thread
From: Christian Borntraeger @ 2019-02-11  8:28 UTC (permalink / raw)
  To: Cornelia Huck, Collin Walling; +Cc: qemu-devel, qemu-s390x, david, pasic, rth



On 11.02.2019 09:23, Cornelia Huck wrote:
> On Fri,  8 Feb 2019 17:11:10 -0500
> Collin Walling <walling@linux.ibm.com> wrote:
> 
>> Latest systems and host kernels support mepoch, which is a
>> feature that was meant to be supported for z14 GA1 from the
>> get-go. Let's copy it to the z14 GA1 default CPU model.
> 
> Do older kernels simply not support it, or was there something actively
> missing? IOW, is it fine to turn this on with older kernels?

Older kernels will not provide the necessary implementation, so mepoch will not
work with such older kernel. (So worst case would be that a new qemu+old kernel
requires to add mepoch=off to -cpu z14)
The idea of this patch is to update QEMU in accordance with newer kernels to use
more features by default if people use -cpu z14.

Now that I look a 2nd time: shall we also add 
S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF ?


> 
> [It's probably all good, although I like to wait for David's ack for
> any cpu model patches :)]
> 
>>
>> Machines s390-ccw-virtio-3.1 and older will retain the old CPU
>> models and will not provide this bit in the default model.
>>
>> Signed-off-by: Collin Walling <walling@linux.ibm.com>
>> ---
>>  hw/s390x/s390-virtio-ccw.c  | 1 +
>>  target/s390x/gen-features.c | 1 +
>>  2 files changed, 2 insertions(+)
>>
>> diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
>> index fd9d0b0542..32c5027345 100644
>> --- a/hw/s390x/s390-virtio-ccw.c
>> +++ b/hw/s390x/s390-virtio-ccw.c
>> @@ -757,6 +757,7 @@ DEFINE_CCW_MACHINE(4_0, "4.0", true);
>>  static void ccw_machine_3_1_instance_options(MachineState *machine)
>>  {
>>      ccw_machine_4_0_instance_options(machine);
>> +    s390_cpudef_featoff_greater(14, 1, S390_FEAT_MULTIPLE_EPOCH);
>>  }
>>  
>>  static void ccw_machine_3_1_class_options(MachineClass *mc)
>> diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
>> index 70015eaaf5..d258d67dca 100644
>> --- a/target/s390x/gen-features.c
>> +++ b/target/s390x/gen-features.c
>> @@ -550,6 +550,7 @@ static uint16_t default_GEN14_GA1[] = {
>>      S390_FEAT_GROUP_MSA_EXT_6,
>>      S390_FEAT_GROUP_MSA_EXT_7,
>>      S390_FEAT_GROUP_MSA_EXT_8,
>> +    S390_FEAT_MULTIPLE_EPOCH,
>>  };
>>  
>>  /* QEMU (CPU model) features */
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model
  2019-02-08 22:11 ` [Qemu-devel] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model Collin Walling
  2019-02-11  8:19   ` [Qemu-devel] [qemu-s390x] " Christian Borntraeger
@ 2019-02-11  8:50   ` David Hildenbrand
  1 sibling, 0 replies; 9+ messages in thread
From: David Hildenbrand @ 2019-02-11  8:50 UTC (permalink / raw)
  To: Collin Walling, qemu-devel, qemu-s390x; +Cc: borntraeger, cohuck, pasic, rth

On 08.02.19 23:11, Collin Walling wrote:
> Introduce the z14 GA2 cpu model for QEMU. There are no new features
> introduced with this model, and will inherit the same feature set as
> z14 GA1.
> 
> Signed-off-by: Collin Walling <walling@linux.ibm.com>
> ---
>  target/s390x/cpu_models.c   | 1 +
>  target/s390x/gen-features.c | 7 +++++++
>  2 files changed, 8 insertions(+)
> 
> diff --git a/target/s390x/cpu_models.c b/target/s390x/cpu_models.c
> index 7c253ff308..968c21cd47 100644
> --- a/target/s390x/cpu_models.c
> +++ b/target/s390x/cpu_models.c
> @@ -79,6 +79,7 @@ static S390CPUDef s390_cpu_defs[] = {
>      CPUDEF_INIT(0x2964, 13, 2, 47, 0x08000000U, "z13.2", "IBM z13 GA2"),
>      CPUDEF_INIT(0x2965, 13, 2, 47, 0x08000000U, "z13s", "IBM z13s GA1"),
>      CPUDEF_INIT(0x3906, 14, 1, 47, 0x08000000U, "z14", "IBM z14 GA1"),
> +    CPUDEF_INIT(0x3906, 14, 2, 47, 0x08000000U, "z14.2", "IBM z14 GA2"),
>      CPUDEF_INIT(0x3907, 14, 1, 47, 0x08000000U, "z14ZR1", "IBM z14 Model ZR1 GA1"),
>  };
>  
> diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
> index d258d67dca..3026fbd88e 100644
> --- a/target/s390x/gen-features.c
> +++ b/target/s390x/gen-features.c
> @@ -353,6 +353,8 @@ static uint16_t base_GEN14_GA1[] = {
>      S390_FEAT_ORDER_PRESERVING_COMPRESSION,
>  };
>  
> +#define base_GEN14_GA2 EmptyFeat
> +
>  /* Full features (in order of release)
>   * Automatically includes corresponding base features.
>   * Full features are all features this hardware supports even if kvm/QEMU do not
> @@ -480,6 +482,8 @@ static uint16_t full_GEN14_GA1[] = {
>      S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF,
>  };
>  
> +#define full_GEN14_GA2 EmptyFeat
> +
>  /* Default features (in order of release)
>   * Automatically includes corresponding base features.
>   * Default features are all features this version of QEMU supports for this
> @@ -553,6 +557,8 @@ static uint16_t default_GEN14_GA1[] = {
>      S390_FEAT_MULTIPLE_EPOCH,
>  };
>  
> +#define default_GEN14_GA2 EmptyFeat
> +
>  /* QEMU (CPU model) features */
>  
>  static uint16_t qemu_V2_11[] = {
> @@ -661,6 +667,7 @@ static CpuFeatDefSpec CpuFeatDef[] = {
>      CPU_FEAT_INITIALIZER(GEN13_GA1),
>      CPU_FEAT_INITIALIZER(GEN13_GA2),
>      CPU_FEAT_INITIALIZER(GEN14_GA1),
> +    CPU_FEAT_INITIALIZER(GEN14_GA2),
>  };
>  
>  #define FEAT_GROUP_INITIALIZER(_name)                  \
> 

Reviewed-by: David Hildenbrand <david@redhat.com>

-- 

Thanks,

David / dhildenb

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later
  2019-02-11  8:28   ` Christian Borntraeger
@ 2019-02-11  8:55     ` David Hildenbrand
  2019-02-11 10:37       ` Cornelia Huck
  0 siblings, 1 reply; 9+ messages in thread
From: David Hildenbrand @ 2019-02-11  8:55 UTC (permalink / raw)
  To: Christian Borntraeger, Cornelia Huck, Collin Walling
  Cc: qemu-devel, qemu-s390x, pasic, rth

On 11.02.19 09:28, Christian Borntraeger wrote:
> 
> 
> On 11.02.2019 09:23, Cornelia Huck wrote:
>> On Fri,  8 Feb 2019 17:11:10 -0500
>> Collin Walling <walling@linux.ibm.com> wrote:
>>
>>> Latest systems and host kernels support mepoch, which is a
>>> feature that was meant to be supported for z14 GA1 from the
>>> get-go. Let's copy it to the z14 GA1 default CPU model.
>>
>> Do older kernels simply not support it, or was there something actively
>> missing? IOW, is it fine to turn this on with older kernels?
> 
> Older kernels will not provide the necessary implementation, so mepoch will not
> work with such older kernel. (So worst case would be that a new qemu+old kernel
> requires to add mepoch=off to -cpu z14)

Or use a compat machine.

> The idea of this patch is to update QEMU in accordance with newer kernels to use
> more features by default if people use -cpu z14.

Agreed, this was the original purpose of the default models. Can "break"
on old kernels, but the compat machines can help for these users, so it
does not really "break".

> 
> Now that I look a 2nd time: shall we also add 
> S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF ?

I think so.

> 
> 
>>
>> [It's probably all good, although I like to wait for David's ack for
>> any cpu model patches :)]

I'm fine with this :)

With S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF also added

Reviewed-by: David Hildenbrand <david@redhat.com>

>>
>>>
>>> Machines s390-ccw-virtio-3.1 and older will retain the old CPU
>>> models and will not provide this bit in the default model.
>>>
>>> Signed-off-by: Collin Walling <walling@linux.ibm.com>
>>> ---
>>>  hw/s390x/s390-virtio-ccw.c  | 1 +
>>>  target/s390x/gen-features.c | 1 +
>>>  2 files changed, 2 insertions(+)
>>>
>>> diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
>>> index fd9d0b0542..32c5027345 100644
>>> --- a/hw/s390x/s390-virtio-ccw.c
>>> +++ b/hw/s390x/s390-virtio-ccw.c
>>> @@ -757,6 +757,7 @@ DEFINE_CCW_MACHINE(4_0, "4.0", true);
>>>  static void ccw_machine_3_1_instance_options(MachineState *machine)
>>>  {
>>>      ccw_machine_4_0_instance_options(machine);
>>> +    s390_cpudef_featoff_greater(14, 1, S390_FEAT_MULTIPLE_EPOCH);
>>>  }
>>>  
>>>  static void ccw_machine_3_1_class_options(MachineClass *mc)
>>> diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
>>> index 70015eaaf5..d258d67dca 100644
>>> --- a/target/s390x/gen-features.c
>>> +++ b/target/s390x/gen-features.c
>>> @@ -550,6 +550,7 @@ static uint16_t default_GEN14_GA1[] = {
>>>      S390_FEAT_GROUP_MSA_EXT_6,
>>>      S390_FEAT_GROUP_MSA_EXT_7,
>>>      S390_FEAT_GROUP_MSA_EXT_8,
>>> +    S390_FEAT_MULTIPLE_EPOCH,
>>>  };
>>>  
>>>  /* QEMU (CPU model) features */
>>
> 


-- 

Thanks,

David / dhildenb

^ permalink raw reply	[flat|nested] 9+ messages in thread

* Re: [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later
  2019-02-11  8:55     ` David Hildenbrand
@ 2019-02-11 10:37       ` Cornelia Huck
  0 siblings, 0 replies; 9+ messages in thread
From: Cornelia Huck @ 2019-02-11 10:37 UTC (permalink / raw)
  To: David Hildenbrand
  Cc: Christian Borntraeger, Collin Walling, qemu-devel, qemu-s390x,
	pasic, rth

On Mon, 11 Feb 2019 09:55:25 +0100
David Hildenbrand <david@redhat.com> wrote:

> On 11.02.19 09:28, Christian Borntraeger wrote:
> > 
> > 
> > On 11.02.2019 09:23, Cornelia Huck wrote:  
> >> On Fri,  8 Feb 2019 17:11:10 -0500
> >> Collin Walling <walling@linux.ibm.com> wrote:
> >>  
> >>> Latest systems and host kernels support mepoch, which is a
> >>> feature that was meant to be supported for z14 GA1 from the
> >>> get-go. Let's copy it to the z14 GA1 default CPU model.  
> >>
> >> Do older kernels simply not support it, or was there something actively
> >> missing? IOW, is it fine to turn this on with older kernels?  
> > 
> > Older kernels will not provide the necessary implementation, so mepoch will not
> > work with such older kernel. (So worst case would be that a new qemu+old kernel
> > requires to add mepoch=off to -cpu z14)  
> 
> Or use a compat machine.
> 
> > The idea of this patch is to update QEMU in accordance with newer kernels to use
> > more features by default if people use -cpu z14.  
> 
> Agreed, this was the original purpose of the default models. Can "break"
> on old kernels, but the compat machines can help for these users, so it
> does not really "break".

That seems fine then.

> 
> > 
> > Now that I look a 2nd time: shall we also add 
> > S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF ?  
> 
> I think so.
> 
> > 
> >   
> >>
> >> [It's probably all good, although I like to wait for David's ack for
> >> any cpu model patches :)]  
> 
> I'm fine with this :)
> 
> With S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF also added
> 
> Reviewed-by: David Hildenbrand <david@redhat.com>

Ok, can I please get a v2 with that added as well?

> 
> >>  
> >>>
> >>> Machines s390-ccw-virtio-3.1 and older will retain the old CPU
> >>> models and will not provide this bit in the default model.
> >>>
> >>> Signed-off-by: Collin Walling <walling@linux.ibm.com>
> >>> ---
> >>>  hw/s390x/s390-virtio-ccw.c  | 1 +
> >>>  target/s390x/gen-features.c | 1 +
> >>>  2 files changed, 2 insertions(+)
> >>>
> >>> diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c
> >>> index fd9d0b0542..32c5027345 100644
> >>> --- a/hw/s390x/s390-virtio-ccw.c
> >>> +++ b/hw/s390x/s390-virtio-ccw.c
> >>> @@ -757,6 +757,7 @@ DEFINE_CCW_MACHINE(4_0, "4.0", true);
> >>>  static void ccw_machine_3_1_instance_options(MachineState *machine)
> >>>  {
> >>>      ccw_machine_4_0_instance_options(machine);
> >>> +    s390_cpudef_featoff_greater(14, 1, S390_FEAT_MULTIPLE_EPOCH);
> >>>  }
> >>>  
> >>>  static void ccw_machine_3_1_class_options(MachineClass *mc)
> >>> diff --git a/target/s390x/gen-features.c b/target/s390x/gen-features.c
> >>> index 70015eaaf5..d258d67dca 100644
> >>> --- a/target/s390x/gen-features.c
> >>> +++ b/target/s390x/gen-features.c
> >>> @@ -550,6 +550,7 @@ static uint16_t default_GEN14_GA1[] = {
> >>>      S390_FEAT_GROUP_MSA_EXT_6,
> >>>      S390_FEAT_GROUP_MSA_EXT_7,
> >>>      S390_FEAT_GROUP_MSA_EXT_8,
> >>> +    S390_FEAT_MULTIPLE_EPOCH,
> >>>  };
> >>>  
> >>>  /* QEMU (CPU model) features */  
> >>  
> >   
> 
> 

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2019-02-11 10:38 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-02-08 22:11 [Qemu-devel] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later Collin Walling
2019-02-08 22:11 ` [Qemu-devel] [PATCH 2/2] s390x/cpumodel: add z14 GA2 model Collin Walling
2019-02-11  8:19   ` [Qemu-devel] [qemu-s390x] " Christian Borntraeger
2019-02-11  8:50   ` [Qemu-devel] " David Hildenbrand
2019-02-11  8:14 ` [Qemu-devel] [qemu-s390x] [PATCH 1/2] s390x/cpumodel: default enable mepoch for z14 and later Christian Borntraeger
2019-02-11  8:23 ` [Qemu-devel] " Cornelia Huck
2019-02-11  8:28   ` Christian Borntraeger
2019-02-11  8:55     ` David Hildenbrand
2019-02-11 10:37       ` Cornelia Huck

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.