]> xenbits.xensource.com Git - xen.git/commitdiff
libxl/libxl_checkpoint_device.c: used LOG*D functions
authorCedric Bosdonnat <cbosdonnat@suse.com>
Fri, 2 Dec 2016 15:08:12 +0000 (16:08 +0100)
committerWei Liu <wei.liu2@citrix.com>
Sat, 3 Dec 2016 15:57:33 +0000 (15:57 +0000)
Use LOG*D logging functions where possible instead of the LOG* ones.

Signed-off-by: Cédric Bosdonnat <cbosdonnat@suse.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
tools/libxl/libxl_checkpoint_device.c

index 0a16dbb1564ae301293c129ded0893cb3a99d461..01e74b563aa329081230991f767445eedf172817 100644 (file)
@@ -132,7 +132,7 @@ static void device_setup_iterate(libxl__egc *egc, libxl__ao_device *aodev)
         if (!dev->ops) {
             libxl_device_nic * nic = NULL;
             libxl_device_disk * disk = NULL;
-            uint32_t domid;
+            uint32_t domid = INVALID_DOMID;
             int devid;
             if (dev->kind == LIBXL__DEVICE_KIND_VIF) {
                 nic = (libxl_device_nic *)dev->backend_dev;
@@ -143,15 +143,15 @@ static void device_setup_iterate(libxl__egc *egc, libxl__ao_device *aodev)
                 domid = disk->backend_domid;
                 devid = libxl__device_disk_dev_number(disk->vdev, NULL, NULL);
             } else {
-                LOG(ERROR,"device kind not handled by checkpoint: %s",
-                    libxl__device_kind_to_string(dev->kind));
+                LOGD(ERROR, domid, "device kind not handled by checkpoint: %s",
+                     libxl__device_kind_to_string(dev->kind));
                 aodev->rc = ERROR_FAIL;
                 goto out;
             }
-            LOG(ERROR,"device not handled by checkpoint"
-                " (device=%s:%"PRId32"/%"PRId32")",
-                libxl__device_kind_to_string(dev->kind),
-                domid, devid);
+            LOGD(ERROR, domid, "device not handled by checkpoint"
+                 " (device=%s:%"PRId32"/%"PRId32")",
+                 libxl__device_kind_to_string(dev->kind),
+                 domid, devid);
             aodev->rc = ERROR_CHECKPOINT_DEVICE_NOT_SUPPORTED;
             goto out;
         }