]> git.karo-electronics.de Git - karo-tx-linux.git/blobdiff - drivers/thermal/armada_thermal.c
Merge branches 'misc', 'drv_cleanup', 'devm-cleanup' and 'ti-soc' of .git into next
[karo-tx-linux.git] / drivers / thermal / armada_thermal.c
index 7c603b854e87fb3ba6c3fb1f45f5ed34683aa1f9..5e53212b984fd183f329a0fb7f7b48e778199f12 100644 (file)
@@ -169,21 +169,11 @@ static int armada_thermal_probe(struct platform_device *pdev)
                return -ENOMEM;
 
        res = platform_get_resource(pdev, IORESOURCE_MEM, 0);
-       if (!res) {
-               dev_err(&pdev->dev, "Failed to get platform resource\n");
-               return -ENODEV;
-       }
-
        priv->sensor = devm_ioremap_resource(&pdev->dev, res);
        if (IS_ERR(priv->sensor))
                return PTR_ERR(priv->sensor);
 
        res = platform_get_resource(pdev, IORESOURCE_MEM, 1);
-       if (!res) {
-               dev_err(&pdev->dev, "Failed to get platform resource\n");
-               return -ENODEV;
-       }
-
        priv->control = devm_ioremap_resource(&pdev->dev, res);
        if (IS_ERR(priv->control))
                return PTR_ERR(priv->control);
@@ -210,7 +200,6 @@ static int armada_thermal_exit(struct platform_device *pdev)
                platform_get_drvdata(pdev);
 
        thermal_zone_device_unregister(armada_thermal);
-       platform_set_drvdata(pdev, NULL);
 
        return 0;
 }