drm: Automatically unregister the connector during cleanup
authorChris Wilson <chris@chris-wilson.co.uk>
Wed, 15 Jun 2016 12:17:49 +0000 (13:17 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 17 Jun 2016 07:43:39 +0000 (09:43 +0200)
commit80de34611af6f123937a40ea17c8db792d38baba
treee0427f6e82c697d9e209a72ffd1f35e212a37a9b
parent40daac6136948dc83c1dec14fe4a2444915b22df
drm: Automatically unregister the connector during cleanup

As we now can call drm_connector_unregister() multiple times, provide a
failsafe unregister for a connector when cleaning it up.

v2: Add a WARN to catch any connectors that are still visible to
userspace when we come to destoy them.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Dave Airlie <airlied@redhat.com>
Cc: dri-devel@lists.freedesktop.org
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/1465993109-19523-5-git-send-email-chris@chris-wilson.co.uk
drivers/gpu/drm/drm_crtc.c