mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-29 23:53:32 +00:00
regulator: core: Use IS_ERR_OR_NULL()
Use IS_ERR_OR_NULL() rather than open coding it. Signed-off-by: Viresh Kumar <viresh.kumar@linaro.org> Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
d3fb980014
commit
9357684271
1 changed files with 1 additions and 1 deletions
|
@ -1588,7 +1588,7 @@ static void _regulator_put(struct regulator *regulator)
|
||||||
{
|
{
|
||||||
struct regulator_dev *rdev;
|
struct regulator_dev *rdev;
|
||||||
|
|
||||||
if (regulator == NULL || IS_ERR(regulator))
|
if (IS_ERR_OR_NULL(regulator))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
lockdep_assert_held_once(®ulator_list_mutex);
|
lockdep_assert_held_once(®ulator_list_mutex);
|
||||||
|
|
Loading…
Reference in a new issue