From fb9a35f89fac2ca97597ce212439d2997f2caf7e Mon Sep 17 00:00:00 2001 From: Laurent Pinchart Date: Sun, 11 Jan 2015 16:30:44 +0200 Subject: drm: omapdrm: Refactor CRTC creation code Create a omap_modeset_create_crtc() function to avoid duplicating plane and CRTC creation code. Signed-off-by: Laurent Pinchart --- drivers/gpu/drm/omapdrm/omap_plane.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/gpu/drm/omapdrm/omap_plane.c') diff --git a/drivers/gpu/drm/omapdrm/omap_plane.c b/drivers/gpu/drm/omapdrm/omap_plane.c index a418fa7e5d0e..056ded8280f8 100644 --- a/drivers/gpu/drm/omapdrm/omap_plane.c +++ b/drivers/gpu/drm/omapdrm/omap_plane.c @@ -393,7 +393,7 @@ struct drm_plane *omap_plane_init(struct drm_device *dev, omap_plane = kzalloc(sizeof(*omap_plane), GFP_KERNEL); if (!omap_plane) - return NULL; + return ERR_PTR(-ENOMEM); drm_flip_work_init(&omap_plane->unpin_work, "unpin", unpin_worker); -- cgit v1.2.3