diff options
Diffstat (limited to 'drivers/regulator/fixed.c')
-rw-r--r-- | drivers/regulator/fixed.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/regulator/fixed.c b/drivers/regulator/fixed.c index cdc674fb46c3..9c7f956d57c4 100644 --- a/drivers/regulator/fixed.c +++ b/drivers/regulator/fixed.c | |||
@@ -70,12 +70,14 @@ static int regulator_fixed_voltage_probe(struct platform_device *pdev) | |||
70 | 70 | ||
71 | drvdata = kzalloc(sizeof(struct fixed_voltage_data), GFP_KERNEL); | 71 | drvdata = kzalloc(sizeof(struct fixed_voltage_data), GFP_KERNEL); |
72 | if (drvdata == NULL) { | 72 | if (drvdata == NULL) { |
73 | dev_err(&pdev->dev, "Failed to allocate device data\n"); | ||
73 | ret = -ENOMEM; | 74 | ret = -ENOMEM; |
74 | goto err; | 75 | goto err; |
75 | } | 76 | } |
76 | 77 | ||
77 | drvdata->desc.name = kstrdup(config->supply_name, GFP_KERNEL); | 78 | drvdata->desc.name = kstrdup(config->supply_name, GFP_KERNEL); |
78 | if (drvdata->desc.name == NULL) { | 79 | if (drvdata->desc.name == NULL) { |
80 | dev_err(&pdev->dev, "Failed to allocate supply name\n"); | ||
79 | ret = -ENOMEM; | 81 | ret = -ENOMEM; |
80 | goto err; | 82 | goto err; |
81 | } | 83 | } |
@@ -90,6 +92,7 @@ static int regulator_fixed_voltage_probe(struct platform_device *pdev) | |||
90 | config->init_data, drvdata); | 92 | config->init_data, drvdata); |
91 | if (IS_ERR(drvdata->dev)) { | 93 | if (IS_ERR(drvdata->dev)) { |
92 | ret = PTR_ERR(drvdata->dev); | 94 | ret = PTR_ERR(drvdata->dev); |
95 | dev_err(&pdev->dev, "Failed to register regulator: %d\n", ret); | ||
93 | goto err_name; | 96 | goto err_name; |
94 | } | 97 | } |
95 | 98 | ||