]> git.dujemihanovic.xyz Git - linux.git/commit
cpufreq: apple-soc: Fix an IS_ERR() vs NULL check
authorDan Carpenter <error27@gmail.com>
Mon, 27 Feb 2023 10:07:09 +0000 (13:07 +0300)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Wed, 1 Mar 2023 18:34:54 +0000 (19:34 +0100)
commitf43523620f646c89ffd8ada840a0068290e51266
tree23f5dcbe4a2fe4d02b0690607cb61b61b37cb93e
parent5bd289f69bc145fa10927a6883502a0e7cbcb811
cpufreq: apple-soc: Fix an IS_ERR() vs NULL check

The of_iomap() function returns NULL if it fails.  It never returns
error pointers.  Fix the check accordingly.

Fixes: 6286bbb40576 ("cpufreq: apple-soc: Add new driver to control Apple SoC CPU P-states")
Signed-off-by: Dan Carpenter <error27@gmail.com>
Reviewed-by: Eric Curtin <ecurtin@redhat.com>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
drivers/cpufreq/apple-soc-cpufreq.c