|
@@ -292,10 +292,9 @@ static int max8907_regulator_probe(struct platform_device *pdev)
|
|
|
return ret;
|
|
|
|
|
|
pmic = devm_kzalloc(&pdev->dev, sizeof(*pmic), GFP_KERNEL);
|
|
|
- if (!pmic) {
|
|
|
- dev_err(&pdev->dev, "Failed to alloc pmic\n");
|
|
|
+ if (!pmic)
|
|
|
return -ENOMEM;
|
|
|
- }
|
|
|
+
|
|
|
platform_set_drvdata(pdev, pmic);
|
|
|
|
|
|
memcpy(pmic->desc, max8907_regulators, sizeof(pmic->desc));
|