<div dir="ltr"><div class="gmail_default" style="font-size:small">merged.</div><div class="gmail_default" style="font-size:small"><br></div><div class="gmail_default" style="font-size:small">Bruce</div></div><br><div class="gmail_quote"><div dir="ltr">On Mon, Nov 26, 2018 at 9:22 PM Hongzhi.Song <<a href="mailto:hongzhi.song@windriver.com">hongzhi.song@windriver.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">When CRIU is called for a first time and the /run/criu.kdat file does<br>
not exists, the following warning is shown:<br>
        Warn  (criu/kerndat.c:847): Can't load /run/criu.kdat<br>
<br>
This patch is replacing this warning with a more appropriate debug<br>
message.<br>
        File /run/criu.kdat does not exist<br>
<br>
Signed-off-by: Hongzhi.Song <<a href="mailto:hongzhi.song@windriver.com" target="_blank">hongzhi.song@windriver.com</a>><br>
---<br>
 recipes-containers/criu/<a href="http://criu_git.bb" rel="noreferrer" target="_blank">criu_git.bb</a>                |  1 +<br>
 ...on-t-open-run-criu.kdat-if-doesn-t-exists.patch | 42 ++++++++++++++++++++++<br>
 2 files changed, 43 insertions(+)<br>
 create mode 100644 recipes-containers/criu/files/0001-kdat-Don-t-open-run-criu.kdat-if-doesn-t-exists.patch<br>
<br>
diff --git a/recipes-containers/criu/<a href="http://criu_git.bb" rel="noreferrer" target="_blank">criu_git.bb</a> b/recipes-containers/criu/<a href="http://criu_git.bb" rel="noreferrer" target="_blank">criu_git.bb</a><br>
index 00de417..45195ea 100644<br>
--- a/recipes-containers/criu/<a href="http://criu_git.bb" rel="noreferrer" target="_blank">criu_git.bb</a><br>
+++ b/recipes-containers/criu/<a href="http://criu_git.bb" rel="noreferrer" target="_blank">criu_git.bb</a><br>
@@ -21,6 +21,7 @@ SRC_URI = "git://<a href="http://github.com/xemul/criu.git;protocol=git" rel="noreferrer" target="_blank">github.com/xemul/criu.git;protocol=git</a> \<br>
            file://0002-criu-Skip-documentation-install.patch \<br>
            file://0001-criu-Change-libraries-install-directory.patch \<br>
            file://lib-Makefile-overwrite-install-lib-to-allow-multiarc.patch \<br>
+           file://0001-kdat-Don-t-open-run-criu.kdat-if-doesn-t-exists.patch \<br>
           "<br>
<br>
 COMPATIBLE_HOST = "(x86_64|arm|aarch64).*-linux"<br>
diff --git a/recipes-containers/criu/files/0001-kdat-Don-t-open-run-criu.kdat-if-doesn-t-exists.patch b/recipes-containers/criu/files/0001-kdat-Don-t-open-run-criu.kdat-if-doesn-t-exists.patch<br>
new file mode 100644<br>
index 0000000..805f799<br>
--- /dev/null<br>
+++ b/recipes-containers/criu/files/0001-kdat-Don-t-open-run-criu.kdat-if-doesn-t-exists.patch<br>
@@ -0,0 +1,42 @@<br>
+From b9760919eb3f805dd3d2af5692b49cba9c468595 Mon Sep 17 00:00:00 2001<br>
+From: "Hongzhi.Song" <<a href="mailto:hongzhi.song@windriver.com" target="_blank">hongzhi.song@windriver.com</a>><br>
+Date: Mon, 26 Nov 2018 02:39:59 -0500<br>
+Subject: [PATCH] kdat: Don't open /run/criu.kdat if doesn't exists<br>
+<br>
+When CRIU is called for a first time and the /run/criu.kdat file does<br>
+not exists, the following warning is shown:<br>
+       Warn  (criu/kerndat.c:847): Can't load /run/criu.kdat<br>
+<br>
+This patch is replacing this warning with a more appropriate debug<br>
+message.<br>
+       File /run/criu.kdat does not exist<br>
+<br>
+Signed-off-by: Radostin Stoyanov <<a href="mailto:rstoyanov1@gmail.com" target="_blank">rstoyanov1@gmail.com</a>><br>
+Signed-off-by: Andrei Vagin <<a href="mailto:avagin@virtuozzo.com" target="_blank">avagin@virtuozzo.com</a>><br>
+<br>
+Upstream-Status: Backport [<a href="https://github.com/checkpoint-restore/criu/commit/868de91a099c00f099d8a41557d660d173f72521" rel="noreferrer" target="_blank">https://github.com/checkpoint-restore/criu/commit/868de91a099c00f099d8a41557d660d173f72521</a>]<br>
+<br>
+Signed-off-by: Hongzhi.Song <<a href="mailto:hongzhi.song@windriver.com" target="_blank">hongzhi.song@windriver.com</a>><br>
+---<br>
+ criu/kerndat.c | 5 ++++-<br>
+ 1 file changed, 4 insertions(+), 1 deletion(-)<br>
+<br>
+diff --git a/criu/kerndat.c b/criu/kerndat.c<br>
+index 8cb5690..9fb475c 100644<br>
+--- a/criu/kerndat.c<br>
++++ b/criu/kerndat.c<br>
+@@ -789,7 +789,10 @@ static int kerndat_try_load_cache(void)<br>
+ <br>
+       fd = open(KERNDAT_CACHE_FILE, O_RDONLY);<br>
+       if (fd < 0) {<br>
+-              pr_warn("Can't load %s\n", KERNDAT_CACHE_FILE);<br>
++              if(ENOENT == errno)<br>
++                      pr_debug("File %s does not exist\n", KERNDAT_CACHE_FILE);<br>
++              else<br>
++                      pr_warn("Can't load %s\n", KERNDAT_CACHE_FILE);<br>
+               return 1;<br>
+       }<br>
+ <br>
+-- <br>
+2.8.1<br>
+<br>
-- <br>
2.8.1<br>
<br>
-- <br>
_______________________________________________<br>
meta-virtualization mailing list<br>
<a href="mailto:meta-virtualization@yoctoproject.org" target="_blank">meta-virtualization@yoctoproject.org</a><br>
<a href="https://lists.yoctoproject.org/listinfo/meta-virtualization" rel="noreferrer" target="_blank">https://lists.yoctoproject.org/listinfo/meta-virtualization</a><br>
</blockquote></div><br clear="all"><div><br></div>-- <br><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">- Thou shalt not follow the NULL pointer, for chaos and madness await thee at its end<br>- "Use the force Harry" - Gandalf, Star Trek II<br><br></div>