From: Viresh Kumar Date: Mon, 17 Aug 2015 07:00:58 +0000 (+0530) Subject: regulator: core: Use IS_ERR_OR_NULL() X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=93576842718edf302b03f30b9915d3e704b0c78a;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git regulator: core: Use IS_ERR_OR_NULL() Use IS_ERR_OR_NULL() rather than open coding it. Signed-off-by: Viresh Kumar Signed-off-by: Mark Brown --- diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c index 999a94b9735e..5d61eb8f2a79 100644 --- a/drivers/regulator/core.c +++ b/drivers/regulator/core.c @@ -1588,7 +1588,7 @@ static void _regulator_put(struct regulator *regulator) { struct regulator_dev *rdev; - if (regulator == NULL || IS_ERR(regulator)) + if (IS_ERR_OR_NULL(regulator)) return; lockdep_assert_held_once(®ulator_list_mutex);