diff options
author | Robert Yang <liezhi.yang@windriver.com> | 2017-11-14 02:19:22 +0800 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2017-12-18 18:03:56 +0000 |
commit | 60ceabb92276ff182042c866b3e6e25fe9ff20d1 (patch) | |
tree | 56af10c767c2d82f9411db6d2e9823080e6183eb /meta/lib | |
parent | 7c99808915f8d00124648e23840bb41fbe93e964 (diff) | |
download | poky-60ceabb92276ff182042c866b3e6e25fe9ff20d1.tar.gz |
targetcontrol.py: use oe.types.boolean for QEMU_USE_KVM
So that both QEMU_USE_KVM = "True" and "1" will work.
[YOCTO #12343]
(From OE-Core rev: f28890ae2eb8a9cb2da39588e696a4b0c501bdf0)
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Ross Burton <ross.burton@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/lib')
-rw-r--r-- | meta/lib/oeqa/targetcontrol.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/meta/lib/oeqa/targetcontrol.py b/meta/lib/oeqa/targetcontrol.py index f63936c3ec..59a9c35a09 100644 --- a/meta/lib/oeqa/targetcontrol.py +++ b/meta/lib/oeqa/targetcontrol.py | |||
@@ -91,6 +91,8 @@ class QemuTarget(BaseTarget): | |||
91 | 91 | ||
92 | def __init__(self, d, logger, image_fstype=None): | 92 | def __init__(self, d, logger, image_fstype=None): |
93 | 93 | ||
94 | import oe.types | ||
95 | |||
94 | super(QemuTarget, self).__init__(d, logger) | 96 | super(QemuTarget, self).__init__(d, logger) |
95 | 97 | ||
96 | self.rootfs = '' | 98 | self.rootfs = '' |
@@ -107,7 +109,7 @@ class QemuTarget(BaseTarget): | |||
107 | dump_dir = d.getVar("TESTIMAGE_DUMP_DIR") | 109 | dump_dir = d.getVar("TESTIMAGE_DUMP_DIR") |
108 | qemu_use_kvm = d.getVar("QEMU_USE_KVM") | 110 | qemu_use_kvm = d.getVar("QEMU_USE_KVM") |
109 | if qemu_use_kvm and \ | 111 | if qemu_use_kvm and \ |
110 | (qemu_use_kvm == "True" and "x86" in d.getVar("MACHINE") or \ | 112 | (oe.types.boolean(qemu_use_kvm) and "x86" in d.getVar("MACHINE") or \ |
111 | d.getVar("MACHINE") in qemu_use_kvm.split()): | 113 | d.getVar("MACHINE") in qemu_use_kvm.split()): |
112 | use_kvm = True | 114 | use_kvm = True |
113 | else: | 115 | else: |