Add some more correctness assertions to free().
[pintos-anon] / src / threads / interrupt.c
index 8e7d575afe7928ac5f22c57c11719e2107dcae50..c886cc9d709ab71a3c4bc870eb758ea92321b1a5 100644 (file)
@@ -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";