drm_rmmap_ioctl(): remove dead code
PATCH 1/1 drm_rmmap_ioctl(): remove dead code
This patch removes some obviously dead code spotted by the Coverity checker.
Signed-off-by Adrian Bunk <[email protected]>
---
drivers/char/drm/drm_bufs.c renamed from drivers/char/drm/drm_bufs.c.old +0 -5
@@ -476,15 +476,10 @@ int drm_rmmap_ioctl(struct inode *inode,if (list_empty (&dev->maplist) || !map) {mutex_unlock (&dev->struct_mutex);return -EINVAL ; } -if (!map) { -mutex_unlock (&dev->struct_mutex); -return -EINVAL ; - } -/* Register and framebuffer maps are permanent */ if ((map->type == _DRM_REGISTERS) || (map->type == _DRM_FRAME_BUFFER)) {mutex_unlock (&dev->struct_mutex);return 0 ; }