[PATCH] ntdll: use symbols, add documentation for i386 page faulterror code

Dmitry Timoshkov dmitry at codeweavers.com
Mon Jul 28 10:34:48 CDT 2008


"John Reiser" <jreiser at BitWagon.com> wrote:

> diff --git a/include/winnt.h b/include/winnt.h
> index e8a37f5..ad2f674 100644
> --- a/include/winnt.h
> +++ b/include/winnt.h
> @@ -812,9 +812,24 @@ typedef struct _CONTEXT86
> 
> typedef CONTEXT86 CONTEXT;
> 
> -#define EXCEPTION_READ_FAULT    0
> -#define EXCEPTION_WRITE_FAULT   1
> -#define EXCEPTION_EXECUTE_FAULT 8
> +/* Page Fault Error Code.
> + * Intel 64 and IA-32 Architectures Software Developer's Manual, Volume 3A:
> + * System Programming Guide, Part 1; Figure 5-9, Page-Fault Error Code, p.5-55.
> + * http://www.intel.com/design/processor/manuals/253668.pdf
> + * linux/arch/x86/mm/fault.c  do_page_fault()
> + */
> +/*  This hardware bit is ignored by shifting it off the bottom.
> + *#define EXCEPTION_PAGE_NOT_P  (0<<0)
> + *#define EXCEPTION_PROT_VIOL   (1<<0)
> + *
> + * Hardware delivers these bits [below] one position to the left.
> + */
> +#define EXCEPTION_READ_FAULT    (0<<0)
> +#define EXCEPTION_WRITE_FAULT   (1<<0)  /* 1 */
> +#define EXCEPTION_KERNEL_MODE   (0<<1)
> +#define EXCEPTION_USER_MODE     (1<<1)  /* 2 */
> +#define EXCEPTION_RSV_PAGETAB   (1<<2)  /* 4 */
> +#define EXCEPTION_EXECUTE_FAULT (1<<3)  /* 8 */

These changes are not compatible with PSDK.

-- 
Dmitry.



More information about the wine-devel mailing list