Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 374565
b: refs/heads/master
c: c7a8b9d
h: refs/heads/master
i:
  374563: 2ac2c9d
v: v3
  • Loading branch information
Eduardo Valentin authored and Zhang Rui committed Apr 24, 2013
1 parent 85e6898 commit c920aa3
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 14 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a502be187385666441d4d6fe66efd4179a74d779
refs/heads/master: c7a8b9d91642cb858862de613652aad5d21632be
14 changes: 3 additions & 11 deletions trunk/drivers/thermal/exynos_thermal.c
Original file line number Diff line number Diff line change
Expand Up @@ -854,10 +854,6 @@ static const struct of_device_id exynos_tmu_match[] = {
.compatible = "samsung,exynos4210-tmu",
.data = (void *)EXYNOS4210_TMU_DRV_DATA,
},
{
.compatible = "samsung,exynos4412-tmu",
.data = (void *)EXYNOS_TMU_DRV_DATA,
},
{
.compatible = "samsung,exynos5250-tmu",
.data = (void *)EXYNOS_TMU_DRV_DATA,
Expand Down Expand Up @@ -941,16 +937,12 @@ static int exynos_tmu_probe(struct platform_device *pdev)
return ret;
}

data->clk = devm_clk_get(&pdev->dev, "tmu_apbif");
data->clk = clk_get(NULL, "tmu_apbif");
if (IS_ERR(data->clk)) {
dev_err(&pdev->dev, "Failed to get clock\n");
return PTR_ERR(data->clk);
}

ret = clk_prepare(data->clk);
if (ret)
return ret;

if (pdata->type == SOC_ARCH_EXYNOS ||
pdata->type == SOC_ARCH_EXYNOS4210)
data->soc = pdata->type;
Expand Down Expand Up @@ -1002,7 +994,7 @@ static int exynos_tmu_probe(struct platform_device *pdev)
return 0;
err_clk:
platform_set_drvdata(pdev, NULL);
clk_unprepare(data->clk);
clk_put(data->clk);
return ret;
}

Expand All @@ -1014,7 +1006,7 @@ static int exynos_tmu_remove(struct platform_device *pdev)

exynos_unregister_thermal();

clk_unprepare(data->clk);
clk_put(data->clk);

platform_set_drvdata(pdev, NULL);

Expand Down
4 changes: 2 additions & 2 deletions trunk/drivers/thermal/thermal_core.c
Original file line number Diff line number Diff line change
Expand Up @@ -1301,7 +1301,7 @@ thermal_cooling_device_register(char *type, void *devdata,
return ERR_PTR(result);
}

strcpy(cdev->type, type ? : "");
strlcpy(cdev->type, type ? : "", sizeof(cdev->type));
mutex_init(&cdev->lock);
INIT_LIST_HEAD(&cdev->thermal_instances);
cdev->ops = ops;
Expand Down Expand Up @@ -1606,7 +1606,7 @@ struct thermal_zone_device *thermal_zone_device_register(const char *type,
return ERR_PTR(result);
}

strcpy(tz->type, type ? : "");
strlcpy(tz->type, type ? : "", sizeof(tz->type));
tz->ops = ops;
tz->tzp = tzp;
tz->device.class = &thermal_class;
Expand Down

0 comments on commit c920aa3

Please sign in to comment.