Commit fa515888 authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/staging

* 'hwmon-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/groeck/staging:
  hwmon: (twl4030-madc-hwmon) Return proper error if hwmon_device_register fails
parents bc9be57f c30aa39c
...@@ -98,7 +98,6 @@ static const struct attribute_group twl4030_madc_group = { ...@@ -98,7 +98,6 @@ static const struct attribute_group twl4030_madc_group = {
static int __devinit twl4030_madc_hwmon_probe(struct platform_device *pdev) static int __devinit twl4030_madc_hwmon_probe(struct platform_device *pdev)
{ {
int ret; int ret;
int status;
struct device *hwmon; struct device *hwmon;
ret = sysfs_create_group(&pdev->dev.kobj, &twl4030_madc_group); ret = sysfs_create_group(&pdev->dev.kobj, &twl4030_madc_group);
...@@ -107,7 +106,7 @@ static int __devinit twl4030_madc_hwmon_probe(struct platform_device *pdev) ...@@ -107,7 +106,7 @@ static int __devinit twl4030_madc_hwmon_probe(struct platform_device *pdev)
hwmon = hwmon_device_register(&pdev->dev); hwmon = hwmon_device_register(&pdev->dev);
if (IS_ERR(hwmon)) { if (IS_ERR(hwmon)) {
dev_err(&pdev->dev, "hwmon_device_register failed.\n"); dev_err(&pdev->dev, "hwmon_device_register failed.\n");
status = PTR_ERR(hwmon); ret = PTR_ERR(hwmon);
goto err_reg; goto err_reg;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment