summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorAníbal Limón <anibal.limon@linux.intel.com>2017-05-26 15:37:43 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-06-02 13:36:14 +0100
commitadc434c0636b7dea2ef70c8d2c8e61cdb5c703b1 (patch)
tree85f864b0176b1556473f80174523f063d5dafc37 /meta
parenta4eef558c9933eb32413b61ff80a11b999951b40 (diff)
downloadpoky-adc434c0636b7dea2ef70c8d2c8e61cdb5c703b1.tar.gz
oeqa/sdk: Enable usage of OEQA thread mode
oeqa/sdk/context.py - Use OETestContextThreaded. classes/testsdk.bbclass - Enable bb event thread mode to avoid corrupt the PIPE when multiple threads writes. [YOCTO #11450] (From OE-Core rev: 598c6579932c2ca1dbdb022c8bec8af2e6c21e6b) Signed-off-by: Aníbal Limón <anibal.limon@linux.intel.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/classes/testsdk.bbclass4
-rw-r--r--meta/lib/oeqa/sdk/context.py5
2 files changed, 7 insertions, 2 deletions
diff --git a/meta/classes/testsdk.bbclass b/meta/classes/testsdk.bbclass
index edea89cbf4..8a9e680328 100644
--- a/meta/classes/testsdk.bbclass
+++ b/meta/classes/testsdk.bbclass
@@ -24,6 +24,8 @@ def testsdk_main(d):
24 from oeqa.sdk.context import OESDKTestContext, OESDKTestContextExecutor 24 from oeqa.sdk.context import OESDKTestContext, OESDKTestContextExecutor
25 from oeqa.utils import make_logger_bitbake_compatible 25 from oeqa.utils import make_logger_bitbake_compatible
26 26
27 bb.event.enable_threadlock()
28
27 pn = d.getVar("PN") 29 pn = d.getVar("PN")
28 logger = make_logger_bitbake_compatible(logging.getLogger("BitBake")) 30 logger = make_logger_bitbake_compatible(logging.getLogger("BitBake"))
29 31
@@ -97,6 +99,8 @@ def testsdkext_main(d):
97 from oeqa.utils import avoid_paths_in_environ, make_logger_bitbake_compatible, subprocesstweak 99 from oeqa.utils import avoid_paths_in_environ, make_logger_bitbake_compatible, subprocesstweak
98 from oeqa.sdkext.context import OESDKExtTestContext, OESDKExtTestContextExecutor 100 from oeqa.sdkext.context import OESDKExtTestContext, OESDKExtTestContextExecutor
99 101
102 bb.event.enable_threadlock()
103
100 pn = d.getVar("PN") 104 pn = d.getVar("PN")
101 logger = make_logger_bitbake_compatible(logging.getLogger("BitBake")) 105 logger = make_logger_bitbake_compatible(logging.getLogger("BitBake"))
102 106
diff --git a/meta/lib/oeqa/sdk/context.py b/meta/lib/oeqa/sdk/context.py
index 82e4c19bfc..b3d7c75183 100644
--- a/meta/lib/oeqa/sdk/context.py
+++ b/meta/lib/oeqa/sdk/context.py
@@ -6,9 +6,10 @@ import sys
6import glob 6import glob
7import re 7import re
8 8
9from oeqa.core.context import OETestContext, OETestContextExecutor 9from oeqa.core.context import OETestContextExecutor
10from oeqa.core.threaded import OETestContextThreaded
10 11
11class OESDKTestContext(OETestContext): 12class OESDKTestContext(OETestContextThreaded):
12 sdk_files_dir = os.path.join(os.path.dirname(os.path.abspath(__file__)), "files") 13 sdk_files_dir = os.path.join(os.path.dirname(os.path.abspath(__file__)), "files")
13 14
14 def __init__(self, td=None, logger=None, sdk_dir=None, sdk_env=None, 15 def __init__(self, td=None, logger=None, sdk_dir=None, sdk_env=None,