summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAwais Belal <awais_belal@mentor.com>2017-02-14 16:14:15 -0500
committerRichard Purdie <richard.purdie@linuxfoundation.org>2017-02-19 06:16:57 -0800
commit35a79cc495413f2cebe08e566f68ffef116cd6a3 (patch)
treec81ea0771d70c274874988f5fbdd0c35088c8d7b
parente98757e267389267d96778a1b443293eae12799e (diff)
downloadpoky-35a79cc495413f2cebe08e566f68ffef116cd6a3.tar.gz
kernel-yocto.bbclass: ensure repatching when HEAD is checked out
In some cases it is seen that kernel_checkout and validate_branches are run again in simultaneous builds. During do_patch the kgit-s2q mechanism looks for a sentinel file inside the .git directory, finds a fence post and starts picking up patches after that. This can create trouble as validate_branches checks out the HEAD of the branch and so the patches should be reapplied rather than skipped due to finding of the fence post. We can call kgit-s2q --clean to remove the sentinel file when the branches are checked out. (From OE-Core rev: d57aeafdd2b49010a9fa6d1cd9d10f3cfd5754a5) Signed-off-by: Awais Belal <awais_belal@mentor.com> Signed-off-by: Bruce Ashfield <bruce.ashfield@windriver.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
-rw-r--r--meta/classes/kernel-yocto.bbclass4
-rw-r--r--meta/recipes-kernel/kern-tools/kern-tools-native_git.bb2
2 files changed, 5 insertions, 1 deletions
diff --git a/meta/classes/kernel-yocto.bbclass b/meta/classes/kernel-yocto.bbclass
index a7b6356381..33361b9624 100644
--- a/meta/classes/kernel-yocto.bbclass
+++ b/meta/classes/kernel-yocto.bbclass
@@ -365,6 +365,10 @@ do_validate_branches() {
365 current_branch=`git rev-parse --abbrev-ref HEAD` 365 current_branch=`git rev-parse --abbrev-ref HEAD`
366 git branch "$current_branch-orig" 366 git branch "$current_branch-orig"
367 git reset --hard ${force_srcrev} 367 git reset --hard ${force_srcrev}
368 # We've checked out HEAD, make sure we cleanup kgit-s2q fence post check
369 # so the patches are applied as expected otherwise no patching
370 # would be done in some corner cases.
371 kgit-s2q --clean
368 fi 372 fi
369 fi 373 fi
370} 374}
diff --git a/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb b/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
index 4b1de5752c..03f8ce3cc2 100644
--- a/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
+++ b/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
@@ -4,7 +4,7 @@ LIC_FILES_CHKSUM = "file://git/tools/kgit;beginline=5;endline=9;md5=a6c2fa8aef1b
4 4
5DEPENDS = "git-native" 5DEPENDS = "git-native"
6 6
7SRCREV = "c14440d4e7ae0160c260ed65c3e123be5dc97ae8" 7SRCREV = "5deada879404820db146685729e89ba0887fc0ee"
8PR = "r12" 8PR = "r12"
9PV = "0.2+git${SRCPV}" 9PV = "0.2+git${SRCPV}"
10 10