X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fthreads%2Finterrupt.c;h=c886cc9d709ab71a3c4bc870eb758ea92321b1a5;hb=cfbade23277061d4ab0d26a2fb350b98657e7302;hp=8e7d575afe7928ac5f22c57c11719e2107dcae50;hpb=b0a700d18f0a0a8c87e1a4fff3a2108e0edb0fbc;p=pintos-anon diff --git a/src/threads/interrupt.c b/src/threads/interrupt.c index 8e7d575..c886cc9 100644 --- a/src/threads/interrupt.c +++ b/src/threads/interrupt.c @@ -51,7 +51,7 @@ intr_get_level (void) { uint32_t flags; - asm ("pushfl; popl %0" : "=g" (flags)); + asm volatile ("pushfl; popl %0" : "=g" (flags)); return flags & FLAG_IF ? INTR_ON : INTR_OFF; } @@ -118,6 +118,7 @@ intr_init (void) intr_names[11] = "#NP Segment Not Present"; intr_names[12] = "#SS Stack Fault Exception"; intr_names[13] = "#GP General Protection Exception"; + intr_names[14] = "#PF Page-Fault Exception"; intr_names[16] = "#MF x87 FPU Floating-Point Error"; intr_names[17] = "#AC Alignment Check Exception"; intr_names[18] = "#MC Machine-Check Exception";