ia64/xen-unstable

view patches/linux-2.6.16.13/xenoprof-generic.patch @ 10596:a67c1bcb5522

Add Xenoprof passive domain support (missing file).
Signed-off-by: Yang Xiaowei <xiaowei.yang@intel.com>
Signed-off-by: Jose Renato Santos <jsantos@hpl.hp.com>
author kaf24@firebug.cl.cam.ac.uk
date Thu Jun 29 14:30:41 2006 +0100 (2006-06-29)
parents 23591d2c46aa
children b875c036839f
line source
1 diff -pru ../pristine-linux-2.6.16.13/drivers/oprofile/buffer_sync.c ./drivers/oprofile/buffer_sync.c
2 --- ../pristine-linux-2.6.16.13/drivers/oprofile/buffer_sync.c 2006-05-03 05:38:44.000000000 +0800
3 +++ ./drivers/oprofile/buffer_sync.c 2006-06-27 12:14:53.000000000 +0800
4 @@ -6,6 +6,10 @@
5 *
6 * @author John Levon <levon@movementarian.org>
7 *
8 + * Modified by Aravind Menon for Xen
9 + * These modifications are:
10 + * Copyright (C) 2005 Hewlett-Packard Co.
11 + *
12 * This is the core of the buffer management. Each
13 * CPU buffer is processed and entered into the
14 * global event buffer. Such processing is necessary
15 @@ -275,15 +279,30 @@ static void add_cpu_switch(int i)
16 last_cookie = INVALID_COOKIE;
17 }
19 -static void add_kernel_ctx_switch(unsigned int in_kernel)
20 +static void add_cpu_mode_switch(unsigned int cpu_mode)
21 {
22 add_event_entry(ESCAPE_CODE);
23 - if (in_kernel)
24 - add_event_entry(KERNEL_ENTER_SWITCH_CODE);
25 - else
26 - add_event_entry(KERNEL_EXIT_SWITCH_CODE);
27 + switch (cpu_mode) {
28 + case CPU_MODE_USER:
29 + add_event_entry(USER_ENTER_SWITCH_CODE);
30 + break;
31 + case CPU_MODE_KERNEL:
32 + add_event_entry(KERNEL_ENTER_SWITCH_CODE);
33 + break;
34 + case CPU_MODE_XEN:
35 + add_event_entry(XEN_ENTER_SWITCH_CODE);
36 + break;
37 + case CPU_MODE_PASSIVE_START:
38 + add_event_entry(PASSIVE_START_CODE);
39 + break;
40 + case CPU_MODE_PASSIVE_STOP:
41 + add_event_entry(PASSIVE_STOP_CODE);
42 + break;
43 + default:
44 + break;
45 + }
46 }
47 -
48 +
49 static void
50 add_user_ctx_switch(struct task_struct const * task, unsigned long cookie)
51 {
52 @@ -348,9 +367,9 @@ static int add_us_sample(struct mm_struc
53 * for later lookup from userspace.
54 */
55 static int
56 -add_sample(struct mm_struct * mm, struct op_sample * s, int in_kernel)
57 +add_sample(struct mm_struct * mm, struct op_sample * s, int cpu_mode)
58 {
59 - if (in_kernel) {
60 + if (cpu_mode >= CPU_MODE_KERNEL) {
61 add_sample_entry(s->eip, s->event);
62 return 1;
63 } else if (mm) {
64 @@ -496,10 +515,11 @@ void sync_buffer(int cpu)
65 struct mm_struct *mm = NULL;
66 struct task_struct * new;
67 unsigned long cookie = 0;
68 - int in_kernel = 1;
69 + int cpu_mode = 1;
70 unsigned int i;
71 sync_buffer_state state = sb_buffer_start;
72 unsigned long available;
73 + int domain_switch = NO_DOMAIN_SWITCH;
75 down(&buffer_sem);
77 @@ -513,12 +533,19 @@ void sync_buffer(int cpu)
78 struct op_sample * s = &cpu_buf->buffer[cpu_buf->tail_pos];
80 if (is_code(s->eip)) {
81 - if (s->event <= CPU_IS_KERNEL) {
82 + if (s->event < CPU_TRACE_BEGIN) {
83 /* kernel/userspace switch */
84 - in_kernel = s->event;
85 + cpu_mode = s->event;
86 if (state == sb_buffer_start)
87 state = sb_sample_start;
88 - add_kernel_ctx_switch(s->event);
89 +
90 + if (s->event == CPU_MODE_PASSIVE_START)
91 + domain_switch = DOMAIN_SWITCH_START_EVENT1;
92 + else if (s->event == CPU_MODE_PASSIVE_STOP)
93 + domain_switch = DOMAIN_SWITCH_STOP_EVENT1;
94 +
95 + if (domain_switch != DOMAIN_SWITCH_START_EVENT2)
96 + add_cpu_mode_switch(s->event);
97 } else if (s->event == CPU_TRACE_BEGIN) {
98 state = sb_bt_start;
99 add_trace_begin();
100 @@ -535,11 +562,20 @@ void sync_buffer(int cpu)
101 add_user_ctx_switch(new, cookie);
102 }
103 } else {
104 - if (state >= sb_bt_start &&
105 - !add_sample(mm, s, in_kernel)) {
106 - if (state == sb_bt_start) {
107 - state = sb_bt_ignore;
108 - atomic_inc(&oprofile_stats.bt_lost_no_mapping);
109 + if (domain_switch == DOMAIN_SWITCH_START_EVENT1) {
110 + add_event_entry(s->event);
111 + domain_switch = DOMAIN_SWITCH_START_EVENT2;
112 + } else if (domain_switch == DOMAIN_SWITCH_START_EVENT1) {
113 + add_sample_entry(s->eip, s->event);
114 + } else if (domain_switch == DOMAIN_SWITCH_STOP_EVENT1) {
115 + domain_switch = NO_DOMAIN_SWITCH;
116 + } else {
117 + if (state >= sb_bt_start &&
118 + !add_sample(mm, s, cpu_mode)) {
119 + if (state == sb_bt_start) {
120 + state = sb_bt_ignore;
121 + atomic_inc(&oprofile_stats.bt_lost_no_mapping);
122 + }
123 }
124 }
125 }
126 diff -pru ../pristine-linux-2.6.16.13/drivers/oprofile/buffer_sync.h ./drivers/oprofile/buffer_sync.h
127 --- ../pristine-linux-2.6.16.13/drivers/oprofile/buffer_sync.h 2006-05-03 05:38:44.000000000 +0800
128 +++ ./drivers/oprofile/buffer_sync.h 2006-06-27 12:12:09.000000000 +0800
129 @@ -9,6 +9,11 @@
131 #ifndef OPROFILE_BUFFER_SYNC_H
132 #define OPROFILE_BUFFER_SYNC_H
133 +
134 +#define NO_DOMAIN_SWITCH -1
135 +#define DOMAIN_SWITCH_START_EVENT1 0
136 +#define DOMAIN_SWITCH_START_EVENT2 1
137 +#define DOMAIN_SWITCH_STOP_EVENT1 2
139 /* add the necessary profiling hooks */
140 int sync_start(void);
141 diff -pru ../pristine-linux-2.6.16.13/drivers/oprofile/cpu_buffer.c ./drivers/oprofile/cpu_buffer.c
142 --- ../pristine-linux-2.6.16.13/drivers/oprofile/cpu_buffer.c 2006-05-03 05:38:44.000000000 +0800
143 +++ ./drivers/oprofile/cpu_buffer.c 2006-06-19 22:43:53.000000000 +0800
144 @@ -6,6 +6,10 @@
145 *
146 * @author John Levon <levon@movementarian.org>
147 *
148 + * Modified by Aravind Menon for Xen
149 + * These modifications are:
150 + * Copyright (C) 2005 Hewlett-Packard Co.
151 + *
152 * Each CPU has a local buffer that stores PC value/event
153 * pairs. We also log context switches when we notice them.
154 * Eventually each CPU's buffer is processed into the global
155 @@ -58,7 +62,7 @@ int alloc_cpu_buffers(void)
156 goto fail;
158 b->last_task = NULL;
159 - b->last_is_kernel = -1;
160 + b->last_cpu_mode = -1;
161 b->tracing = 0;
162 b->buffer_size = buffer_size;
163 b->tail_pos = 0;
164 @@ -114,7 +118,7 @@ void cpu_buffer_reset(struct oprofile_cp
165 * collected will populate the buffer with proper
166 * values to initialize the buffer
167 */
168 - cpu_buf->last_is_kernel = -1;
169 + cpu_buf->last_cpu_mode = -1;
170 cpu_buf->last_task = NULL;
171 }
173 @@ -164,13 +168,13 @@ add_code(struct oprofile_cpu_buffer * bu
174 * because of the head/tail separation of the writer and reader
175 * of the CPU buffer.
176 *
177 - * is_kernel is needed because on some architectures you cannot
178 + * cpu_mode is needed because on some architectures you cannot
179 * tell if you are in kernel or user space simply by looking at
180 - * pc. We tag this in the buffer by generating kernel enter/exit
181 - * events whenever is_kernel changes
182 + * pc. We tag this in the buffer by generating kernel/user (and xen)
183 + * enter events whenever cpu_mode changes
184 */
185 static int log_sample(struct oprofile_cpu_buffer * cpu_buf, unsigned long pc,
186 - int is_kernel, unsigned long event)
187 + int cpu_mode, unsigned long event)
188 {
189 struct task_struct * task;
191 @@ -181,16 +185,14 @@ static int log_sample(struct oprofile_cp
192 return 0;
193 }
195 - is_kernel = !!is_kernel;
196 -
197 task = current;
199 /* notice a switch from user->kernel or vice versa */
200 - if (cpu_buf->last_is_kernel != is_kernel) {
201 - cpu_buf->last_is_kernel = is_kernel;
202 - add_code(cpu_buf, is_kernel);
203 + if (cpu_buf->last_cpu_mode != cpu_mode) {
204 + cpu_buf->last_cpu_mode = cpu_mode;
205 + add_code(cpu_buf, cpu_mode);
206 }
207 -
208 +
209 /* notice a task switch */
210 if (cpu_buf->last_task != task) {
211 cpu_buf->last_task = task;
212 diff -pru ../pristine-linux-2.6.16.13/drivers/oprofile/cpu_buffer.h ./drivers/oprofile/cpu_buffer.h
213 --- ../pristine-linux-2.6.16.13/drivers/oprofile/cpu_buffer.h 2006-05-03 05:38:44.000000000 +0800
214 +++ ./drivers/oprofile/cpu_buffer.h 2006-06-27 10:38:08.000000000 +0800
215 @@ -36,7 +36,7 @@ struct oprofile_cpu_buffer {
216 volatile unsigned long tail_pos;
217 unsigned long buffer_size;
218 struct task_struct * last_task;
219 - int last_is_kernel;
220 + int last_cpu_mode;
221 int tracing;
222 struct op_sample * buffer;
223 unsigned long sample_received;
224 @@ -51,7 +51,13 @@ extern struct oprofile_cpu_buffer cpu_bu
225 void cpu_buffer_reset(struct oprofile_cpu_buffer * cpu_buf);
227 /* transient events for the CPU buffer -> event buffer */
228 -#define CPU_IS_KERNEL 1
229 -#define CPU_TRACE_BEGIN 2
230 +#define CPU_MODE_USER 0
231 +#define CPU_MODE_KERNEL 1
232 +#define CPU_MODE_XEN 2
233 +#define CPU_MODE_PASSIVE_START 3
234 +#define CPU_MODE_PASSIVE_STOP 4
235 +#define CPU_TRACE_BEGIN 5
236 +
237 +#define IGNORED_PC 0
239 #endif /* OPROFILE_CPU_BUFFER_H */
240 diff -pru ../pristine-linux-2.6.16.13/drivers/oprofile/event_buffer.h ./drivers/oprofile/event_buffer.h
241 --- ../pristine-linux-2.6.16.13/drivers/oprofile/event_buffer.h 2006-05-03 05:38:44.000000000 +0800
242 +++ ./drivers/oprofile/event_buffer.h 2006-06-19 22:43:53.000000000 +0800
243 @@ -29,11 +29,14 @@ void wake_up_buffer_waiter(void);
244 #define CPU_SWITCH_CODE 2
245 #define COOKIE_SWITCH_CODE 3
246 #define KERNEL_ENTER_SWITCH_CODE 4
247 -#define KERNEL_EXIT_SWITCH_CODE 5
248 +#define USER_ENTER_SWITCH_CODE 5
249 #define MODULE_LOADED_CODE 6
250 #define CTX_TGID_CODE 7
251 #define TRACE_BEGIN_CODE 8
252 #define TRACE_END_CODE 9
253 +#define XEN_ENTER_SWITCH_CODE 10
254 +#define PASSIVE_START_CODE 11
255 +#define PASSIVE_STOP_CODE 12
257 #define INVALID_COOKIE ~0UL
258 #define NO_COOKIE 0UL
259 diff -pru ../pristine-linux-2.6.16.13/drivers/oprofile/oprof.c ./drivers/oprofile/oprof.c
260 --- ../pristine-linux-2.6.16.13/drivers/oprofile/oprof.c 2006-05-03 05:38:44.000000000 +0800
261 +++ ./drivers/oprofile/oprof.c 2006-06-19 23:45:17.000000000 +0800
262 @@ -5,6 +5,10 @@
263 * @remark Read the file COPYING
264 *
265 * @author John Levon <levon@movementarian.org>
266 + *
267 + * Modified by Aravind Menon for Xen
268 + * These modifications are:
269 + * Copyright (C) 2005 Hewlett-Packard Co.
270 */
272 #include <linux/kernel.h>
273 @@ -19,7 +23,7 @@
274 #include "cpu_buffer.h"
275 #include "buffer_sync.h"
276 #include "oprofile_stats.h"
277 -
278 +
279 struct oprofile_operations oprofile_ops;
281 unsigned long oprofile_started;
282 @@ -33,6 +37,32 @@ static DECLARE_MUTEX(start_sem);
283 */
284 static int timer = 0;
286 +int oprofile_set_active(int active_domains[], unsigned int adomains)
287 +{
288 + int err;
289 +
290 + if (!oprofile_ops.set_active)
291 + return -EINVAL;
292 +
293 + down(&start_sem);
294 + err = oprofile_ops.set_active(active_domains, adomains);
295 + up(&start_sem);
296 + return err;
297 +}
298 +
299 +int oprofile_set_passive(int passive_domains[], unsigned int pdomains)
300 +{
301 + int err;
302 +
303 + if (!oprofile_ops.set_passive)
304 + return -EINVAL;
305 +
306 + down(&start_sem);
307 + err = oprofile_ops.set_passive(passive_domains, pdomains);
308 + up(&start_sem);
309 + return err;
310 +}
311 +
312 int oprofile_setup(void)
313 {
314 int err;
315 diff -pru ../pristine-linux-2.6.16.13/drivers/oprofile/oprof.h ./drivers/oprofile/oprof.h
316 --- ../pristine-linux-2.6.16.13/drivers/oprofile/oprof.h 2006-05-03 05:38:44.000000000 +0800
317 +++ ./drivers/oprofile/oprof.h 2006-06-19 23:42:36.000000000 +0800
318 @@ -35,5 +35,8 @@ void oprofile_create_files(struct super_
319 void oprofile_timer_init(struct oprofile_operations * ops);
321 int oprofile_set_backtrace(unsigned long depth);
322 +
323 +int oprofile_set_active(int active_domains[], unsigned int adomains);
324 +int oprofile_set_passive(int passive_domains[], unsigned int pdomains);
326 #endif /* OPROF_H */
327 diff -pru ../pristine-linux-2.6.16.13/drivers/oprofile/oprofile_files.c ./drivers/oprofile/oprofile_files.c
328 --- ../pristine-linux-2.6.16.13/drivers/oprofile/oprofile_files.c 2006-05-03 05:38:44.000000000 +0800
329 +++ ./drivers/oprofile/oprofile_files.c 2006-06-19 23:29:07.000000000 +0800
330 @@ -5,15 +5,21 @@
331 * @remark Read the file COPYING
332 *
333 * @author John Levon <levon@movementarian.org>
334 + *
335 + * Modified by Aravind Menon for Xen
336 + * These modifications are:
337 + * Copyright (C) 2005 Hewlett-Packard Co.
338 */
340 #include <linux/fs.h>
341 #include <linux/oprofile.h>
342 +#include <asm/uaccess.h>
343 +#include <linux/ctype.h>
345 #include "event_buffer.h"
346 #include "oprofile_stats.h"
347 #include "oprof.h"
348 -
349 +
350 unsigned long fs_buffer_size = 131072;
351 unsigned long fs_cpu_buffer_size = 8192;
352 unsigned long fs_buffer_watershed = 32768; /* FIXME: tune */
353 @@ -117,11 +123,202 @@ static ssize_t dump_write(struct file *
354 static struct file_operations dump_fops = {
355 .write = dump_write,
356 };
357 -
358 +
359 +#define TMPBUFSIZE 512
360 +
361 +static unsigned int adomains = 0;
362 +static int active_domains[MAX_OPROF_DOMAINS + 1];
363 +static DEFINE_MUTEX(adom_mutex);
364 +
365 +static ssize_t adomain_write(struct file * file, char const __user * buf,
366 + size_t count, loff_t * offset)
367 +{
368 + char *tmpbuf;
369 + char *startp, *endp;
370 + int i;
371 + unsigned long val;
372 + ssize_t retval = count;
373 +
374 + if (*offset)
375 + return -EINVAL;
376 + if (count > TMPBUFSIZE - 1)
377 + return -EINVAL;
378 +
379 + if (!(tmpbuf = kmalloc(TMPBUFSIZE, GFP_KERNEL)))
380 + return -ENOMEM;
381 +
382 + if (copy_from_user(tmpbuf, buf, count)) {
383 + kfree(tmpbuf);
384 + return -EFAULT;
385 + }
386 + tmpbuf[count] = 0;
387 +
388 + mutex_lock(&adom_mutex);
389 +
390 + startp = tmpbuf;
391 + /* Parse one more than MAX_OPROF_DOMAINS, for easy error checking */
392 + for (i = 0; i <= MAX_OPROF_DOMAINS; i++) {
393 + val = simple_strtoul(startp, &endp, 0);
394 + if (endp == startp)
395 + break;
396 + while (ispunct(*endp) || isspace(*endp))
397 + endp++;
398 + active_domains[i] = val;
399 + if (active_domains[i] != val)
400 + /* Overflow, force error below */
401 + i = MAX_OPROF_DOMAINS + 1;
402 + startp = endp;
403 + }
404 + /* Force error on trailing junk */
405 + adomains = *startp ? MAX_OPROF_DOMAINS + 1 : i;
406 +
407 + kfree(tmpbuf);
408 +
409 + if (adomains > MAX_OPROF_DOMAINS
410 + || oprofile_set_active(active_domains, adomains)) {
411 + adomains = 0;
412 + retval = -EINVAL;
413 + }
414 +
415 + mutex_unlock(&adom_mutex);
416 + return retval;
417 +}
418 +
419 +static ssize_t adomain_read(struct file * file, char __user * buf,
420 + size_t count, loff_t * offset)
421 +{
422 + char * tmpbuf;
423 + size_t len;
424 + int i;
425 + ssize_t retval;
426 +
427 + if (!(tmpbuf = kmalloc(TMPBUFSIZE, GFP_KERNEL)))
428 + return -ENOMEM;
429 +
430 + mutex_lock(&adom_mutex);
431 +
432 + len = 0;
433 + for (i = 0; i < adomains; i++)
434 + len += snprintf(tmpbuf + len,
435 + len < TMPBUFSIZE ? TMPBUFSIZE - len : 0,
436 + "%u ", active_domains[i]);
437 + WARN_ON(len > TMPBUFSIZE);
438 + if (len != 0 && len <= TMPBUFSIZE)
439 + tmpbuf[len-1] = '\n';
440 +
441 + mutex_unlock(&adom_mutex);
442 +
443 + retval = simple_read_from_buffer(buf, count, offset, tmpbuf, len);
444 +
445 + kfree(tmpbuf);
446 + return retval;
447 +}
448 +
449 +
450 +static struct file_operations active_domain_ops = {
451 + .read = adomain_read,
452 + .write = adomain_write,
453 +};
454 +
455 +static unsigned int pdomains = 0;
456 +static int passive_domains[MAX_OPROF_DOMAINS];
457 +static DEFINE_MUTEX(pdom_mutex);
458 +
459 +static ssize_t pdomain_write(struct file * file, char const __user * buf,
460 + size_t count, loff_t * offset)
461 +{
462 + char *tmpbuf;
463 + char *startp, *endp;
464 + int i;
465 + unsigned long val;
466 + ssize_t retval = count;
467 +
468 + if (*offset)
469 + return -EINVAL;
470 + if (count > TMPBUFSIZE - 1)
471 + return -EINVAL;
472 +
473 + if (!(tmpbuf = kmalloc(TMPBUFSIZE, GFP_KERNEL)))
474 + return -ENOMEM;
475 +
476 + if (copy_from_user(tmpbuf, buf, count)) {
477 + kfree(tmpbuf);
478 + return -EFAULT;
479 + }
480 + tmpbuf[count] = 0;
481 +
482 + mutex_lock(&pdom_mutex);
483 +
484 + startp = tmpbuf;
485 + /* Parse one more than MAX_OPROF_DOMAINS, for easy error checking */
486 + for (i = 0; i <= MAX_OPROF_DOMAINS; i++) {
487 + val = simple_strtoul(startp, &endp, 0);
488 + if (endp == startp)
489 + break;
490 + while (ispunct(*endp) || isspace(*endp))
491 + endp++;
492 + passive_domains[i] = val;
493 + if (passive_domains[i] != val)
494 + /* Overflow, force error below */
495 + i = MAX_OPROF_DOMAINS + 1;
496 + startp = endp;
497 + }
498 + /* Force error on trailing junk */
499 + pdomains = *startp ? MAX_OPROF_DOMAINS + 1 : i;
500 +
501 + kfree(tmpbuf);
502 +
503 + if (pdomains > MAX_OPROF_DOMAINS
504 + || oprofile_set_passive(passive_domains, pdomains)) {
505 + pdomains = 0;
506 + retval = -EINVAL;
507 + }
508 +
509 + mutex_unlock(&pdom_mutex);
510 + return retval;
511 +}
512 +
513 +static ssize_t pdomain_read(struct file * file, char __user * buf,
514 + size_t count, loff_t * offset)
515 +{
516 + char * tmpbuf;
517 + size_t len;
518 + int i;
519 + ssize_t retval;
520 +
521 + if (!(tmpbuf = kmalloc(TMPBUFSIZE, GFP_KERNEL)))
522 + return -ENOMEM;
523 +
524 + mutex_lock(&pdom_mutex);
525 +
526 + len = 0;
527 + for (i = 0; i < pdomains; i++)
528 + len += snprintf(tmpbuf + len,
529 + len < TMPBUFSIZE ? TMPBUFSIZE - len : 0,
530 + "%u ", passive_domains[i]);
531 + WARN_ON(len > TMPBUFSIZE);
532 + if (len != 0 && len <= TMPBUFSIZE)
533 + tmpbuf[len-1] = '\n';
534 +
535 + mutex_unlock(&pdom_mutex);
536 +
537 + retval = simple_read_from_buffer(buf, count, offset, tmpbuf, len);
538 +
539 + kfree(tmpbuf);
540 + return retval;
541 +}
542 +
543 +static struct file_operations passive_domain_ops = {
544 + .read = pdomain_read,
545 + .write = pdomain_write,
546 +};
547 +
548 void oprofile_create_files(struct super_block * sb, struct dentry * root)
549 {
550 oprofilefs_create_file(sb, root, "enable", &enable_fops);
551 oprofilefs_create_file_perm(sb, root, "dump", &dump_fops, 0666);
552 + oprofilefs_create_file(sb, root, "active_domains", &active_domain_ops);
553 + oprofilefs_create_file(sb, root, "passive_domains", &passive_domain_ops);
554 oprofilefs_create_file(sb, root, "buffer", &event_buffer_fops);
555 oprofilefs_create_ulong(sb, root, "buffer_size", &fs_buffer_size);
556 oprofilefs_create_ulong(sb, root, "buffer_watershed", &fs_buffer_watershed);
557 --- ../pristine-linux-2.6.16.13/include/linux/oprofile.h 2006-05-03 05:38:44.000000000 +0800
558 +++ ./include/linux/oprofile.h 2006-06-19 23:52:00.000000000 +0800
559 @@ -16,6 +16,8 @@
560 #include <linux/types.h>
561 #include <linux/spinlock.h>
562 #include <asm/atomic.h>
563 +
564 +#include <xen/interface/xenoprof.h>
566 struct super_block;
567 struct dentry;
568 @@ -27,6 +29,11 @@ struct oprofile_operations {
569 /* create any necessary configuration files in the oprofile fs.
570 * Optional. */
571 int (*create_files)(struct super_block * sb, struct dentry * root);
572 + /* setup active domains with Xen */
573 + int (*set_active)(int *active_domains, unsigned int adomains);
574 + /* setup passive domains with Xen */
575 + int (*set_passive)(int *passive_domains, unsigned int pdomains);
576 +
577 /* Do any necessary interrupt setup. Optional. */
578 int (*setup)(void);
579 /* Do any necessary interrupt shutdown. Optional. */