From patchwork Thu Nov 17 17:35:48 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Cedric Bosdonnat X-Patchwork-Id: 9434829 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 A0C706047D for ; Thu, 17 Nov 2016 17:38:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 93F8920499 for ; Thu, 17 Nov 2016 17:38:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 88E0729687; Thu, 17 Nov 2016 17:38:57 +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 35DB620499 for ; Thu, 17 Nov 2016 17:38:57 +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 1c7Qc0-0008Dh-9H; Thu, 17 Nov 2016 17:36:36 +0000 Received: from mail6.bemta6.messagelabs.com ([193.109.254.103]) by lists.xenproject.org with esmtp (Exim 4.84_2) (envelope-from ) id 1c7Qby-0008Cc-Qj for xen-devel@lists.xen.org; Thu, 17 Nov 2016 17:36:34 +0000 Received: from [193.109.254.147] by server-8.bemta-6.messagelabs.com id D2/06-20944-2AAED285; Thu, 17 Nov 2016 17:36:34 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFupjkeJIrShJLcpLzFFi42I53H6XVXfhK90 Ig2tfxC2WfFzM4sDocXT3b6YAxijWzLyk/IoE1owTb18xFzQLVBx8MJmpgXELdxcjF4eQwBJG iefrFjN2MXJysAnYS3T9OcoEYosISEtc+3wZLM4sUCKx92kHmC0s4C/x4tFiFhCbRUBVovn1B yCbg4NXwFyi/5sdSFhCQF7iwtVTYCWcAhYSBw6fYwaxhYBK3rxZADaeV0BQ4uTMJ2CtzALqEu vnCUFskpdo3jqbeQIj7ywkVbMQqmYhqVrAyLyKUb04tagstUjXSC+pKDM9oyQ3MTNH19DATC8 3tbg4MT01JzGpWC85P3cTIzCcGIBgB+Oyv06HGCU5mJREeZlf6kYI8SXlp1RmJBZnxBeV5qQW H2KU4eBQkuAtAMkJFqWmp1akZeYAAxsmLcHBoyTCKwmS5i0uSMwtzkyHSJ1iVJQS5w0DSQiAJ DJK8+DaYNF0iVFWSpiXEegQIZ6C1KLczBJU+VeM4hyMSsK8i0Cm8GTmlcBNfwW0mAlo8R4BHZ DFJYkIKakGRjf/0o0tNwojr7ofbZnSurSo0Wxn076F8RWPNLf55XwvK7y8lOuM12XXJa7KjMy b7zAV7e2Nt0mWmrKR/f/rkKN31v59l6Ff8W11Jq/mYpulMl6f14e/+mSl1eH62NnD7ZJAoRrb 7XlbdP9Yz1wtECibd7nvyDqJm0su85YuzriV+qn7X+xaHiWW4oxEQy3mouJEAHnQpnGhAgAA X-Env-Sender: cbosdonnat@suse.com X-Msg-Ref: server-16.tower-27.messagelabs.com!1479404192!72115655!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 19305 invoked from network); 17 Nov 2016 17:36:33 -0000 Received: from smtp.nue.novell.com (HELO smtp.nue.novell.com) (195.135.221.5) by server-16.tower-27.messagelabs.com with DHE-RSA-AES256-GCM-SHA384 encrypted SMTP; 17 Nov 2016 17:36:33 -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); Thu, 17 Nov 2016 18:36:31 +0100 From: =?UTF-8?q?C=C3=A9dric=20Bosdonnat?= To: xen-devel@lists.xen.org Date: Thu, 17 Nov 2016 18:35:48 +0100 Message-Id: <20161117173617.6697-7-cbosdonnat@suse.com> X-Mailer: git-send-email 2.10.1 In-Reply-To: <20161117173617.6697-1-cbosdonnat@suse.com> References: <20161117173617.6697-1-cbosdonnat@suse.com> MIME-Version: 1.0 Cc: Wei Liu , Ian Jackson , 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 --- 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; }