Commit 8153aeff authored by Dave Airlie's avatar Dave Airlie

More differentiated error codes for DRM(agp_acquire)

parent 6cc03ee7
......@@ -103,7 +103,11 @@ int DRM(agp_acquire)(struct inode *inode, struct file *filp,
drm_device_t *dev = priv->dev;
int retcode;
if (!dev->agp || dev->agp->acquired || !drm_agp->acquire)
if (!dev->agp)
return -ENODEV;
if (dev->agp->acquired)
return -EBUSY;
if (!drm_agp->acquire)
return -EINVAL;
if ((retcode = drm_agp->acquire()))
return retcode;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment