aboutsummaryrefslogtreecommitdiffstats
path: root/xen/common/trace.c
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2009-07-13 11:32:41 +0100
committerKeir Fraser <keir.fraser@citrix.com>2009-07-13 11:32:41 +0100
commitcfbf17ffbb03e8c8501cae1bbba5459450b3447c (patch)
treecf2e5b34ce9149243688329505ecea8e68c7eb1f /xen/common/trace.c
parent749182393c49818b03172986aa2ba6afe3615c5d (diff)
downloadxen-cfbf17ffbb03e8c8501cae1bbba5459450b3447c.tar.gz
xen-cfbf17ffbb03e8c8501cae1bbba5459450b3447c.tar.bz2
xen-cfbf17ffbb03e8c8501cae1bbba5459450b3447c.zip
Introduce and use a per-CPU read-mostly sub-section
Since mixing data that only gets setup once and then (perhaps frequently) gets read by remote CPUs with data that the local CPU may modify (again, perhaps frequently) still causes undesirable cache protocol related bus traffic, separate the former class of objects from the latter. These objects converted here are just picked based on their write-once (or write-very-rarely) properties; perhaps some more adjustments may be desirable subsequently. The primary users of the new sub-section will result from the next patch. Signed-off-by: Jan Beulich <jbeulich@novell.com>
Diffstat (limited to 'xen/common/trace.c')
-rw-r--r--xen/common/trace.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/xen/common/trace.c b/xen/common/trace.c
index 38113d21df..594a3d68a0 100644
--- a/xen/common/trace.c
+++ b/xen/common/trace.c
@@ -46,8 +46,8 @@ static unsigned int opt_tbuf_size = 0;
integer_param("tbuf_size", opt_tbuf_size);
/* Pointers to the meta-data objects for all system trace buffers */
-static DEFINE_PER_CPU(struct t_buf *, t_bufs);
-static DEFINE_PER_CPU(unsigned char *, t_data);
+static DEFINE_PER_CPU_READ_MOSTLY(struct t_buf *, t_bufs);
+static DEFINE_PER_CPU_READ_MOSTLY(unsigned char *, t_data);
static int data_size;
/* High water mark for trace buffers; */