Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752627AbbKKPfA (ORCPT ); Wed, 11 Nov 2015 10:35:00 -0500 Received: from fw-tnat.cambridge.arm.com ([217.140.96.140]:28021 "EHLO cam-smtp0.cambridge.arm.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752098AbbKKPe7 (ORCPT ); Wed, 11 Nov 2015 10:34:59 -0500 From: Liviu Dudau To: David Airlie Cc: Russell King , DRI devel , LKML Subject: [PATCH 1/3] drm/i2c: tda998x: Unregister the connector in the unbind function. Date: Wed, 11 Nov 2015 15:34:33 +0000 Message-Id: <1447256075-471-2-git-send-email-Liviu.Dudau@arm.com> X-Mailer: git-send-email 2.6.0 In-Reply-To: <1447256075-471-1-git-send-email-Liviu.Dudau@arm.com> References: <1447256075-471-1-git-send-email-Liviu.Dudau@arm.com> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1141 Lines: 31 tda998x uses drm_connector_register() in the .bind function that needs to be balanced with a drm_connector_unregister() in the .unbind. Otherwise dangling sysfs entries are left behind and future rebinds will fail. Signed-off-by: Liviu Dudau Cc: Russell King --- drivers/gpu/drm/i2c/tda998x_drv.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/i2c/tda998x_drv.c b/drivers/gpu/drm/i2c/tda998x_drv.c index 896b6aa..cdbd83b 100644 --- a/drivers/gpu/drm/i2c/tda998x_drv.c +++ b/drivers/gpu/drm/i2c/tda998x_drv.c @@ -1472,6 +1472,7 @@ static void tda998x_unbind(struct device *dev, struct device *master, { struct tda998x_priv *priv = dev_get_drvdata(dev); + drm_connector_unregister(&priv->connector); drm_connector_cleanup(&priv->connector); drm_encoder_cleanup(&priv->encoder); tda998x_destroy(priv); -- 2.6.0 -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/