drm crtc: use drm_mode_destroy instead of kfree in drm_mode_remove

Modes are created using drm_mode_create which does a
drm_mode_object_get, so use drm_mode_destroy in drm_mode_remove
which does a drm_mode_object_put.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Dave Airlie <airlied@redhat.com>
This commit is contained in:
Sascha Hauer 2012-02-01 11:38:19 +01:00 committed by Dave Airlie
parent aefd330e69
commit 554f1d7888
1 changed files with 1 additions and 1 deletions

View File

@ -442,7 +442,7 @@ void drm_mode_remove(struct drm_connector *connector,
struct drm_display_mode *mode)
{
list_del(&mode->head);
kfree(mode);
drm_mode_destroy(connector->dev, mode);
}
EXPORT_SYMBOL(drm_mode_remove);