From patchwork Mon Jul 4 15:14:11 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gerd Hoffmann X-Patchwork-Id: 103118 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [140.186.70.17]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id 0FA52B6F57 for ; Tue, 5 Jul 2011 01:18:16 +1000 (EST) Received: from localhost ([::1]:60842 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qdkua-0008If-09 for incoming@patchwork.ozlabs.org; Mon, 04 Jul 2011 11:18:12 -0400 Received: from eggs.gnu.org ([140.186.70.92]:56887) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qdkqu-0008Hk-2k for qemu-devel@nongnu.org; Mon, 04 Jul 2011 11:14:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qdkqq-0006iV-2A for qemu-devel@nongnu.org; Mon, 04 Jul 2011 11:14:23 -0400 Received: from mx1.redhat.com ([209.132.183.28]:18530) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qdkqp-0006i9-7R for qemu-devel@nongnu.org; Mon, 04 Jul 2011 11:14:19 -0400 Received: from int-mx02.intmail.prod.int.phx2.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id p64FEIYm021078 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Mon, 4 Jul 2011 11:14:18 -0400 Received: from rincewind.home.kraxel.org (vpn1-7-218.ams2.redhat.com [10.36.7.218]) by int-mx02.intmail.prod.int.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id p64FEG1q022399; Mon, 4 Jul 2011 11:14:17 -0400 Received: by rincewind.home.kraxel.org (Postfix, from userid 500) id 3917C413BF; Mon, 4 Jul 2011 17:14:16 +0200 (CEST) From: Gerd Hoffmann To: qemu-devel@nongnu.org Date: Mon, 4 Jul 2011 17:14:11 +0200 Message-Id: <1309792455-26825-6-git-send-email-kraxel@redhat.com> In-Reply-To: <1309792455-26825-1-git-send-email-kraxel@redhat.com> References: <1309792455-26825-1-git-send-email-kraxel@redhat.com> X-Scanned-By: MIMEDefang 2.67 on 10.5.11.12 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 209.132.183.28 Cc: Alon Levy , Gerd Hoffmann Subject: [Qemu-devel] [PATCH 5/9] qxl-logger: add timestamp to command log X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org From: Alon Levy Signed-off-by: Gerd Hoffmann --- hw/qxl-logger.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/hw/qxl-logger.c b/hw/qxl-logger.c index 76f43e6..74cadba 100644 --- a/hw/qxl-logger.c +++ b/hw/qxl-logger.c @@ -19,6 +19,7 @@ * along with this program; if not, see . */ +#include "qemu-timer.h" #include "qxl.h" static const char *qxl_type[] = { @@ -223,7 +224,8 @@ void qxl_log_command(PCIQXLDevice *qxl, const char *ring, QXLCommandExt *ext) if (!qxl->cmdlog) { return; } - fprintf(stderr, "qxl-%d/%s:", qxl->id, ring); + fprintf(stderr, "%ld qxl-%d/%s:", qemu_get_clock_ns(vm_clock), + qxl->id, ring); fprintf(stderr, " cmd @ 0x%" PRIx64 " %s%s", ext->cmd.data, qxl_name(qxl_type, ext->cmd.type), compat ? "(compat)" : "");