xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
From: "Cédric Bosdonnat" <cbosdonnat@suse.com>
To: xen-devel@lists.xen.org
Cc: "Cédric Bosdonnat" <cedric.bosdonnat@free.fr>,
	"Wei Liu" <wei.liu2@citrix.com>,
	"Ian Jackson" <ian.jackson@eu.citrix.com>,
	"Cédric Bosdonnat" <cbosdonnat@suse.com>
Subject: [PATCH 29/35] libxl/libxl_remus.c: used LOG*D functions
Date: Tue, 15 Nov 2016 11:19:07 +0100	[thread overview]
Message-ID: <20161115101913.10396-30-cbosdonnat@suse.com> (raw)
In-Reply-To: <20161115101913.10396-1-cbosdonnat@suse.com>

From: Cédric Bosdonnat <cedric.bosdonnat@free.fr>

Use LOG*D logging functions where possible instead of the LOG* ones.

Signed-off-by: Cédric Bosdonnat <cbosdonnat@suse.com>
---
 tools/libxl/libxl_remus.c | 27 ++++++++++++++-------------
 1 file changed, 14 insertions(+), 13 deletions(-)

diff --git a/tools/libxl/libxl_remus.c b/tools/libxl/libxl_remus.c
index 54ec7de..29a4783 100644
--- a/tools/libxl/libxl_remus.c
+++ b/tools/libxl/libxl_remus.c
@@ -84,7 +84,8 @@ void libxl__remus_setup(libxl__egc *egc, libxl__remus_state *rs)
 
     if (libxl_defbool_val(info->netbuf)) {
         if (!libxl__netbuffer_enabled(gc)) {
-            LOG(ERROR, "Remus: No support for network buffering");
+            LOGD(ERROR, dss->domid,
+                 "Remus: No support for network buffering");
             goto out;
         }
         cds->device_kind_flags |= (1 << LIBXL__DEVICE_KIND_VIF);
@@ -101,8 +102,8 @@ void libxl__remus_setup(libxl__egc *egc, libxl__remus_state *rs)
     rs->interval = info->interval;
 
     if (init_device_subkind(cds)) {
-        LOG(ERROR, "Remus: failed to init device subkind for guest %u",
-            dss->domid);
+        LOGD(ERROR, dss->domid,
+             "Remus: failed to init device subkind");
         goto out;
     }
 
@@ -130,8 +131,7 @@ static void remus_setup_done(libxl__egc *egc,
         return;
     }
 
-    LOG(ERROR, "Remus: failed to setup device for guest with domid %u, rc %d",
-        dss->domid, rc);
+    LOGD(ERROR, dss->domid, "Remus: failed to setup device, rc %d", rc);
     cds->callback = remus_setup_failed;
     libxl__checkpoint_devices_teardown(egc, cds);
 }
@@ -143,8 +143,8 @@ static void remus_setup_failed(libxl__egc *egc,
     STATE_AO_GC(dss->ao);
 
     if (rc)
-        LOG(ERROR, "Remus: failed to teardown device after setup failed"
-            " for guest with domid %u, rc %d", dss->domid, rc);
+        LOGD(ERROR, dss->domid,
+             "Remus: failed to teardown device after setup failed, rc %d", rc);
 
     cleanup_device_subkind(cds);
 
@@ -165,8 +165,8 @@ void libxl__remus_teardown(libxl__egc *egc,
 
     EGC_GC;
 
-    LOG(WARN, "Remus: Domain suspend terminated with rc %d,"
-        " teardown Remus devices...", rc);
+    LOGD(WARN, dss->domid, "Remus: Domain suspend terminated with rc %d,"
+         " teardown Remus devices...", rc);
     cds->callback = remus_teardown_done;
     libxl__checkpoint_devices_teardown(egc, cds);
 }
@@ -179,8 +179,8 @@ static void remus_teardown_done(libxl__egc *egc,
     STATE_AO_GC(dss->ao);
 
     if (rc)
-        LOG(ERROR, "Remus: failed to teardown device for guest with domid %u,"
-            " rc %d", dss->domid, rc);
+        LOGD(ERROR, dss->domid, "Remus: failed to teardown device,"
+            " rc %d", rc);
 
     cleanup_device_subkind(cds);
 
@@ -309,7 +309,8 @@ static void remus_checkpoint_stream_written(
     STATE_AO_GC(dss->ao);
 
     if (rc) {
-        LOG(ERROR, "Failed to save device model. Terminating Remus..");
+        LOGD(ERROR, dss->domid, "Failed to save device model."
+             " Terminating Remus..");
         goto out;
     }
 
@@ -331,7 +332,7 @@ static void remus_devices_commit_cb(libxl__egc *egc,
     STATE_AO_GC(dss->ao);
 
     if (rc) {
-        LOG(ERROR, "Failed to do device commit op."
+        LOGD(ERROR, dss->domid, "Failed to do device commit op."
             " Terminating Remus..");
         goto out;
     }
-- 
2.10.1


_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
https://lists.xen.org/xen-devel

  parent reply	other threads:[~2016-11-15 10:19 UTC|newest]

Thread overview: 47+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-11-15 10:18 [PATCH 00/35] libxl LOG*D functions Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 01/35] libxl: add LIBXL_LOGD_* and LOG*D function families Cédric Bosdonnat
2016-11-17 14:41   ` Wei Liu
2016-11-17 16:01     ` Cedric Bosdonnat
2016-11-17 16:12       ` Wei Liu
2016-11-17 16:29       ` Ian Jackson
2016-11-17 16:34         ` Wei Liu
2016-11-17 16:36           ` Ian Jackson
2016-11-17 16:38             ` Wei Liu
2016-11-15 10:18 ` [PATCH 02/35] libxl.c: switch to LOG*D use Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 03/35] libxl.c: switch to LOG*D use (refactored messages) Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 04/35] libxl.c: switch to LOG*D use Cédric Bosdonnat
2016-11-17 14:50   ` Wei Liu
2016-11-17 16:03     ` Cedric Bosdonnat
2016-11-17 16:15       ` Wei Liu
2016-11-17 16:30       ` Ian Jackson
2016-11-15 10:18 ` [PATCH 05/35] libxl/libxl_bootloader.c: used LOG*D functions Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 06/35] libxl/libxl_checkpoint_device.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 07/35] libxl/libxl_colo.h: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 08/35] libxl/libxl_colo_nic.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 09/35] libxl/libxl_colo_proxy.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 10/35] libxl/libxl_colo_qdisk.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 11/35] libxl/libxl_colo_restore.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 12/35] libxl/libxl_colo_save.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 13/35] libxl/libxl_create.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 14/35] libxl/libxl_device.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 15/35] libxl/libxl_dm.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 16/35] libxl/libxl_dom_save.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 17/35] libxl/libxl_dom_suspend.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 18/35] libxl/libxl_freebsd.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 19/35] libxl/libxl_internal.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 20/35] libxl/libxl_linux.c: " Cédric Bosdonnat
2016-11-15 10:18 ` [PATCH 21/35] libxl/libxl_netbsd.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 22/35] libxl/libxl_netbuffer.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 23/35] libxl/libxl_nic.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 24/35] libxl/libxl_no_colo.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 25/35] libxl/libxl_pci.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 26/35] libxl/libxl_psr.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 27/35] libxl/libxl_pvusb.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 28/35] libxl/libxl_qmp.c: " Cédric Bosdonnat
2016-11-15 10:19 ` Cédric Bosdonnat [this message]
2016-11-15 10:19 ` [PATCH 30/35] libxl/libxl_save_callout.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 31/35] libxl/libxl_stream_write.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 32/35] libxl/libxl_vnuma.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 33/35] libxl/libxl_vtpm.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 34/35] libxl/libxl_x86.c: " Cédric Bosdonnat
2016-11-15 10:19 ` [PATCH 35/35] libxl/libxl_xshelp.c: " Cédric Bosdonnat

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20161115101913.10396-30-cbosdonnat@suse.com \
    --to=cbosdonnat@suse.com \
    --cc=cedric.bosdonnat@free.fr \
    --cc=ian.jackson@eu.citrix.com \
    --cc=wei.liu2@citrix.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).