drm: Remove drm_vblank_cleanup from drm_vblank_init error path.
authorMario Kleiner <mario.kleiner.de@gmail.com>
Wed, 6 Aug 2014 01:22:44 +0000 (03:22 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Wed, 6 Aug 2014 20:39:32 +0000 (22:39 +0200)
drm_vblank_cleanup() would operate on non-existent dev->vblank
data structure, as failure to allocate that data structure is
what triggers the error path in the first place.

Signed-off-by: Mario Kleiner <mario.kleiner.de@gmail.com>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/drm_irq.c

index aa9b0649506757c1e7819a5adf33462e43ed3606..6473089e5fd3e32499389c04dd16a005993f80aa 100644 (file)
@@ -303,7 +303,7 @@ int drm_vblank_init(struct drm_device *dev, int num_crtcs)
        return 0;
 
 err:
-       drm_vblank_cleanup(dev);
+       dev->num_crtcs = 0;
        return ret;
 }
 EXPORT_SYMBOL(drm_vblank_init);