- uint32_t cr2, ss;
- asm ("movl %%cr2, %0" : "=r" (cr2));
- asm ("movl %%ss, %0" : "=r" (ss));
+ uint32_t cr2;
+
+ /* Store current value of CR2 into `cr2'.
+ CR2 is the linear address of the last page fault.
+ See [IA32-v2a] "MOV--Move to/from Control Registers" and
+ [IA32-v3] 5.14 "Interrupt 14--Page Fault Exception
+ (#PF)". */
+ asm ("mov %0, %%cr2" : "=r" (cr2));