提交 debd15ce 编写于 作者: L Liviu Dudau (ARM) 提交者: Russell King

drm/i2c: tda998x: unregister the connector in the unbind function

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: NLiviu Dudau <Liviu.Dudau@arm.com>
Signed-off-by: NRussell King <rmk+kernel@arm.linux.org.uk>
上级 9525c4dd
...@@ -1472,6 +1472,7 @@ static void tda998x_unbind(struct device *dev, struct device *master, ...@@ -1472,6 +1472,7 @@ static void tda998x_unbind(struct device *dev, struct device *master,
{ {
struct tda998x_priv *priv = dev_get_drvdata(dev); struct tda998x_priv *priv = dev_get_drvdata(dev);
drm_connector_unregister(&priv->connector);
drm_connector_cleanup(&priv->connector); drm_connector_cleanup(&priv->connector);
drm_encoder_cleanup(&priv->encoder); drm_encoder_cleanup(&priv->encoder);
tda998x_destroy(priv); tda998x_destroy(priv);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册