Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 2fed97d9 authored by Jeff Ohlstein's avatar Jeff Ohlstein Committed by Stephen Boyd
Browse files

thermal: msm8960_tsens: nullify tmdev when early_init fails



The initialization code uses the tmdev variable as an indicator as to
whether or not early initialization succeeded. However, when early init
fails, it only kfrees the pointer, it doesn't set it to NULL. This
causes us to dereference the now-freed pointer.

Additionally, squash the message that prints each time we fail to read
the temperature sensor, and print a warning to the kernel log when tsens
calibration data is not present.

Change-Id: Iab400cac687cdbc36d8c69541675c29a0b82c704
Signed-off-by: default avatarJeff Ohlstein <johlstei@codeaurora.org>
Signed-off-by: default avatarDavid Brown <davidb@codeaurora.org>
parent 7fcfde34
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment