From patchwork Fri Dec 2 15:08:12 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Cedric Bosdonnat X-Patchwork-Id: 9458707 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CC47360236 for ; Fri, 2 Dec 2016 15:11:29 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BF76C2847C for ; Fri, 2 Dec 2016 15:11:29 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B44D72855C; Fri, 2 Dec 2016 15:11:29 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-4.2 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 705412847C for ; Fri, 2 Dec 2016 15:11:29 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cCpSa-0002wi-Tj; Fri, 02 Dec 2016 15:09:12 +0000 Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cCpSa-0002va-B3 for xen-devel@lists.xen.org; Fri, 02 Dec 2016 15:09:12 +0000 Received: from [85.158.139.211] by server-15.bemta-5.messagelabs.com id 14/45-13537-79E81485; Fri, 02 Dec 2016 15:09:11 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFprAIsWRWlGSWpSXmKPExsVyuP0uq+70Psc Ig4u3mC2WfFzM4sDocXT3b6YAxijWzLyk/IoE1oxHi28xF6wWqDh+fz57A+MN7i5GLg4hgSWM Ejd3n2PqYuTkYBOwl+j6cxTMFhGQlrj2+TIjiM0sUCLRdK6TGcQWFvCXePFoMQuIzSKgKnFx4 g92EJtXwELiQP9zVhBbQkBeYuH5I2BzOAUsJR60XAebIwRU03zjDgtEvaDEyZlPgGwOoPnqEu vnCUGskpdo3jqbeQIj7ywkVbMQqmYhqVrAyLyKUaM4tagstUjXyEIvqSgzPaMkNzEzR9fQwFQ vN7W4ODE9NScxqVgvOT93EyMwpOoZGBh3MPat8jvEKMnBpCTKa5rjGCHEl5SfUpmRWJwRX1Sa k1p8iFGGg0NJgre5FygnWJSanlqRlpkDDG6YtAQHj5IIrypImre4IDG3ODMdInWKUVFKnPcIS EIAJJFRmgfXBouoS4yyUsK8jAwMDEI8BalFuZklqPKvGMU5GJWEefeBTOHJzCuBm/4KaDET0O KO6/Ygi0sSEVJSDYzMLdd6/7ac2c9+7OKZz5/uqhxuZTsWufD7Ovb9Z7j3d1jl7gjoLJlqcL6 5I8LF6JBfXWqBvdDhprxts+cpaAQ9vXHla2vF5ocX//Hdu9yVkFL9dqLBGkuBxTN0/jTVFRhK 7m5Q/Lfh6iV2PfW3aw0yTqw1bTy2Mi092EhzsQbfTMlzxmGnghmVWIozEg21mIuKEwHU/hfwo wIAAA== X-Env-Sender: cbosdonnat@suse.com X-Msg-Ref: server-3.tower-206.messagelabs.com!1480691349!69846464!1 X-Originating-IP: [195.135.221.5] X-SpamReason: No, hits=0.5 required=7.0 tests=BODY_RANDOM_LONG X-StarScan-Received: X-StarScan-Version: 9.0.16; banners=-,-,- X-VirusChecked: Checked Received: (qmail 48048 invoked from network); 2 Dec 2016 15:09:09 -0000 Received: from smtp.nue.novell.com (HELO smtp.nue.novell.com) (195.135.221.5) by server-3.tower-206.messagelabs.com with DHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 2 Dec 2016 15:09:09 -0000 Received: from laptop.vms (mhy71-2-88-167-63-197.fbx.proxad.net [88.167.63.197]) by smtp.nue.novell.com with ESMTP (TLS encrypted); Fri, 02 Dec 2016 16:09:09 +0100 From: =?UTF-8?q?C=C3=A9dric=20Bosdonnat?= To: xen-devel@lists.xen.org Date: Fri, 2 Dec 2016 16:08:12 +0100 Message-Id: <20161202150841.31227-7-cbosdonnat@suse.com> X-Mailer: git-send-email 2.10.2 In-Reply-To: <20161202150841.31227-1-cbosdonnat@suse.com> References: <20161202150841.31227-1-cbosdonnat@suse.com> MIME-Version: 1.0 Cc: Ian Jackson , Wei Liu , Cedric Bosdonnat Subject: [Xen-devel] [PATCH v2 06/35] libxl/libxl_checkpoint_device.c: used LOG*D functions X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Virus-Scanned: ClamAV using ClamSMTP From: Cedric Bosdonnat Use LOG*D logging functions where possible instead of the LOG* ones. Signed-off-by: Cédric Bosdonnat Acked-by: Wei Liu --- tools/libxl/libxl_checkpoint_device.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/tools/libxl/libxl_checkpoint_device.c b/tools/libxl/libxl_checkpoint_device.c index 0a16dbb..01e74b5 100644 --- a/tools/libxl/libxl_checkpoint_device.c +++ b/tools/libxl/libxl_checkpoint_device.c @@ -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; }