Skip to content

Commit

Permalink
Extcon: Don't try to create duplicate link names
Browse files Browse the repository at this point in the history
We can't create a link from the device to the compatibility switch class
since we already create a link from the device to to the extcon class
object and we try to use the same name for both links. This causes a loud
complaint from sysfs on boot.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
  • Loading branch information
Mark Brown authored and Greg Kroah-Hartman committed Jun 15, 2012
1 parent 1d29cfa commit c3b1545
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/extcon/extcon_class.c
Original file line number Diff line number Diff line change
@@ -762,7 +762,7 @@ int extcon_dev_register(struct extcon_dev *edev, struct device *dev)
#if defined(CONFIG_ANDROID)
if (switch_class)
ret = class_compat_create_link(switch_class, edev->dev,
dev);
NULL);
#endif /* CONFIG_ANDROID */

spin_lock_init(&edev->lock);

0 comments on commit c3b1545

Please sign in to comment.