Re: [libvirt] [PATCH] tests: reintroduce tests for libxl's legacy nested setting
On 10/1/18 2:35 AM, Erik Skultety wrote: On Mon, Oct 01, 2018 at 08:04:57AM +0200, Erik Skultety wrote: On Thu, Sep 27, 2018 at 08:25:53AM -0600, Jim Fehlig wrote: On 9/27/18 3:29 AM, Erik Skultety wrote: On Wed, Sep 26, 2018 at 11:31:19AM -0600, Jim Fehlig wrote: The preferred location for setting the nested CPU flag changed in Xen 4.10 and is advertised via the LIBXL_HAVE_BUILDINFO_NESTED_HVM define. Commit 95d19cd0 changed libxl to use the new preferred location but unconditionally changed the tests, causing 'make check' failures against Xen < 4.10 that do not contain the new location. Commit e94415d5 fixed the failures by only running the tests when LIBXL_HAVE_BUILDINFO_NESTED_HVM is defined. Since libvirt supports several versions of Xen that use the old nested location, it is prudent to test the flag is set correctly. This patch reintroduces the tests for the legacy location of the nested setting. Signed-off-by: Jim Fehlig --- We could probably get by with one test for the old nested location, in which case I'd drop vnuma-hvm-legacy-nest. Any opinions on that? I verified with a few different platforms. I don't have a better idea on what to do about the legacy tests, we either add more (even identical) test files or we figure out some black magic to do the same thing (not preferred). Anyway, to answer your question, even though it might be enough, I'd like to stay consistent and keep both, so that if one day someone is looking at the source they don't wonder why only one of them is being run in the legacy mode. I hope that makes sense. Yep, no problem. Should I push now or after release? Ah, sorry, we definitely want this in the release, so safe for freeze. I went ahead and pushed the patch myself, since DV plans on doing the release at some point during the day which might already by too late for you because of a different timezone. Yep, I would have missed the release. Thanks for pushing it! Regards Jim -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH] tests: reintroduce tests for libxl's legacy nested setting
On Mon, Oct 01, 2018 at 08:04:57AM +0200, Erik Skultety wrote: > On Thu, Sep 27, 2018 at 08:25:53AM -0600, Jim Fehlig wrote: > > On 9/27/18 3:29 AM, Erik Skultety wrote: > > > On Wed, Sep 26, 2018 at 11:31:19AM -0600, Jim Fehlig wrote: > > > > The preferred location for setting the nested CPU flag changed in > > > > Xen 4.10 and is advertised via the LIBXL_HAVE_BUILDINFO_NESTED_HVM > > > > define. Commit 95d19cd0 changed libxl to use the new preferred > > > > location but unconditionally changed the tests, causing 'make check' > > > > failures against Xen < 4.10 that do not contain the new location. > > > > > > > > Commit e94415d5 fixed the failures by only running the tests when > > > > LIBXL_HAVE_BUILDINFO_NESTED_HVM is defined. Since libvirt supports > > > > several versions of Xen that use the old nested location, it is > > > > prudent to test the flag is set correctly. This patch reintroduces > > > > the tests for the legacy location of the nested setting. > > > > > > > > Signed-off-by: Jim Fehlig > > > > --- > > > > > > > > We could probably get by with one test for the old nested location, > > > > in which case I'd drop vnuma-hvm-legacy-nest. Any opinions on that? > > > > > > I verified with a few different platforms. I don't have a better idea on > > > what > > > to do about the legacy tests, we either add more (even identical) test > > > files > > > or we figure out some black magic to do the same thing (not preferred). > > > Anyway, to answer your question, even though it might be enough, I'd like > > > to > > > stay consistent and keep both, so that if one day someone is looking at > > > the > > > source they don't wonder why only one of them is being run in the legacy > > > mode. > > > I hope that makes sense. > > > > Yep, no problem. Should I push now or after release? > > Ah, sorry, we definitely want this in the release, so safe for freeze. I went ahead and pushed the patch myself, since DV plans on doing the release at some point during the day which might already by too late for you because of a different timezone. Erik -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH] tests: reintroduce tests for libxl's legacy nested setting
On Thu, Sep 27, 2018 at 08:25:53AM -0600, Jim Fehlig wrote: > On 9/27/18 3:29 AM, Erik Skultety wrote: > > On Wed, Sep 26, 2018 at 11:31:19AM -0600, Jim Fehlig wrote: > > > The preferred location for setting the nested CPU flag changed in > > > Xen 4.10 and is advertised via the LIBXL_HAVE_BUILDINFO_NESTED_HVM > > > define. Commit 95d19cd0 changed libxl to use the new preferred > > > location but unconditionally changed the tests, causing 'make check' > > > failures against Xen < 4.10 that do not contain the new location. > > > > > > Commit e94415d5 fixed the failures by only running the tests when > > > LIBXL_HAVE_BUILDINFO_NESTED_HVM is defined. Since libvirt supports > > > several versions of Xen that use the old nested location, it is > > > prudent to test the flag is set correctly. This patch reintroduces > > > the tests for the legacy location of the nested setting. > > > > > > Signed-off-by: Jim Fehlig > > > --- > > > > > > We could probably get by with one test for the old nested location, > > > in which case I'd drop vnuma-hvm-legacy-nest. Any opinions on that? > > > > I verified with a few different platforms. I don't have a better idea on > > what > > to do about the legacy tests, we either add more (even identical) test files > > or we figure out some black magic to do the same thing (not preferred). > > Anyway, to answer your question, even though it might be enough, I'd like to > > stay consistent and keep both, so that if one day someone is looking at the > > source they don't wonder why only one of them is being run in the legacy > > mode. > > I hope that makes sense. > > Yep, no problem. Should I push now or after release? Ah, sorry, we definitely want this in the release, so safe for freeze. Erik -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH] tests: reintroduce tests for libxl's legacy nested setting
On 9/27/18 3:29 AM, Erik Skultety wrote: On Wed, Sep 26, 2018 at 11:31:19AM -0600, Jim Fehlig wrote: The preferred location for setting the nested CPU flag changed in Xen 4.10 and is advertised via the LIBXL_HAVE_BUILDINFO_NESTED_HVM define. Commit 95d19cd0 changed libxl to use the new preferred location but unconditionally changed the tests, causing 'make check' failures against Xen < 4.10 that do not contain the new location. Commit e94415d5 fixed the failures by only running the tests when LIBXL_HAVE_BUILDINFO_NESTED_HVM is defined. Since libvirt supports several versions of Xen that use the old nested location, it is prudent to test the flag is set correctly. This patch reintroduces the tests for the legacy location of the nested setting. Signed-off-by: Jim Fehlig --- We could probably get by with one test for the old nested location, in which case I'd drop vnuma-hvm-legacy-nest. Any opinions on that? I verified with a few different platforms. I don't have a better idea on what to do about the legacy tests, we either add more (even identical) test files or we figure out some black magic to do the same thing (not preferred). Anyway, to answer your question, even though it might be enough, I'd like to stay consistent and keep both, so that if one day someone is looking at the source they don't wonder why only one of them is being run in the legacy mode. I hope that makes sense. Yep, no problem. Should I push now or after release? Regards, Jim -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
Re: [libvirt] [PATCH] tests: reintroduce tests for libxl's legacy nested setting
On Wed, Sep 26, 2018 at 11:31:19AM -0600, Jim Fehlig wrote: > The preferred location for setting the nested CPU flag changed in > Xen 4.10 and is advertised via the LIBXL_HAVE_BUILDINFO_NESTED_HVM > define. Commit 95d19cd0 changed libxl to use the new preferred > location but unconditionally changed the tests, causing 'make check' > failures against Xen < 4.10 that do not contain the new location. > > Commit e94415d5 fixed the failures by only running the tests when > LIBXL_HAVE_BUILDINFO_NESTED_HVM is defined. Since libvirt supports > several versions of Xen that use the old nested location, it is > prudent to test the flag is set correctly. This patch reintroduces > the tests for the legacy location of the nested setting. > > Signed-off-by: Jim Fehlig > --- > > We could probably get by with one test for the old nested location, > in which case I'd drop vnuma-hvm-legacy-nest. Any opinions on that? I verified with a few different platforms. I don't have a better idea on what to do about the legacy tests, we either add more (even identical) test files or we figure out some black magic to do the same thing (not preferred). Anyway, to answer your question, even though it might be enough, I'd like to stay consistent and keep both, so that if one day someone is looking at the source they don't wonder why only one of them is being run in the legacy mode. I hope that makes sense. Reviewed-by: Erik Skultety -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list
[libvirt] [PATCH] tests: reintroduce tests for libxl's legacy nested setting
The preferred location for setting the nested CPU flag changed in Xen 4.10 and is advertised via the LIBXL_HAVE_BUILDINFO_NESTED_HVM define. Commit 95d19cd0 changed libxl to use the new preferred location but unconditionally changed the tests, causing 'make check' failures against Xen < 4.10 that do not contain the new location. Commit e94415d5 fixed the failures by only running the tests when LIBXL_HAVE_BUILDINFO_NESTED_HVM is defined. Since libvirt supports several versions of Xen that use the old nested location, it is prudent to test the flag is set correctly. This patch reintroduces the tests for the legacy location of the nested setting. Signed-off-by: Jim Fehlig --- We could probably get by with one test for the old nested location, in which case I'd drop vnuma-hvm-legacy-nest. Any opinions on that? .../fullvirt-cpuid-legacy-nest.json | 60 ++ .../fullvirt-cpuid-legacy-nest.xml| 34 .../vnuma-hvm-legacy-nest.json| 178 ++ .../vnuma-hvm-legacy-nest.xml | 100 ++ tests/libxlxml2domconfigtest.c| 3 + 5 files changed, 375 insertions(+) diff --git a/tests/libxlxml2domconfigdata/fullvirt-cpuid-legacy-nest.json b/tests/libxlxml2domconfigdata/fullvirt-cpuid-legacy-nest.json new file mode 100644 index 00..cdc8b9867d --- /dev/null +++ b/tests/libxlxml2domconfigdata/fullvirt-cpuid-legacy-nest.json @@ -0,0 +1,60 @@ +{ +"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, +"shadow_memkb": 5656, +"cpuid": [ +{ +"leaf": 1, +"ecx": "xxx0", +"edx": "xxx1" +} +], +"sched_params": { +}, +"type.hvm": { +"pae": "True", +"apic": "True", +"acpi": "True", +"nested_hvm": "False", +"nographic": "True", +"vnc": { +"enable": "False" +}, +"sdl": { +"enable": "False" +}, +"spice": { + +}, +"boot": "c", +"rdm": { + +} +}, +"arch_arm": { + +} +}, +"disks": [ +{ +"pdev_path": "/dev/HostVG/XenGuest2", +"vdev": "hda", +"backend": "phy", +"format": "raw", +"removable": 1, +"readwrite": 1 +} +], +"on_reboot": "restart", +"on_crash": "restart" +} diff --git a/tests/libxlxml2domconfigdata/fullvirt-cpuid-legacy-nest.xml b/tests/libxlxml2domconfigdata/fullvirt-cpuid-legacy-nest.xml new file mode 100644 index 00..4f06db0714 --- /dev/null +++ b/tests/libxlxml2domconfigdata/fullvirt-cpuid-legacy-nest.xml @@ -0,0 +1,34 @@ + + XenGuest2 + c7a5fdb2-cdaf-9455-926a-d65c16db1809 + 592896 + 403456 + 1 + +hvm + + + + + + + + + + + + + destroy + restart + restart + + + + + + + + + + + diff --git a/tests/libxlxml2domconfigdata/vnuma-hvm-legacy-nest.json b/tests/libxlxml2domconfigdata/vnuma-hvm-legacy-nest.json new file mode 100644 index 00..3b2fc5f40f --- /dev/null +++ b/tests/libxlxml2domconfigdata/vnuma-hvm-legacy-nest.json @@ -0,0 +1,178 @@ +{ +"c_info": { +"type": "hvm", +"name": "test-hvm", +"uuid": "2147d599-9cc6-c0dc-92ab-4064b5446e9b" +}, +"b_info": { +"max_vcpus": 6, +"avail_vcpus": [ +0, +1, +2, +3, +4, +5 +], +"vnuma_nodes": [ +{ +"memkb": 2097152, +"distances": [ +10, +21, +31, +41, +51, +61 +], +"vcpus": [ +0 +] +}, +{ +"memkb": 2097152, +"distances": [ +21, +10, +21, +31, +41, +51 +], +"vcpus": [ +1 +] +}, +{ +"memkb": 2097152, +"distances": [ +31, +21, +10, +21, +31, +41 +], +"vcpus": [ +2 +] +}, +{ +