diff --git a/lib/libdrm/libdrm/xf86drm.h b/lib/libdrm/libdrm/xf86drm.h index 34c9ec0e6..30dad41db 100644 --- a/lib/libdrm/libdrm/xf86drm.h +++ b/lib/libdrm/libdrm/xf86drm.h @@ -48,8 +48,13 @@ (S_IRUSR|S_IWUSR|S_IXUSR|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH) #define DRM_DEV_MODE (S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP) +#ifdef __OpenBSD__ +#define DRM_DIR_NAME "/dev" +#define DRM_DEV_NAME "%s/drm%d" +#else #define DRM_DIR_NAME "/dev/dri" #define DRM_DEV_NAME "%s/card%d" +#endif #define DRM_PROC_NAME "/proc/dri/" /* For backward Linux compatibility */ #define DRM_ERR_NO_DEVICE (-1001) diff --git a/xserver/os/privsep.c b/xserver/os/privsep.c index 5d1422290..1394b844a 100644 --- a/xserver/os/privsep.c +++ b/xserver/os/privsep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: privsep.c,v 1.6 2008/06/12 18:50:19 oga Exp $ */ +/* $OpenBSD: privsep.c,v 1.7 2008/06/12 22:20:24 oga Exp $ */ /* * Copyright 2001 Niels Provos * All rights reserved. @@ -108,7 +108,7 @@ struct okdev { {"/dev/ttyD7", O_RDWR | O_NONBLOCK | O_EXCL}, {"/dev/pci", O_RDWR | O_NONBLOCK | O_EXCL}, {"/dev/agp0", O_RDWR | O_NONBLOCK | O_EXCL}, - {"/dev/dri/card0", O_RDWR }, + {"/dev/drm0", O_RDWR }, {NULL, 0} };