This will allow Mesa to port code to Windows more easily. Hide BSD header and drm_handle_t behind _WIN32 check. Change __volatile__ to volatile, which is standard. Signed-off-by: James Park <jpark37@xxxxxxxxxxxxxxxx> --- include/uapi/drm/drm.h | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/include/uapi/drm/drm.h b/include/uapi/drm/drm.h index 808b48a..53dc3c9 100644 --- a/include/uapi/drm/drm.h +++ b/include/uapi/drm/drm.h @@ -48,10 +48,9 @@ typedef unsigned int drm_handle_t; #include <asm/ioctl.h> typedef unsigned int drm_handle_t; -#else /* One of the BSDs */ +#else #include <stdint.h> -#include <sys/ioccom.h> #include <sys/types.h> typedef int8_t __s8; typedef uint8_t __u8; @@ -62,10 +61,16 @@ typedef uint32_t __u32; typedef int64_t __s64; typedef uint64_t __u64; typedef size_t __kernel_size_t; + +#ifndef _WIN32 /* One of the BSDs */ + +#include <sys/ioccom.h> typedef unsigned long drm_handle_t; #endif +#endif + #if defined(__cplusplus) extern "C" { #endif @@ -128,7 +133,7 @@ struct drm_tex_region { * other data stored in the same cache line. */ struct drm_hw_lock { - __volatile__ unsigned int lock; /**< lock variable */ + volatile unsigned int lock; /**< lock variable */ char padding[60]; /**< Pad to cache line */ }; -- 2.7.4 _______________________________________________ dri-devel mailing list dri-devel@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/dri-devel