cpuid: add rhel64|qemu13 check_models test

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
---
v2:
  * rebased on top of tree where there is no subtests.cfg.example
  * s/kvm/qemu/ in pathnames and test config
  * Change some errors types to a more suitable ones
cpuid: add simplistic kernel that dumps cpuid to serial port

... and test utilities to parse its output

CPUID leaves are capped by reported level, xlevel, x2level values.

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
  v3:
    * dump CPUID(EAX=3), CPUID(EAX=4,ECX=3), CPUID(EAX={0xB, 0xC})
    * dump CPUID(EAX=0x80000007) and known paravirt cpuid leaves if
      detected
    * make target name specific to function cpuid_dump_kernel.bin,
      so we could later add another targets for other tests
  v2:
    * log cpuid dump on parsing failure
    * cap by reported level, xlevel, x2level
cpuid: add a series of default_vendor tests

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
v2:
    * remove rhelcpu models form qemu13 test
    * if vendor is missing use  host's vendor
    * remove no needed cpu_models list from kvm test
    * replace cpu_models with shorter ignore_cpu_models in rhel64.kvm.cpuid.default.vendor
    * fix typo
    * s/default_vendor/default.vendor/ in config so we could use
      cpuid.default selector for all default tests

default.vendor fix
cpuid: add custom_vendor test

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
v2:
    * s/TestFail/TestNAError/
    * s/custom_vendor/custom.vendor/ in config
cpuid: add custom_level test

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
v2:
    * s/TestFail/TestNAError/
    * s/custom_level/custom.level/ in config
cpuid: add custom_family test

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
v2:
    * s/TestFail/TestNAError/
    * s/custom_family/custom.family/ in config
cpuid: add custom_model test

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
v2:
   * s/TestFail/TestNAError/
   * s/custom_model/custom.model/ in config
cpuid: add custom_stepping test

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
v2:
   * s/TestFail/TestNAError/
   * s/custom_stepping/custom.stepping/ in config
cpuid: add custom_xlevel test

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
v2:
    * s/TestFail/TestNAError/
    * s/custom_xlevel/custom.xlevel/ in config
cpuid: add custom_model_id test

Signed-off-by: Igor Mammedov <imammedo@redhat.com>
---
v2:
    * s/TestFail/TestNAError/
    * s/custom_model_id/custom.model_id/ in config
qemu_cpu.cfg: remove duplication of settings

The duplication of settings makes it very hard to spot mistakes. This is
a new version of the config file that uses nesting and cartesian
products of variants to avoid duplication.

To make it easier to test wheter the changes are working, this generates
exactly the same dictionaries as the original config, in exactly the
same sequence, including all the bugs. Look for the #FIXME comments for
places that will be cleaned up or fixed later.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
qemu_cpu.cfg: clean up the vendor list on check_models

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
qemu_cpu.cfg: no need to have host-specific variants of default.vendor.kvm

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
qemu_cpu.cfg: remove ignore_cpu_models from default.vendor.qemu13.intel

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
qemu_cpu.cfg: there's no need for host-specific variants of default.vendor.nokvm.intel

The list of CPU models is the same on RHEL-6 and QEMU-1.3.

Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>