diff options
Diffstat (limited to 'drivers/regulator/core.c')
-rw-r--r-- | drivers/regulator/core.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c index 74e00d7791..a767e383fb 100644 --- a/drivers/regulator/core.c +++ b/drivers/regulator/core.c @@ -168,6 +168,9 @@ int of_regulator_register(struct regulator_dev *rd, struct device_node *node) name = of_get_property(node, "regulator-name", NULL); ri = __regulator_register(rd, name); + if (IS_ERR(ri)) + return PTR_ERR(ri); + ri->node = node; of_property_read_u32(node, "regulator-enable-ramp-delay", |