diff options
| author | Hongzhi.Song <hongzhi.song@windriver.com> | 2019-01-17 01:44:15 -0800 |
|---|---|---|
| committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-01-18 16:24:40 +0000 |
| commit | 90206d9ece648df00dc8cfcd7c4b80c30dd39c1c (patch) | |
| tree | 66f912f17d7c1ce93dc547a3af76166c3c2e7d10 | |
| parent | 0f74cc32b7c7e9ae7a4b007ca5c43f5686745c4d (diff) | |
| download | poky-90206d9ece648df00dc8cfcd7c4b80c30dd39c1c.tar.gz | |
oeqa/runtime/ksample.py: skip kprobe case except x86 and powerpc
A new commit was introduced to kernel, which caused kprobe sample case
failed on arm.
[kernel commit: e46daee53bb50b, ARM: 8806/1: kprobes: Fix false positive
with FORTIFY_SOURCE]
And according to author, the case just works on x86 and powerpc.
So we just promise that the case can pass on x86 and powerpc.
(From OE-Core rev: 1a5b14bc3fe29618beea016ab2b32f55c19dd6ad)
Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
| -rw-r--r-- | meta/lib/oeqa/runtime/cases/ksample.py | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/meta/lib/oeqa/runtime/cases/ksample.py b/meta/lib/oeqa/runtime/cases/ksample.py index 354cc97673..584d0fb5e4 100644 --- a/meta/lib/oeqa/runtime/cases/ksample.py +++ b/meta/lib/oeqa/runtime/cases/ksample.py | |||
| @@ -22,6 +22,12 @@ class KSample(OERuntimeTestCase): | |||
| 22 | self.assertTrue(result, msg) | 22 | self.assertTrue(result, msg) |
| 23 | self.assertEqual(status, 0, cmd) | 23 | self.assertEqual(status, 0, cmd) |
| 24 | 24 | ||
| 25 | def check_arch(self, archset=''): | ||
| 26 | status, output = self.target.run("uname -m") | ||
| 27 | result = ("%s" % output) in archset | ||
| 28 | if not result: | ||
| 29 | self.skipTest("This case doesn't support %s" % output) | ||
| 30 | |||
| 25 | def check_config(self, config_opt=''): | 31 | def check_config(self, config_opt=''): |
| 26 | cmd = "zcat /proc/config.gz | grep %s" % config_opt | 32 | cmd = "zcat /proc/config.gz | grep %s" % config_opt |
| 27 | status, output = self.target.run(cmd) | 33 | status, output = self.target.run(cmd) |
| @@ -99,6 +105,7 @@ class KSampleTest(KSample): | |||
| 99 | # kprobe | 105 | # kprobe |
| 100 | @OETestDepends(['ssh.SSHTest.test_ssh']) | 106 | @OETestDepends(['ssh.SSHTest.test_ssh']) |
| 101 | def test_kprobe_test(self): | 107 | def test_kprobe_test(self): |
| 108 | self.check_arch("x86 ppc") | ||
| 102 | index = ["kprobe", "kretprobe"] | 109 | index = ["kprobe", "kretprobe"] |
| 103 | for i in index: | 110 | for i in index: |
| 104 | self.kprobe_func(i) | 111 | self.kprobe_func(i) |
