drm/omap: fix DMM driver (un)registration
commitea7e3a662814447cd329390feddd04b9ec0a4b82
authorTomi Valkeinen <tomi.valkeinen@ti.com>
Wed, 2 Apr 2014 11:31:50 +0000 (2 14:31 +0300)
committerTomi Valkeinen <tomi.valkeinen@ti.com>
Mon, 14 Apr 2014 09:34:14 +0000 (14 12:34 +0300)
treed277124dbb5c40d9a8fe6c15e94cbeeb56c8b297
parent707cf58a0a847f60f849b44bfb9b85dcc17c599d
drm/omap: fix DMM driver (un)registration

At the moment the DMM driver is never unregistered, even if it's
registered in the omapdrm module's init function. This means we'll get
errors when reloading the omapdrm module.

Fix this by unregistering the DMM driver properly, and also change the
module init to fail if DMM driver cannot be registered, simplifying the
unregister path as we don't need to keep the state whether we registered
the DMM driver or not.

Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
Reviewed-by: Rob Clark <robdclark@gmail.com>
drivers/gpu/drm/omapdrm/omap_drv.c