Message ID | 20241106030728.553238-2-zhao1.liu@intel.com |
---|---|
State | New |
Headers | show |
Series | i386: miscellaneous cleanup | expand |
On Wed, Nov 06, 2024 at 11:07:18AM +0800, Zhao Liu wrote: > In x86_cpu_filter_features(), if host doesn't support AVX10, the > configured avx10_version should be marked as filtered regardless of > whether prefix is NULL or not. > > Check prefix before warn_report() instead of checking for > have_filtered_features. > > Cc: qemu-stable@nongnu.org > Fixes: commit bccfb846fd52 ("target/i386: add AVX10 feature and AVX10 version property") > Signed-off-by: Zhao Liu <zhao1.liu@intel.com> Reviewed-by: Tao Su <tao1.su@linux.intel.com> > --- > v5: new commit. > --- > target/i386/cpu.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/target/i386/cpu.c b/target/i386/cpu.c > index 3baa95481fbc..77c1233daa13 100644 > --- a/target/i386/cpu.c > +++ b/target/i386/cpu.c > @@ -7711,8 +7711,10 @@ static bool x86_cpu_filter_features(X86CPU *cpu, bool verbose) > env->avx10_version = version; > have_filtered_features = true; > } > - } else if (env->avx10_version && prefix) { > - warn_report("%s: avx10.%d.", prefix, env->avx10_version); > + } else if (env->avx10_version) { > + if (prefix) { > + warn_report("%s: avx10.%d.", prefix, env->avx10_version); > + } > have_filtered_features = true; > } > > -- > 2.34.1 >
06.11.2024 06:07, Zhao Liu wrote: > In x86_cpu_filter_features(), if host doesn't support AVX10, the > configured avx10_version should be marked as filtered regardless of > whether prefix is NULL or not. > > Check prefix before warn_report() instead of checking for > have_filtered_features. > > Cc: qemu-stable@nongnu.org > Fixes: commit bccfb846fd52 ("target/i386: add AVX10 feature and AVX10 version property") > Signed-off-by: Zhao Liu <zhao1.liu@intel.com> Hi! Has this patch been forgotten? 9.2 is out already and I'm collecting fixes for it... Thanks, /mjt > --- > v5: new commit. > --- > target/i386/cpu.c | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/target/i386/cpu.c b/target/i386/cpu.c > index 3baa95481fbc..77c1233daa13 100644 > --- a/target/i386/cpu.c > +++ b/target/i386/cpu.c > @@ -7711,8 +7711,10 @@ static bool x86_cpu_filter_features(X86CPU *cpu, bool verbose) > env->avx10_version = version; > have_filtered_features = true; > } > - } else if (env->avx10_version && prefix) { > - warn_report("%s: avx10.%d.", prefix, env->avx10_version); > + } else if (env->avx10_version) { > + if (prefix) { > + warn_report("%s: avx10.%d.", prefix, env->avx10_version); > + } > have_filtered_features = true; > } >
On 21.12.2024 00:04, Michael Tokarev wrote: > 06.11.2024 06:07, Zhao Liu wrote: >> In x86_cpu_filter_features(), if host doesn't support AVX10, the >> configured avx10_version should be marked as filtered regardless of >> whether prefix is NULL or not. >> >> Check prefix before warn_report() instead of checking for >> have_filtered_features. >> >> Cc: qemu-stable@nongnu.org >> Fixes: commit bccfb846fd52 ("target/i386: add AVX10 feature and AVX10 >> version property") >> Signed-off-by: Zhao Liu <zhao1.liu@intel.com> > > Hi! > > Has this patch been forgotten? 9.2 is out already and I'm collecting > fixes for it... Ping #2? It's a 10.0.1 time already.. :) Thanks, /mjt >> --- >> v5: new commit. >> --- >> target/i386/cpu.c | 6 ++++-- >> 1 file changed, 4 insertions(+), 2 deletions(-) >> >> diff --git a/target/i386/cpu.c b/target/i386/cpu.c >> index 3baa95481fbc..77c1233daa13 100644 >> --- a/target/i386/cpu.c >> +++ b/target/i386/cpu.c >> @@ -7711,8 +7711,10 @@ static bool x86_cpu_filter_features(X86CPU >> *cpu, bool verbose) >> env->avx10_version = version; >> have_filtered_features = true; >> } >> - } else if (env->avx10_version && prefix) { >> - warn_report("%s: avx10.%d.", prefix, env->avx10_version); >> + } else if (env->avx10_version) { >> + if (prefix) { >> + warn_report("%s: avx10.%d.", prefix, env->avx10_version); >> + } >> have_filtered_features = true; >> } > >
On Mon, May 12, 2025 at 12:35:35PM +0300, Michael Tokarev wrote: > Date: Mon, 12 May 2025 12:35:35 +0300 > From: Michael Tokarev <mjt@tls.msk.ru> > Subject: Re: [PATCH v5 01/11 for v9.2?] i386/cpu: Mark avx10_version > filtered when prefix is NULL > > On 21.12.2024 00:04, Michael Tokarev wrote: > > 06.11.2024 06:07, Zhao Liu wrote: > > > In x86_cpu_filter_features(), if host doesn't support AVX10, the > > > configured avx10_version should be marked as filtered regardless of > > > whether prefix is NULL or not. > > > > > > Check prefix before warn_report() instead of checking for > > > have_filtered_features. > > > > > > Cc: qemu-stable@nongnu.org > > > Fixes: commit bccfb846fd52 ("target/i386: add AVX10 feature and > > > AVX10 version property") > > > Signed-off-by: Zhao Liu <zhao1.liu@intel.com> > > > > Hi! > > > > Has this patch been forgotten? 9.2 is out already and I'm collecting > > fixes for it... > > Ping #2? It's a 10.0.1 time already.. :) > Hi Michael, I'm sorry, but now I think it is not necessary, since it doesn't affect the normal use of avx10. And I don't think anyone is actively setting the wrong avx10 version in a normal production environment ( even KVM only supports v1). Hope this helps and saves you the effort! Thanks, Zhao
diff --git a/target/i386/cpu.c b/target/i386/cpu.c index 3baa95481fbc..77c1233daa13 100644 --- a/target/i386/cpu.c +++ b/target/i386/cpu.c @@ -7711,8 +7711,10 @@ static bool x86_cpu_filter_features(X86CPU *cpu, bool verbose) env->avx10_version = version; have_filtered_features = true; } - } else if (env->avx10_version && prefix) { - warn_report("%s: avx10.%d.", prefix, env->avx10_version); + } else if (env->avx10_version) { + if (prefix) { + warn_report("%s: avx10.%d.", prefix, env->avx10_version); + } have_filtered_features = true; }
In x86_cpu_filter_features(), if host doesn't support AVX10, the configured avx10_version should be marked as filtered regardless of whether prefix is NULL or not. Check prefix before warn_report() instead of checking for have_filtered_features. Cc: qemu-stable@nongnu.org Fixes: commit bccfb846fd52 ("target/i386: add AVX10 feature and AVX10 version property") Signed-off-by: Zhao Liu <zhao1.liu@intel.com> --- v5: new commit. --- target/i386/cpu.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)