From: Dario Faggioli Subject: [PATCH v2 16/16] xenalyze: handle DOM0 operaions events Date: Tue, 16 Feb 2016 19:13:31 +0100 Message-ID: <20160216181331.27876.31120.stgit@Solace.station> References: <20160216180550.27876.22680.stgit@Solace.station> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail6.bemta5.messagelabs.com ([195.245.231.135]) by lists.xen.org with esmtp (Exim 4.72) (envelope-from ) id 1aVk80-0004RS-Ea for xen-devel@lists.xenproject.org; Tue, 16 Feb 2016 18:13:36 +0000 Received: by mail-wm0-f65.google.com with SMTP id g62so21909898wme.2 for ; Tue, 16 Feb 2016 10:13:35 -0800 (PST) In-Reply-To: <20160216180550.27876.22680.stgit@Solace.station> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: xen-devel@lists.xenproject.org Cc: Olaf Hering , Wei Liu , Ian Campbell , George Dunlap , Ian Jackson List-Id: xen-devel@lists.xenproject.org (i.e., domain creation and destruction) so the trace will show properly decoded info, rather than just a bunch of hex codes. --- Cc: George Dunlap Cc: Ian Jackson Cc: Ian Campbell Cc: Wei Liu Cc: Olaf Hering Cc: Konrad Rzeszutek Wilk --- Changes from v1: * new patch in the series. --- tools/xentrace/xenalyze.c | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/tools/xentrace/xenalyze.c b/tools/xentrace/xenalyze.c index dd21229..267f932 100644 --- a/tools/xentrace/xenalyze.c +++ b/tools/xentrace/xenalyze.c @@ -8452,6 +8452,30 @@ void hw_process(struct pcpu_info *p) } } + +#define TRC_DOM0_SUB_DOMOPS 1 +void dom0_process(struct pcpu_info *p) +{ + struct record_info *ri = &p->ri; + + switch(ri->evt.sub) + { + case TRC_DOM0_SUB_DOMOPS: + if(opt.dump_all) { + struct { + unsigned int domid; + } *r = (typeof(r))ri->d; + + printf(" %s %s domain d%u\n", ri->dump_header, + ri->event == TRC_DOM0_DOM_ADD ? "creating" : "destroying", + r->domid); + } + break; + default: + process_generic(&p->ri); + } +} + /* ---- Base ----- */ void dump_generic(FILE * f, struct record_info *ri) { @@ -9288,6 +9312,8 @@ void process_record(struct pcpu_info *p) { hw_process(p); break; case TRC_DOM0OP_MAIN: + dom0_process(p); + break; default: process_generic(ri); }