Determine whether a drm kernel driver has been loaded
#include <xf86drm.h>
int drmAvailable(void);
drmAvailable allows the caller to determine whether a kernel DRM driver is loaded.
drmAvailable returns 1 if a DRM driver is currently loaded. Otherwise 0 is returned.
Bugs in this function should be reported to http://bugs.freedesktop.org under the "Mesa" product, with "Other" or "libdrm" as the component.
drm(7), drmOpen(3)