From patchwork Wed Sep 21 15:42:28 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Llu=C3=ADs_Vilanova?= X-Patchwork-Id: 115797 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 4EA4DB6F8F for ; Thu, 22 Sep 2011 01:44:24 +1000 (EST) Received: from localhost ([::1]:35077 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6OyC-0002bG-Sm for incoming@patchwork.ozlabs.org; Wed, 21 Sep 2011 11:44:20 -0400 Received: from eggs.gnu.org ([140.186.70.92]:35383) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6Oy4-0002aL-2y for qemu-devel@nongnu.org; Wed, 21 Sep 2011 11:44:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R6Oy2-0006r8-Iq for qemu-devel@nongnu.org; Wed, 21 Sep 2011 11:44:11 -0400 Received: from gw.ac.upc.edu ([147.83.30.3]:54683) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R6Oy2-0006qw-AK for qemu-devel@nongnu.org; Wed, 21 Sep 2011 11:44:10 -0400 Received: from localhost (unknown [84.88.53.92]) by gw.ac.upc.edu (Postfix) with ESMTP id 66E096B0245; Wed, 21 Sep 2011 17:44:09 +0200 (CEST) To: qemu-devel@nongnu.org From: =?utf-8?b?TGx1w61z?= Vilanova Date: Wed, 21 Sep 2011 17:42:28 +0200 Message-ID: <20110921154228.27648.29185.stgit@ginnungagap.bsc.es> In-Reply-To: <20110921154221.27648.63402.stgit@ginnungagap.bsc.es> References: <20110921154221.27648.63402.stgit@ginnungagap.bsc.es> User-Agent: StGit/0.15 MIME-Version: 1.0 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 147.83.30.3 Cc: Jan Kiszka , Stefan Hajnoczi Subject: [Qemu-devel] [PATCH 2/3] trace: Add "vcpu_init" event 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 Signals the creation of a new vCPU (CPUState structure). Signed-off-by: LluĂ­s Vilanova --- cpus-user.c | 2 ++ cpus.c | 2 ++ trace-events | 7 +++++++ 3 files changed, 11 insertions(+), 0 deletions(-) diff --git a/cpus-user.c b/cpus-user.c index c1e5e58..5db48d2 100644 --- a/cpus-user.c +++ b/cpus-user.c @@ -1,8 +1,10 @@ /* Implementation of routines in "cpus.c" when compiling for CONFIG_USER_ONLY */ #include "qemu-common.h" +#include "trace.h" void qemu_init_vcpu(void *env) { + trace_vcpu_init(env); } diff --git a/cpus.c b/cpus.c index 8978779..00679ad 100644 --- a/cpus.c +++ b/cpus.c @@ -33,6 +33,7 @@ #include "qemu-thread.h" #include "cpus.h" +#include "trace.h" #ifndef _WIN32 #include "compatfd.h" @@ -856,6 +857,7 @@ void qemu_init_vcpu(void *_env) } else { qemu_tcg_init_vcpu(env); } + trace_vcpu_init(env); } void qemu_notify_event(void) diff --git a/trace-events b/trace-events index 658f0bc..cc59149 100644 --- a/trace-events +++ b/trace-events @@ -502,3 +502,10 @@ escc_sunkbd_event_in(int ch) "Untranslated keycode %2.2x" escc_sunkbd_event_out(int ch) "Translated keycode %2.2x" escc_kbd_command(int val) "Command %d" escc_sunmouse_event(int dx, int dy, int buttons_state) "dx=%d dy=%d buttons=%01x" + +### Abstract events (not specific to a file; keep at bottom) + +## vCPU + +# Create a new vCPU (CPUState structure) +vcpu_init(void *vcpu) "%p"