diff options
author | Emmanuel Roullit <emmanuel.roullit@gmail.com> | 2018-09-05 21:49:58 +0200 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2018-09-13 07:42:27 +0100 |
commit | a8948584c1bfec41611596fa24a984ae503e9375 (patch) | |
tree | 94f2dbaa9ab6d824fae25e0eb941ba4db6ba40bc | |
parent | ae130de4ba287730d5f843019ecf8b8383b3741e (diff) | |
download | poky-a8948584c1bfec41611596fa24a984ae503e9375.tar.gz |
testimage.bbclass: fix qemu_use_kvm handling
QEMU_USE_KVM can either be a boolean or a whitespace separated list
of kvm supported machines.
For the 'intel-corei7-64' machine, defined in meta-intel, kvm could not be
used as the 'x86' substring is not part of its machine name.
By changing the order of this 'or' statement and setting
the 'QEMU_USE_KVM' variable to 'intel-corei7-64', it is possible to run the
'testimage' task with kvm support successfully.
(From OE-Core rev: a22789253aa653dc50fb159b40910248c2f98dd4)
Signed-off-by: Emmanuel Roullit <emmanuel.roullit@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r-- | meta/classes/testimage.bbclass | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/meta/classes/testimage.bbclass b/meta/classes/testimage.bbclass index 6fa901b6a6..39de191a73 100644 --- a/meta/classes/testimage.bbclass +++ b/meta/classes/testimage.bbclass | |||
@@ -221,8 +221,8 @@ def testimage_main(d): | |||
221 | # Get use_kvm | 221 | # Get use_kvm |
222 | qemu_use_kvm = d.getVar("QEMU_USE_KVM") | 222 | qemu_use_kvm = d.getVar("QEMU_USE_KVM") |
223 | if qemu_use_kvm and \ | 223 | if qemu_use_kvm and \ |
224 | (oe.types.boolean(qemu_use_kvm) and 'x86' in machine or \ | 224 | (d.getVar('MACHINE') in qemu_use_kvm.split() or \ |
225 | d.getVar('MACHINE') in qemu_use_kvm.split()): | 225 | oe.types.boolean(qemu_use_kvm) and 'x86' in machine): |
226 | kvm = True | 226 | kvm = True |
227 | else: | 227 | else: |
228 | kvm = False | 228 | kvm = False |