Fix a one-off error in compat_addr_ok(). Signed-off-by: Jan Beulich <jbeulich@novell.com> Index: 2007-01-08/xen/include/asm-x86/x86_64/uaccess.h ==================================================================--- 2007-01-08.orig/xen/include/asm-x86/x86_64/uaccess.h 2006-12-18 09:49:18.000000000 +0100 +++ 2007-01-08/xen/include/asm-x86/x86_64/uaccess.h 2007-01-25 15:18:37.000000000 +0100 @@ -20,7 +20,8 @@ #define __compat_addr_ok(addr) \ ((unsigned long)(addr) < HYPERVISOR_COMPAT_VIRT_START(current->domain)) -#define compat_access_ok(addr, size) __compat_addr_ok((addr) + (size)) +#define compat_access_ok(addr, size) \ + __compat_addr_ok((unsigned long)(addr) + ((size) ? (size) - 1 : 0)) #define compat_array_access_ok(addr,count,size) \ (likely((count) < (~0U / (size))) && \ _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel