regulator: fan53555: Use PTR_RET function

Used PTR_RET function instead of IS_ERR and PTR_ERR.
Patch found using coccinelle.

Signed-off-by: Alexandru Gheorghiu <gheorghiuandru@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
This commit is contained in:
Alexandru Gheorghiu 2013-03-18 23:35:31 +02:00 committed by Mark Brown
parent a937536b86
commit eb8ad60991
1 changed files with 1 additions and 3 deletions

View File

@ -219,9 +219,7 @@ static int fan53555_regulator_register(struct fan53555_device_info *di,
rdesc->owner = THIS_MODULE;
di->rdev = regulator_register(&di->desc, config);
if (IS_ERR(di->rdev))
return PTR_ERR(di->rdev);
return 0;
return PTR_RET(di->rdev);
}