From mboxrd@z Thu Jan 1 00:00:00 1970 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 From: Gerd Hoffmann 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> Subject: [Qemu-devel] [PATCH 5/9] qxl-logger: add timestamp to command log List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Alon Levy , Gerd Hoffmann 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)" : ""); -- 1.7.1