From mboxrd@z Thu Jan 1 00:00:00 1970 From: Olaf Hering Subject: Re: [PATCH] xentrace: dynamic tracebuffer size allocation Date: Sat, 5 Feb 2011 17:32:39 +0100 Message-ID: <20110205163239.GA26767@aepfle.de> References: <20110205140717.GA3224@aepfle.de> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Return-path: Content-Disposition: inline In-Reply-To: <20110205140717.GA3224@aepfle.de> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org On Sat, Feb 05, Olaf Hering wrote: > > Allocate tracebuffers dynamically, based on the requested buffer size. > Calculate t_info_size from requested t_buf size. > Fix allocation failure path, free pages without the spinlock. > The spinlock is not needed since tracing is not yet enabled. > Remove casts for rawbuf, it can be a void pointer since no math is done. > > Signed-off-by: Olaf Hering plus this change to fix a compile error after spinlock removal.. Index: xen-unstable.hg-4.1.22870/xen/common/trace.c =================================================================== --- xen-unstable.hg-4.1.22870.orig/xen/common/trace.c +++ xen-unstable.hg-4.1.22870/xen/common/trace.c @@ -185,7 +185,6 @@ static int alloc_trace_bufs(unsigned int */ for_each_online_cpu(cpu) { - int flags; void *rawbuf; struct t_buf *buf; @@ -243,7 +242,6 @@ static int alloc_trace_bufs(unsigned int out_dealloc: for_each_online_cpu(cpu) { - int flags; void *rawbuf; rawbuf = per_cpu(t_bufs, cpu);