Skip to content

Commit

Permalink
power_supply: Drop usage of nowarn variant of sysfs_create_link()
Browse files Browse the repository at this point in the history
The function is not exported to modules, plus we do want to catch anyone
who tries to create complex hierarchy (in that case we'd need to change
'powers' symlink to a directory, probably under a different name to not
break ABI).

This patch fixes the following build error:

 ERROR: "sysfs_create_link_nowarn" [drivers/power/power_supply.ko] undefined!

Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Anton Vorontsov <cbouatmailru@gmail.com>
  • Loading branch information
Anton Vorontsov authored and Anton Vorontsov committed Jan 7, 2012
1 parent 34aed73 commit 93278d1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/power/power_supply_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,7 @@ EXPORT_SYMBOL_GPL(power_supply_get_by_name);

int power_supply_powers(struct power_supply *psy, struct device *dev)
{
return sysfs_create_link_nowarn(&psy->dev->kobj, &dev->kobj, "powers");
return sysfs_create_link(&psy->dev->kobj, &dev->kobj, "powers");
}
EXPORT_SYMBOL_GPL(power_supply_powers);

Expand Down

0 comments on commit 93278d1

Please sign in to comment.