summaryrefslogtreecommitdiffstats
path: root/meta
diff options
context:
space:
mode:
authorRichard Purdie <richard.purdie@linuxfoundation.org>2023-01-26 17:06:31 +0000
committerRichard Purdie <richard.purdie@linuxfoundation.org>2023-01-26 21:57:07 +0000
commitc15c59c88d229e35eeac1ed948c84168633e7cb1 (patch)
tree9f224d7b9f500fb81daa1acea0fadf2ea1590d49 /meta
parentf9a5f9fdb69bb61242dc65ed83704f727491ecca (diff)
downloadopenembedded-core-c15c59c88d229e35eeac1ed948c84168633e7cb1.tar.gz
oeqa/selftest/devtool: Fix for linux 6.1 versions onwards
In recent kernel versions the string "Linux" moved to a header, 'include/linux/uts.h' instead of init/version.c. Allow the test to work with both situations. Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta')
-rw-r--r--meta/lib/oeqa/selftest/cases/devtool.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/meta/lib/oeqa/selftest/cases/devtool.py b/meta/lib/oeqa/selftest/cases/devtool.py
index c78a68be5b..86014d2557 100644
--- a/meta/lib/oeqa/selftest/cases/devtool.py
+++ b/meta/lib/oeqa/selftest/cases/devtool.py
@@ -2040,7 +2040,9 @@ class DevtoolUpgradeTests(DevtoolBase):
#Modify the kernel source
modfile = os.path.join(tempdir, 'init/version.c')
- runCmd("sed -i 's/Linux/LiNuX/g' %s" % (modfile))
+ # Moved to uts.h in 6.1 onwards
+ modfile2 = os.path.join(tempdir, 'include/linux/uts.h')
+ runCmd("sed -i 's/Linux/LiNuX/g' %s %s" % (modfile, modfile2))
#Modify the configuration
codeconfigfile = os.path.join(tempdir, '.config.new')