summaryrefslogtreecommitdiff
path: root/drivers/thermal/armada_thermal.c
diff options
context:
space:
mode:
authorSimon Horman <horms+renesas@verge.net.au>2018-07-24 14:14:13 +0300
committerEduardo Valentin <edubezval@gmail.com>2018-07-28 02:45:36 +0300
commit542cdf4068049458e1411b120bd5a4bbe3ddc49a (patch)
tree7ccbed5138706f878025a39137c6273ae6f13bee /drivers/thermal/armada_thermal.c
parentc0c04707033c71d0490a412b0a941d87011949a3 (diff)
downloadlinux-542cdf4068049458e1411b120bd5a4bbe3ddc49a.tar.xz
thermal: rcar_thermal: avoid NULL dereference in absence of IRQ resources
Ensure that the base address used by a call to rcar_thermal_common_write() may be NULL if the SOC supports interrupts for use with the thermal device but none are defined in DT as is the case for R-Car H1 (r8a7779). Guard against this condition to prevent a NULL dereference when the device is probed. Tested on: * R-Mobile APE6 (r8a73a4) / APE6EVM * R-Car H1 (r8a7779) / Marzen * R-Car H2 (r8a7790) / Lager * R-Car M2-W (r8a7791) / Koelsch * R-Car M2-N (r8a7793) / Gose * R-Car D3 ES1.0 (r8a77995) / Draak Fixes: 1969d9dc2079 ("thermal: rcar_thermal: add r8a77995 support") Signed-off-by: Simon Horman <horms+renesas@verge.net.au> Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: Eduardo Valentin <edubezval@gmail.com>
Diffstat (limited to 'drivers/thermal/armada_thermal.c')
0 files changed, 0 insertions, 0 deletions