[PATCH 07/16] drm: Add a function to get the ioctl flags