diff options
author | Lukasz Majewski <l.majewski@samsung.com> | 2015-01-28 10:25:22 -0500 |
---|---|---|
committer | Eduardo Valentin <edubezval@gmail.com> | 2015-01-28 00:29:02 -0500 |
commit | eccb60145415dd8e171687cd1694f50141f50d6d (patch) | |
tree | 24c062368548f869e47f9b28197a5f2934ff65fa | |
parent | d3a5247e5332eb56d8f4833570b6d88f26709b18 (diff) |
thermal: exynos: Correct sanity check at exynos_report_trigger() function
Up till now, by mistake, wrong variable was tested against being NULL.
Since exynos_report_trigger() is always called with valid p pointer,
it is only necessary to check if a valid thermal zone device is passed.
Reported-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Lukasz Majewski <l.majewski@samsung.com>
Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
-rw-r--r-- | drivers/thermal/samsung/exynos_tmu.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/thermal/samsung/exynos_tmu.c b/drivers/thermal/samsung/exynos_tmu.c index 864eec8f5164..b6a6e90ba340 100644 --- a/drivers/thermal/samsung/exynos_tmu.c +++ b/drivers/thermal/samsung/exynos_tmu.c | |||
@@ -172,8 +172,8 @@ static void exynos_report_trigger(struct exynos_tmu_data *p) | |||
172 | unsigned long temp; | 172 | unsigned long temp; |
173 | unsigned int i; | 173 | unsigned int i; |
174 | 174 | ||
175 | if (!p) { | 175 | if (!tz) { |
176 | pr_err("Wrong temperature configuration data\n"); | 176 | pr_err("No thermal zone device defined\n"); |
177 | return; | 177 | return; |
178 | } | 178 | } |
179 | 179 | ||