Skip to contentSkip to conversation

s390x/cpumodel: mepochptff: warn when no mepoch and re-align group init

PATCH Applied Collin Walling 4 participants 13 messages Feb 12, 2019 – Feb 13, 2019

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/3 s390x/cpumodel: mepochptff: warn when no mepoch and re-align group init

The extended PTFF features (qsie, qtoue, stoe, stoue) are dependent on the multiple-epoch facility (mepoch). Let's print a warning if these features are enabled without mepoch.

While we're at it, let's move the FEAT_GROUP_INIT for mepochptff down the s390_feature_groups list so it can be properly indexed with its generated S390FeatGroup enum.

---
 target/s390x/cpu_features.c | 2 +-
 target/s390x/cpu_models.c   | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)
target/s390x/cpu_features.c +1 -1
index 60cfeba48f..1843c84aaa 100644
@@ -456,7 +456,6 @@ static S390FeatGroupDef s390_feature_groups[] = {
     FEAT_GROUP_INIT("plo", PLO, "Perform-locked-operation facility"),
     FEAT_GROUP_INIT("tods", TOD_CLOCK_STEERING, "Tod-clock-steering facility"),
     FEAT_GROUP_INIT("gen13ptff", GEN13_PTFF, "PTFF enhancements introduced with z13"),
-    FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements introduced with Multiple-epoch facility"),
     FEAT_GROUP_INIT("msa", MSA, "Message-security-assist facility"),
     FEAT_GROUP_INIT("msa1", MSA_EXT_1, "Message-security-assist-extension 1 facility"),
     FEAT_GROUP_INIT("msa2", MSA_EXT_2, "Message-security-assist-extension 2 facility"),
@@ -466,6 +465,7 @@ static S390FeatGroupDef s390_feature_groups[] = {
     FEAT_GROUP_INIT("msa6", MSA_EXT_6, "Message-security-assist-extension 6 facility"),
     FEAT_GROUP_INIT("msa7", MSA_EXT_7, "Message-security-assist-extension 7 facility"),
     FEAT_GROUP_INIT("msa8", MSA_EXT_8, "Message-security-assist-extension 8 facility"),
+    FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements introduced with Multiple-epoch facility"),
 };
 
 const S390FeatGroupDef *s390_feat_group_def(S390FeatGroup group)
target/s390x/cpu_models.c +4 -0
index 7c253ff308..b42b5fd327 100644
@@ -788,6 +788,10 @@ static void check_consistency(const S390CPUModel *model)
         { S390_FEAT_SIE_KSS, S390_FEAT_SIE_F2 },
         { S390_FEAT_AP_QUERY_CONFIG_INFO, S390_FEAT_AP },
         { S390_FEAT_AP_FACILITIES_TEST, S390_FEAT_AP },
+        { S390_FEAT_PTFF_QSIE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_QTOUE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_STOE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_STOUE, S390_FEAT_MULTIPLE_EPOCH },
     };
     int i;
 
Signature · 1 line
2.20.1
#5 lore raw

PATCH v2 3/3 s390x/cpumodel: add z14 GA2 model

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.

---
 target/s390x/cpu_models.c   | 1 +
 target/s390x/gen-features.c | 7 +++++++
 2 files changed, 8 insertions(+)
target/s390x/cpu_models.c +1 -0
index d75a20e49d..86d70a3e11 100644
@@ -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"),
 };
 
target/s390x/gen-features.c +7 -0
index 4770f00105..f6ed3f4e0d 100644
@@ -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
@@ -554,6 +558,8 @@ static uint16_t default_GEN14_GA1[] = {
     S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF,
 };
 
+#define default_GEN14_GA2 EmptyFeat
+
 /* QEMU (CPU model) features */
 
 static uint16_t qemu_V2_11[] = {
@@ -662,6 +668,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)                  \
Signature · 1 line
2.20.1
#1 lore raw

PATCH v2 2/3 s390x/cpumodel: default enable mepoch for z14 and later

In reply to Collin Walling

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 nor the extended PTFF functions in the default model.

---
@Christian, @David: I elected to not add your r-b's to this patch since I've added some code to disable feature groups. I'd like to know what you both think :)

---
 hw/s390x/s390-virtio-ccw.c  |  2 ++
 target/s390x/cpu_models.c   | 24 ++++++++++++++++++++++++
 target/s390x/cpu_models.h   |  2 ++
 target/s390x/gen-features.c |  2 ++
 4 files changed, 30 insertions(+)
hw/s390x/s390-virtio-ccw.c +2 -0
index fd9d0b0542..643265f0b4 100644
@@ -757,6 +757,8 @@ 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);
+    s390_cpudef_group_featoff_greater(14, 1, S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF);
 }
 
 static void ccw_machine_3_1_class_options(MachineClass *mc)
target/s390x/cpu_models.c +24 -0
index b42b5fd327..d75a20e49d 100644
@@ -117,6 +117,30 @@ void s390_cpudef_featoff_greater(uint8_t gen, uint8_t ec_ga, S390Feat feat)
     }
 }
 
+void s390_cpudef_group_featoff_greater(uint8_t gen, uint8_t ec_ga,
+                                       S390FeatGroup group)
+{
+    const S390FeatGroupDef *group_def = s390_feat_group_def(group);
+    S390FeatBitmap group_def_off;
+    int i;
+
+    bitmap_complement(group_def_off, group_def->feat, S390_FEAT_MAX);
+
+    for (i = 0; i < ARRAY_SIZE(s390_cpu_defs); i++) {
+        const S390CPUDef *cpu_def = &s390_cpu_defs[i];
+
+        if (cpu_def->gen < gen) {
+            continue;
+        }
+        if (cpu_def->gen == gen && cpu_def->ec_ga < ec_ga) {
+            continue;
+        }
+
+        bitmap_and((unsigned long *)&cpu_def->default_feat,
+                   cpu_def->default_feat, group_def_off, S390_FEAT_MAX);
+    }
+}
+
 uint32_t s390_get_hmfai(void)
 {
     static S390CPU *cpu;
target/s390x/cpu_models.h +2 -0
index 11cf5386fb..174a99e561 100644
@@ -75,6 +75,8 @@ struct S390CPUModel {
 
 void s390_cpudef_featoff(uint8_t gen, uint8_t ec_ga, S390Feat feat);
 void s390_cpudef_featoff_greater(uint8_t gen, uint8_t ec_ga, S390Feat feat);
+void s390_cpudef_group_featoff_greater(uint8_t gen, uint8_t ec_ga,
+                                       S390FeatGroup group);
 uint32_t s390_get_hmfai(void);
 uint8_t s390_get_mha_pow(void);
 uint32_t s390_get_ibc_val(void);
target/s390x/gen-features.c +2 -0
index 70015eaaf5..4770f00105 100644
@@ -550,6 +550,8 @@ 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,
+    S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF,
 };
 
 /* QEMU (CPU model) features */
Signature · 1 line
2.20.1
Reviewed-by on v2 2/3
#2 lore raw

Re: [Qemu-devel] [PATCH v2 2/3] s390x/cpumodel: default enable mepoch for z14 and later

Quoted 8 lines · Collin Walling

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 nor the extended PTFF functions in the default model.

Quoted 5 lines

---
@Christian, @David: I elected to not add your r-b's to this patch since I've added some code to disable feature groups. I'd like to know what you both think :)

Looks good to me!

Quoted 82 lines
---
 hw/s390x/s390-virtio-ccw.c  |  2 ++
 target/s390x/cpu_models.c   | 24 ++++++++++++++++++++++++
 target/s390x/cpu_models.h   |  2 ++
 target/s390x/gen-features.c |  2 ++
 4 files changed, 30 insertions(+)
hw/s390x/s390-virtio-ccw.c +2 -0
index fd9d0b0542..643265f0b4 100644
@@ -757,6 +757,8 @@ 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);
+    s390_cpudef_group_featoff_greater(14, 1, S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF);
 }
 
 static void ccw_machine_3_1_class_options(MachineClass *mc)
target/s390x/cpu_models.c +24 -0
index b42b5fd327..d75a20e49d 100644
@@ -117,6 +117,30 @@ void s390_cpudef_featoff_greater(uint8_t gen, uint8_t ec_ga, S390Feat feat)
     }
 }
 
+void s390_cpudef_group_featoff_greater(uint8_t gen, uint8_t ec_ga,
+                                       S390FeatGroup group)
+{
+    const S390FeatGroupDef *group_def = s390_feat_group_def(group);
+    S390FeatBitmap group_def_off;
+    int i;
+
+    bitmap_complement(group_def_off, group_def->feat, S390_FEAT_MAX);
+
+    for (i = 0; i < ARRAY_SIZE(s390_cpu_defs); i++) {
+        const S390CPUDef *cpu_def = &s390_cpu_defs[i];
+
+        if (cpu_def->gen < gen) {
+            continue;
+        }
+        if (cpu_def->gen == gen && cpu_def->ec_ga < ec_ga) {
+            continue;
+        }
+
+        bitmap_and((unsigned long *)&cpu_def->default_feat,
+                   cpu_def->default_feat, group_def_off, S390_FEAT_MAX);
+    }
+}
+
 uint32_t s390_get_hmfai(void)
 {
     static S390CPU *cpu;
target/s390x/cpu_models.h +2 -0
index 11cf5386fb..174a99e561 100644
@@ -75,6 +75,8 @@ struct S390CPUModel {
 
 void s390_cpudef_featoff(uint8_t gen, uint8_t ec_ga, S390Feat feat);
 void s390_cpudef_featoff_greater(uint8_t gen, uint8_t ec_ga, S390Feat feat);
+void s390_cpudef_group_featoff_greater(uint8_t gen, uint8_t ec_ga,
+                                       S390FeatGroup group);
 uint32_t s390_get_hmfai(void);
 uint8_t s390_get_mha_pow(void);
 uint32_t s390_get_ibc_val(void);
target/s390x/gen-features.c +2 -0
index 70015eaaf5..4770f00105 100644
@@ -550,6 +550,8 @@ 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,
+    S390_FEAT_GROUP_MULTIPLE_EPOCH_PTFF,
 };
 
 /* QEMU (CPU model) features */
Signature · 3 lines
Thanks,

David / dhildenb
#7 lore raw
In reply to Collin Walling
Quoted 8 lines · On Mon, 11 Feb 2019 20:16:55 -0500 Collin Walling <[email protected]> wrote:

The extended PTFF features (qsie, qtoue, stoe, stoue) are dependent on the multiple-epoch facility (mepoch). Let's print a warning if these features are enabled without mepoch.

While we're at it, let's move the FEAT_GROUP_INIT for mepochptff down the s390_feature_groups list so it can be properly indexed with its generated S390FeatGroup enum.

Quoted 5 lines
---
 target/s390x/cpu_features.c | 2 +-
 target/s390x/cpu_models.c   | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)

Not a comment for this patch (looks fine to me), but more general:
Could you please add a cover letter if you send more than one patch? It's easy to miss that there are three patches and not two :)

Reviewed-by on v2 1/3
#9 lore raw
In reply to Collin Walling
Quoted 9 lines · Collin Walling

The extended PTFF features (qsie, qtoue, stoe, stoue) are dependent on the multiple-epoch facility (mepoch). Let's print a warning if these features are enabled without mepoch.

While we're at it, let's move the FEAT_GROUP_INIT for mepochptff down the s390_feature_groups list so it can be properly indexed with its generated S390FeatGroup enum.

Looks sane.

Quoted 41 lines
---
 target/s390x/cpu_features.c | 2 +-
 target/s390x/cpu_models.c   | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)
target/s390x/cpu_features.c +1 -1
index 60cfeba48f..1843c84aaa 100644
@@ -456,7 +456,6 @@ static S390FeatGroupDef s390_feature_groups[] = {
     FEAT_GROUP_INIT("plo", PLO, "Perform-locked-operation facility"),
     FEAT_GROUP_INIT("tods", TOD_CLOCK_STEERING, "Tod-clock-steering facility"),
     FEAT_GROUP_INIT("gen13ptff", GEN13_PTFF, "PTFF enhancements introduced with z13"),
-    FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements introduced with Multiple-epoch facility"),
     FEAT_GROUP_INIT("msa", MSA, "Message-security-assist facility"),
     FEAT_GROUP_INIT("msa1", MSA_EXT_1, "Message-security-assist-extension 1 facility"),
     FEAT_GROUP_INIT("msa2", MSA_EXT_2, "Message-security-assist-extension 2 facility"),
@@ -466,6 +465,7 @@ static S390FeatGroupDef s390_feature_groups[] = {
     FEAT_GROUP_INIT("msa6", MSA_EXT_6, "Message-security-assist-extension 6 facility"),
     FEAT_GROUP_INIT("msa7", MSA_EXT_7, "Message-security-assist-extension 7 facility"),
     FEAT_GROUP_INIT("msa8", MSA_EXT_8, "Message-security-assist-extension 8 facility"),
+    FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements introduced with Multiple-epoch facility"),
 };
 
 const S390FeatGroupDef *s390_feat_group_def(S390FeatGroup group)
target/s390x/cpu_models.c +4 -0
index 7c253ff308..b42b5fd327 100644
@@ -788,6 +788,10 @@ static void check_consistency(const S390CPUModel *model)
         { S390_FEAT_SIE_KSS, S390_FEAT_SIE_F2 },
         { S390_FEAT_AP_QUERY_CONFIG_INFO, S390_FEAT_AP },
         { S390_FEAT_AP_FACILITIES_TEST, S390_FEAT_AP },
+        { S390_FEAT_PTFF_QSIE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_QTOUE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_STOE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_STOUE, S390_FEAT_MULTIPLE_EPOCH },
     };
     int i;
 
#8 lore raw
In reply to Cornelia Huck
Quoted 17 lines · Cornelia Huck
Quoted 8 lines · On Mon, 11 Feb 2019 20:16:55 -0500 Collin Walling <[email protected]> wrote:

The extended PTFF features (qsie, qtoue, stoe, stoue) are dependent on the multiple-epoch facility (mepoch). Let's print a warning if these features are enabled without mepoch.

While we're at it, let's move the FEAT_GROUP_INIT for mepochptff down the s390_feature_groups list so it can be properly indexed with its generated S390FeatGroup enum.

Quoted 5 lines
---
 target/s390x/cpu_features.c | 2 +-
 target/s390x/cpu_models.c   | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)
Quoted 4 lines

Not a comment for this patch (looks fine to me), but more general:
Could you please add a cover letter if you send more than one patch? It's easy to miss that there are three patches and not two :)

Noted. Thanks for the advice!

Signature · 2 lines
Respectfully,
- Collin Walling
#10 lore raw
In reply to Christian Borntraeger
Quoted 11 lines · Christian Borntraeger
Quoted 8 lines · Collin Walling

The extended PTFF features (qsie, qtoue, stoe, stoue) are dependent on the multiple-epoch facility (mepoch). Let's print a warning if these features are enabled without mepoch.

While we're at it, let's move the FEAT_GROUP_INIT for mepochptff down the s390_feature_groups list so it can be properly indexed with its generated S390FeatGroup enum.

Quoted 5 lines
Quoted 1 line

Looks sane.

Thanks!

Signature · 2 lines
Respectfully,
- Collin Walling
#3 lore raw

Re: [Qemu-devel] [qemu-s390x] [PATCH v2 2/3] s390x/cpumodel: default enable mepoch for z14 and later

In reply to David Hildenbrand
Quoted 15 lines · David Hildenbrand
Quoted 8 lines · Collin Walling

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 nor the extended PTFF functions in the default model.

Quoted 5 lines

---
@Christian, @David: I elected to not add your r-b's to this patch since I've added some code to disable feature groups. I'd like to know what you both think :)

Quoted 4 lines

Looks good to me!

Thanks!

Signature · 2 lines
Respectfully,
- Collin Walling
Reviewed-by on v2 1/3
#11 lore raw
In reply to Collin Walling
Quoted 40 lines · Collin Walling

The extended PTFF features (qsie, qtoue, stoe, stoue) are dependent on the multiple-epoch facility (mepoch). Let's print a warning if these features are enabled without mepoch.

While we're at it, let's move the FEAT_GROUP_INIT for mepochptff down the s390_feature_groups list so it can be properly indexed with its generated S390FeatGroup enum.

---
 target/s390x/cpu_features.c | 2 +-
 target/s390x/cpu_models.c   | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)
target/s390x/cpu_features.c +1 -1
index 60cfeba48f..1843c84aaa 100644
@@ -456,7 +456,6 @@ static S390FeatGroupDef s390_feature_groups[] = {
     FEAT_GROUP_INIT("plo", PLO, "Perform-locked-operation facility"),
     FEAT_GROUP_INIT("tods", TOD_CLOCK_STEERING, "Tod-clock-steering facility"),
     FEAT_GROUP_INIT("gen13ptff", GEN13_PTFF, "PTFF enhancements introduced with z13"),
-    FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements introduced with Multiple-epoch facility"),
     FEAT_GROUP_INIT("msa", MSA, "Message-security-assist facility"),
     FEAT_GROUP_INIT("msa1", MSA_EXT_1, "Message-security-assist-extension 1 facility"),
     FEAT_GROUP_INIT("msa2", MSA_EXT_2, "Message-security-assist-extension 2 facility"),
@@ -466,6 +465,7 @@ static S390FeatGroupDef s390_feature_groups[] = {
     FEAT_GROUP_INIT("msa6", MSA_EXT_6, "Message-security-assist-extension 6 facility"),
     FEAT_GROUP_INIT("msa7", MSA_EXT_7, "Message-security-assist-extension 7 facility"),
     FEAT_GROUP_INIT("msa8", MSA_EXT_8, "Message-security-assist-extension 8 facility"),
+    FEAT_GROUP_INIT("mepochptff", MULTIPLE_EPOCH_PTFF, "PTFF enhancements introduced with Multiple-epoch facility"),
 };
 
 const S390FeatGroupDef *s390_feat_group_def(S390FeatGroup group)
target/s390x/cpu_models.c +0 -0
index 7c253ff308..b42b5fd327 100644

target/s390x/cpu_models.c static void check_consistency(const S390CPUModel *model) · line 797

Quoted 10 lines
target/s390x/cpu_models.c +4 -0
@@ -788,6 +788,10 @@ static void check_consistency(const S390CPUModel *model)
         { S390_FEAT_SIE_KSS, S390_FEAT_SIE_F2 },
         { S390_FEAT_AP_QUERY_CONFIG_INFO, S390_FEAT_AP },
         { S390_FEAT_AP_FACILITIES_TEST, S390_FEAT_AP },
+        { S390_FEAT_PTFF_QSIE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_QTOUE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_STOE, S390_FEAT_MULTIPLE_EPOCH },
+        { S390_FEAT_PTFF_STOUE, S390_FEAT_MULTIPLE_EPOCH },
     };
     int i;
 
Signature · 3 lines
Thanks,

David / dhildenb
#12 lore raw
In reply to Collin Walling
Quoted 8 lines · On Mon, 11 Feb 2019 20:16:55 -0500 Collin Walling <[email protected]> wrote:

The extended PTFF features (qsie, qtoue, stoe, stoue) are dependent on the multiple-epoch facility (mepoch). Let's print a warning if these features are enabled without mepoch.

While we're at it, let's move the FEAT_GROUP_INIT for mepochptff down the s390_feature_groups list so it can be properly indexed with its generated S390FeatGroup enum.

Quoted 5 lines
---
 target/s390x/cpu_features.c | 2 +-
 target/s390x/cpu_models.c   | 4 ++++
 2 files changed, 5 insertions(+), 1 deletion(-)

Thanks, applied.

#4 lore raw

Re: [Qemu-devel] [PATCH v2 2/3] s390x/cpumodel: default enable mepoch for z14 and later

In reply to Collin Walling
Quoted 13 lines · On Mon, 11 Feb 2019 20:16:56 -0500 Collin Walling <[email protected]> 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 nor the extended PTFF functions in the default model.

---
@Christian, @David: I elected to not add your r-b's to this patch since I've added some code to disable feature groups. I'd like to know what you both think :)

Quoted 6 lines
---
 hw/s390x/s390-virtio-ccw.c  |  2 ++
 target/s390x/cpu_models.c   | 24 ++++++++++++++++++++++++
 target/s390x/cpu_models.h   |  2 ++
 target/s390x/gen-features.c |  2 ++
 4 files changed, 30 insertions(+)

This gained a conflict in s390-virtio-ccw.c, which I fixed up.

Thanks, applied.

#6 lore raw

Re: [Qemu-devel] [PATCH v2 3/3] s390x/cpumodel: add z14 GA2 model

In reply to Collin Walling
Quoted 11 lines · On Mon, 11 Feb 2019 20:16:57 -0500 Collin Walling <[email protected]> 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.

---
 target/s390x/cpu_models.c   | 1 +
 target/s390x/gen-features.c | 7 +++++++
 2 files changed, 8 insertions(+)

Thanks, applied.