summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2017-11-08 14:14:24 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2018-03-04 11:11:59 +0000
commita71e71f9c4d8c64fb27a03b5a048710c8aee01c1 (patch)
tree4d765c17b43ae22f374f57f0f5fab3c8d3f5ec5f
parent3cf1f1712dacfd39e5506b4743e5150bd5c65f18 (diff)
downloadpoky-a71e71f9c4d8c64fb27a03b5a048710c8aee01c1.tar.gz
oeqa/targetcontrol: Drop unused get_target_controller function
This funciton appears completely unused, drop it. (From OE-Core rev: 31ccc70c4ea58e3781ea14eb534e00e9e06e131a) (From OE-Core rev: 31b8991de32ce91af58eab183f283adcded737c2) Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster@mvista.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/lib/oeqa/targetcontrol.py29
1 files changed, 2 insertions, 27 deletions
diff --git a/meta/lib/oeqa/targetcontrol.py b/meta/lib/oeqa/targetcontrol.py
index 3255e3a5c6..e17c89552f 100644
--- a/meta/lib/oeqa/targetcontrol.py
+++ b/meta/lib/oeqa/targetcontrol.py
@@ -20,31 +20,6 @@ from abc import ABCMeta, abstractmethod
20 20
21logger = logging.getLogger('BitBake.QemuRunner') 21logger = logging.getLogger('BitBake.QemuRunner')
22 22
23def get_target_controller(d):
24 testtarget = d.getVar("TEST_TARGET")
25 # old, simple names
26 if testtarget == "qemu":
27 return QemuTarget(d)
28 elif testtarget == "simpleremote":
29 return SimpleRemoteTarget(d)
30 else:
31 # use the class name
32 try:
33 # is it a core class defined here?
34 controller = getattr(sys.modules[__name__], testtarget)
35 except AttributeError:
36 # nope, perhaps a layer defined one
37 try:
38 bbpath = d.getVar("BBPATH").split(':')
39 testtargetloader = TestTargetLoader()
40 controller = testtargetloader.get_controller_module(testtarget, bbpath)
41 except ImportError as e:
42 bb.fatal("Failed to import {0} from available controller modules:\n{1}".format(testtarget,traceback.format_exc()))
43 except AttributeError as e:
44 bb.fatal("Invalid TEST_TARGET - " + str(e))
45 return controller(d)
46
47
48class BaseTarget(object, metaclass=ABCMeta): 23class BaseTarget(object, metaclass=ABCMeta):
49 24
50 supported_image_fstypes = [] 25 supported_image_fstypes = []
@@ -115,9 +90,9 @@ class QemuTarget(BaseTarget):
115 90
116 supported_image_fstypes = ['ext3', 'ext4', 'cpio.gz', 'wic'] 91 supported_image_fstypes = ['ext3', 'ext4', 'cpio.gz', 'wic']
117 92
118 def __init__(self, d, image_fstype=None): 93 def __init__(self, d, image_fstype=None, logger=None):
119 94
120 super(QemuTarget, self).__init__(d) 95 super(QemuTarget, self).__init__(d, logger)
121 96
122 self.rootfs = '' 97 self.rootfs = ''
123 self.kernel = '' 98 self.kernel = ''