diff options
author | Nicolin Chen <nicoleotsuka@gmail.com> | 2017-09-05 03:41:16 -0400 |
---|---|---|
committer | Eduardo Valentin <edubezval@gmail.com> | 2017-10-31 22:32:13 -0400 |
commit | 1fba81cc09bd3cd71ca43cd66ca7223217eaa054 (patch) | |
tree | 0bc2af66a83f6ffa11d089596ec153f886cfdebe | |
parent | fec3624f0bcdb6b20ef9ccf9d9d55d0d75d776f8 (diff) |
thermal: tegra: remove null check for dev pointer
The dev pointer is going through a null check after a dereference.
So this patch removes that useless check since the driver does not
pass a null dev pointer in any case.
Signed-off-by: Nicolin Chen <nicoleotsuka@gmail.com>
Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
-rw-r--r-- | drivers/thermal/tegra/soctherm.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/thermal/tegra/soctherm.c b/drivers/thermal/tegra/soctherm.c index 7d2db23d71a3..075db1de5e53 100644 --- a/drivers/thermal/tegra/soctherm.c +++ b/drivers/thermal/tegra/soctherm.c | |||
@@ -483,7 +483,7 @@ static int throttrip_program(struct device *dev, | |||
483 | unsigned int throt; | 483 | unsigned int throt; |
484 | u32 r, reg_off; | 484 | u32 r, reg_off; |
485 | 485 | ||
486 | if (!dev || !sg || !stc || !stc->init) | 486 | if (!sg || !stc || !stc->init) |
487 | return -EINVAL; | 487 | return -EINVAL; |
488 | 488 | ||
489 | temp = enforce_temp_range(dev, trip_temp) / ts->soc->thresh_grain; | 489 | temp = enforce_temp_range(dev, trip_temp) / ts->soc->thresh_grain; |