]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
hwmon: (coretemp) Remove redundant platform_set_drvdata()
authorSachin Kamat <sachin.kamat@linaro.org>
Fri, 3 May 2013 09:43:37 +0000 (15:13 +0530)
committerGuenter Roeck <linux@roeck-us.net>
Fri, 21 Jun 2013 17:05:08 +0000 (10:05 -0700)
Commit 0998d06310 (device-core: Ensure drvdata = NULL when no
driver is bound) removes the need to set driver data field to
NULL.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Cc: Rudolf Marek <r.marek@assembler.cz>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
drivers/hwmon/coretemp.c

index 658ce3a8717f6af0fa44f8eec4707d91bd44988d..ade35cf3f48880ee2dad3744428624bbd71d76d3 100644 (file)
@@ -578,7 +578,6 @@ static int coretemp_probe(struct platform_device *pdev)
 
 exit_name:
        device_remove_file(&pdev->dev, &pdata->name_attr);
-       platform_set_drvdata(pdev, NULL);
 exit_free:
        kfree(pdata);
        return err;
@@ -595,7 +594,6 @@ static int coretemp_remove(struct platform_device *pdev)
 
        device_remove_file(&pdev->dev, &pdata->name_attr);
        hwmon_device_unregister(pdata->hwmon_dev);
-       platform_set_drvdata(pdev, NULL);
        kfree(pdata);
        return 0;
 }