Re: [PATCH v6 7/9] tests: check CPU features handling in libxl driver

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Mar 22, 2018 at 10:03:50AM +0000, Daniel P. Berrangé wrote:
> On Wed, Mar 21, 2018 at 05:32:31PM +0100, Marek Marczykowski-Górecki wrote:
> > Test enabling/disabling individual CPU features and also setting
> > nested HVM support, which is also controlled by CPU features node.
> > 
> > Signed-off-by: Marek Marczykowski-Górecki <marmarek@xxxxxxxxxxxxxxxxxxxxxx>
> > Reviewed-by: Jim Fehlig <jfehlig@xxxxxxxx>
> > ---
> > Changes since v3:
> >  - adjust for modified nested HVM handling
> > Changes since v1:
> >  - rewritten to Jim's test suite for libxl_domain_config generator
> > ---
> >  tests/libxlxml2domconfigdata/fullvirt-cpuid.json | 64 +++++++++++++++++-
> >  tests/libxlxml2domconfigdata/fullvirt-cpuid.xml  | 37 ++++++++++-
> >  tests/libxlxml2domconfigtest.c                   |  1 +-
> >  3 files changed, 102 insertions(+)
> >  create mode 100644 tests/libxlxml2domconfigdata/fullvirt-cpuid.json
> >  create mode 100644 tests/libxlxml2domconfigdata/fullvirt-cpuid.xml
> > 
> > diff --git a/tests/libxlxml2domconfigdata/fullvirt-cpuid.json b/tests/libxlxml2domconfigdata/fullvirt-cpuid.json
> > new file mode 100644
> > index 0000000..28037be
> > --- /dev/null
> > +++ b/tests/libxlxml2domconfigdata/fullvirt-cpuid.json
> > @@ -0,0 +1,64 @@
> > +{
> > +    "c_info": {
> > +        "type": "hvm",
> > +        "name": "XenGuest2",
> > +        "uuid": "c7a5fdb2-cdaf-9455-926a-d65c16db1809"
> > +    },
> > +    "b_info": {
> > +        "max_vcpus": 1,
> > +        "avail_vcpus": [
> > +            0
> > +        ],
> > +        "max_memkb": 592896,
> > +        "target_memkb": 403456,
> > +        "video_memkb": 8192,
> > +        "shadow_memkb": 5656,
> > +        "cpuid": [
> > +            {
> > +                "leaf": 1,
> > +                "ecx": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx0",
> > +                "edx": "xxxxxxxxxxxxxxxxxxxxxxxxxxx1xxxx"
> 
> IIUC, this means we have 1 bit marked as forbidden and 1 bit
> marked as required but....
> 
> 
> > +  <cpu mode='host-passthrough'>
> > +    <feature policy='forbid' name='pni'/>
> > +    <feature policy='forbid' name='vmx'/>
> 
> 2 features marked forbidden

vmx is translated to nested_hvm setting.

> > +    <feature policy='require' name='tsc'/>
> 
> and 1 marked required.
> 
> IOW, shouldn't we have seen two 0 bits in the cpuid config above
> not just one ?
> 
> 
> Regards,
> Daniel

-- 
Best Regards,
Marek Marczykowski-Górecki
Invisible Things Lab
A: Because it messes up the order in which people normally read text.
Q: Why is top-posting such a bad thing?

Attachment: signature.asc
Description: PGP signature

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux