Re: [PATCH v1 2/9] target/i386: Hide Intel cache CPUID leaves for Hygon
Zhao Liu <[email protected]>
| Newsgroups | gmane.comp.emulators.qemu,gmane.comp.emulators.kvm.devel |
|---|---|
| Message-ID | <[email protected]> |
On Mon, Jul 06, 2026 at 01:55:23PM +0800, [email protected] wrote: > Date: Mon, 6 Jul 2026 13:55:23 +0800 > From: [email protected] > Subject: [PATCH v1 2/9] target/i386: Hide Intel cache CPUID leaves for Hygon > X-Mailer: git-send-email 2.43.7 > > From: Tina Zhang <[email protected]> > > When x-vendor-cpuid-only is enabled, QEMU suppresses CPUID leaves 2 > and 4 for AuthenticAMD CPUs because those leaves describe Intel cache > information. Hygon Dhyana uses the HygonGenuine vendor string, so it > currently skips that filtering and can expose Intel cache leaves together > with AMD/Hygon extended cache leaves. > > That is inconsistent guest-visible CPUID: Hygon Dhyana provides cache > information through the extended cache leaves, so it should not also > advertise the Intel cache descriptor and deterministic cache parameter > leaves. > > Apply the same leaf 2 and leaf 4 filtering to Hygon CPUs when Hygon > vendor ABI fixes are enabled. The property keeps the old CPUID output > for pc-11.0 and older machine types. > > Signed-off-by: Tina Zhang <[email protected]> > --- > target/i386/cpu.c | 19 +++++++++++++++++-- > 1 file changed, 17 insertions(+), 2 deletions(-) Reviewed-by: Zhao Liu <[email protected]>