ia64/xen-unstable

view xen/include/public/trace.h @ 5704:9b73afea874e

Certain types of event channel are now auto-bound to vcpu0 by Xen.
Make sure that xenolinux agrees with this.
author sos22@douglas.cl.cam.ac.uk
date Fri Jul 08 15:35:43 2005 +0000 (2005-07-08)
parents fb0fa606f610
children ca873c2f5ca2 8799d14bef77 c589ca6d292b e3d811cca4e1
line source
1 /******************************************************************************
2 * include/public/trace.h
3 *
4 * Mark Williamson, (C) 2004 Intel Research Cambridge
5 * Copyright (C) 2005 Bin Ren
6 */
8 #ifndef __XEN_PUBLIC_TRACE_H__
9 #define __XEN_PUBLIC_TRACE_H__
11 /* Trace classes */
12 #define TRC_GEN 0x00010000 /* General trace */
13 #define TRC_SCHED 0x00020000 /* Xen Scheduler trace */
14 #define TRC_DOM0OP 0x00040000 /* Xen DOM0 operation trace */
15 #define TRC_VMX 0x00080000 /* Xen VMX trace */
16 #define TRC_ALL 0xffff0000
18 /* Trace events per class */
20 #define TRC_SCHED_DOM_ADD (TRC_SCHED + 1)
21 #define TRC_SCHED_DOM_REM (TRC_SCHED + 2)
22 #define TRC_SCHED_SLEEP (TRC_SCHED + 3)
23 #define TRC_SCHED_WAKE (TRC_SCHED + 4)
24 #define TRC_SCHED_YIELD (TRC_SCHED + 5)
25 #define TRC_SCHED_BLOCK (TRC_SCHED + 6)
26 #define TRC_SCHED_SHUTDOWN (TRC_SCHED + 7)
27 #define TRC_SCHED_CTL (TRC_SCHED + 8)
28 #define TRC_SCHED_ADJDOM (TRC_SCHED + 9)
29 #define TRC_SCHED_SWITCH (TRC_SCHED + 10)
30 #define TRC_SCHED_S_TIMER_FN (TRC_SCHED + 11)
31 #define TRC_SCHED_T_TIMER_FN (TRC_SCHED + 12)
32 #define TRC_SCHED_DOM_TIMER_FN (TRC_SCHED + 13)
34 #define TRC_VMX_VMEXIT (TRC_VMX + 1)
35 #define TRC_VMX_VECTOR (TRC_VMX + 2)
36 #define TRC_VMX_INT (TRC_VMX + 3)
38 /* This structure represents a single trace buffer record. */
39 struct t_rec {
40 u64 cycles; /* cycle counter timestamp */
41 u32 event; /* event ID */
42 unsigned long data[5]; /* event data items */
43 };
45 /*
46 * This structure contains the metadata for a single trace buffer. The head
47 * field, indexes into an array of struct t_rec's.
48 */
49 struct t_buf {
50 /* Used by both Xen and user space. */
51 atomic_t rec_idx; /* the next record to save to */
52 unsigned int rec_num; /* number of records in this trace buffer */
53 /* Used by Xen only. */
54 struct t_rec *rec; /* start of records */
55 /* Used by user space only. */
56 unsigned long rec_addr; /* machine address of the start of records */
57 };
59 #endif /* __XEN_PUBLIC_TRACE_H__ */