diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2008-03-25 17:55:39 +0000 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2008-03-25 17:55:39 +0000 |
commit | 798780cf11a892e3eaac207794a12bff23ddb598 (patch) | |
tree | 3ae19c1fa65689bbdaa8d6ea5a09299f65d6521c /extras/mini-os/events.c | |
parent | 774a123b38a3dbe08ad1ab569edc4e848cf67a62 (diff) | |
download | xen-798780cf11a892e3eaac207794a12bff23ddb598.tar.gz xen-798780cf11a892e3eaac207794a12bff23ddb598.tar.bz2 xen-798780cf11a892e3eaac207794a12bff23ddb598.zip |
stubdom: fix x86_64 irq stack size
by making it use STACK_SIZE like other places.
Signed-off-by: Samuel Thibault <samuel.thibault@eu.citrix.com>
Diffstat (limited to 'extras/mini-os/events.c')
-rw-r--r-- | extras/mini-os/events.c | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/extras/mini-os/events.c b/extras/mini-os/events.c index 7c88807889..51a3cc24f0 100644 --- a/extras/mini-os/events.c +++ b/extras/mini-os/events.c @@ -118,9 +118,7 @@ evtchn_port_t bind_virq(uint32_t virq, evtchn_handler_t handler, void *data) } #if defined(__x86_64__) -/* Allocate 4 pages for the irqstack */ -#define STACK_PAGES 4 -char irqstack[1024 * 4 * STACK_PAGES]; +char irqstack[2 * STACK_SIZE]; static struct pda { @@ -139,9 +137,9 @@ void init_events(void) asm volatile("movl %0,%%fs ; movl %0,%%gs" :: "r" (0)); wrmsrl(0xc0000101, &cpu0_pda); /* 0xc0000101 is MSR_GS_BASE */ cpu0_pda.irqcount = -1; - cpu0_pda.irqstackptr = irqstack + 1024 * 4 * STACK_PAGES; + cpu0_pda.irqstackptr = (void*) (((unsigned long)irqstack + 2 * STACK_SIZE) & ~(STACK_SIZE - 1)); #endif - /* inintialise event handler */ + /* initialize event handler */ for ( i = 0; i < NR_EVS; i++ ) { ev_actions[i].handler = default_handler; |