Skip to contentSkip to conversation

extcon: palmas: remove assigning "edev.name" to palmas

PATCH In review Kishon Vijay Abraham I 2 participants 2 messages Jun 14, 2013 – Jul 15, 2013 External connector subsystem (extcon)

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 extcon: palmas: remove assigning "edev.name" to palmas

of_extcon_get_extcon_dev() uses dev_name for getting the reference to the extcon device. If the extcon driver assigns a different name other than dev_name, of_extcon_get_extcon_dev() wouldn't be able to find the reference to the extcon device. Since the client drivers of extcon-palmas would be using of_extcon_get_extcon_dev(), removed assigning edev.name in extcon-palmas.

---
 drivers/extcon/extcon-palmas.c |    1 -
 1 file changed, 1 deletion(-)
drivers/extcon/extcon-palmas.c +0 -1
index b752a0a..7350ac2 100644
@@ -172,7 +172,6 @@ static int palmas_usb_probe(struct platform_device *pdev)
 
 	platform_set_drvdata(pdev, palmas_usb);
 
-	palmas_usb->edev.name = "palmas-usb";
 	palmas_usb->edev.supported_cable = palmas_extcon_cable;
 	palmas_usb->edev.mutually_exclusive = mutually_exclusive;
 
Signature · 1 line
1.7.10.4
maintainer
#1 lore raw
Quoted 19 lines · Kishon Vijay Abraham I

of_extcon_get_extcon_dev() uses dev_name for getting the reference to the extcon device. If the extcon driver assigns a different name other than dev_name, of_extcon_get_extcon_dev() wouldn't be able to find the reference to the extcon device. Since the client drivers of extcon-palmas would be using of_extcon_get_extcon_dev(), removed assigning edev.name in extcon-palmas.

---
 drivers/extcon/extcon-palmas.c |    1 -
 1 file changed, 1 deletion(-)
drivers/extcon/extcon-palmas.c +0 -0
index b752a0a..7350ac2 100644

drivers/extcon/extcon-palmas.c static int palmas_usb_probe(struct platform_device *pdev) · line 177

Quoted 7 lines
drivers/extcon/extcon-palmas.c +0 -1
@@ -172,7 +172,6 @@ static int palmas_usb_probe(struct platform_device *pdev)
 
 	platform_set_drvdata(pdev, palmas_usb);
 
-	palmas_usb->edev.name = "palmas-usb";
 	palmas_usb->edev.supported_cable = palmas_extcon_cable;
 	palmas_usb->edev.mutually_exclusive = mutually_exclusive;
 

This patch is applied. Sorry for missing this patch.
You can check it on extcon-linus repo.
- http://git.kernel.org/cgit/linux/kernel/git/chanwoo/extcon.git/log/?h=extcon-linus

Thanks,
Chanwoo Choi