X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fuserprog%2Fexception.c;h=dcfccb85f998da6b5e584da19b891819dc7f776f;hb=7d4e3dda080a47db88616f1c0d975f2091be47f1;hp=745adaa086e4614245748ddd3cbc6c6262b1f5de;hpb=f0ad7eb8b43516c7a2999fd217ec85d954dfc791;p=pintos-anon diff --git a/src/userprog/exception.c b/src/userprog/exception.c index 745adaa..dcfccb8 100644 --- a/src/userprog/exception.c +++ b/src/userprog/exception.c @@ -136,7 +136,7 @@ page_fault (struct intr_frame *f) See [IA32-v2a] "MOV--Move to/from Control Registers" and [IA32-v3] 5.14 "Interrupt 14--Page Fault Exception (#PF)". */ - asm ("movl %%cr2, %0" : "=r" (fault_addr)); + asm ("mov %0, %%cr2" : "=r" (fault_addr)); /* Turn interrupts back on (they were only off so that we could be assured of reading CR2 before it changed). */