diff options
| author | Sachin Kamat <sachin.kamat@linaro.org> | 2014-02-20 03:53:20 -0500 |
|---|---|---|
| committer | Mark Brown <broonie@linaro.org> | 2014-02-20 07:03:14 -0500 |
| commit | 5730aa57de68be409bfab7714e4b2d4cfa707624 (patch) | |
| tree | 272ca42da493a656e326f21e7008cf739de1d96b | |
| parent | 38dbfb59d1175ef458d006556061adeaa8751b72 (diff) | |
regulator: wm831x-dcdc: Remove redundant error message
kzalloc prints its own OOM message upon failure.
Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Mark Brown <broonie@linaro.org>
| -rw-r--r-- | drivers/regulator/wm831x-dcdc.c | 16 |
1 files changed, 4 insertions, 12 deletions
diff --git a/drivers/regulator/wm831x-dcdc.c b/drivers/regulator/wm831x-dcdc.c index 04cf9c16ef23..0d88a82ab2a2 100644 --- a/drivers/regulator/wm831x-dcdc.c +++ b/drivers/regulator/wm831x-dcdc.c | |||
| @@ -469,10 +469,8 @@ static int wm831x_buckv_probe(struct platform_device *pdev) | |||
| 469 | 469 | ||
| 470 | dcdc = devm_kzalloc(&pdev->dev, sizeof(struct wm831x_dcdc), | 470 | dcdc = devm_kzalloc(&pdev->dev, sizeof(struct wm831x_dcdc), |
| 471 | GFP_KERNEL); | 471 | GFP_KERNEL); |
| 472 | if (dcdc == NULL) { | 472 | if (!dcdc) |
| 473 | dev_err(&pdev->dev, "Unable to allocate private data\n"); | ||
| 474 | return -ENOMEM; | 473 | return -ENOMEM; |
| 475 | } | ||
| 476 | 474 | ||
| 477 | dcdc->wm831x = wm831x; | 475 | dcdc->wm831x = wm831x; |
| 478 | 476 | ||
| @@ -622,10 +620,8 @@ static int wm831x_buckp_probe(struct platform_device *pdev) | |||
| 622 | 620 | ||
| 623 | dcdc = devm_kzalloc(&pdev->dev, sizeof(struct wm831x_dcdc), | 621 | dcdc = devm_kzalloc(&pdev->dev, sizeof(struct wm831x_dcdc), |
| 624 | GFP_KERNEL); | 622 | GFP_KERNEL); |
| 625 | if (dcdc == NULL) { | 623 | if (!dcdc) |
| 626 | dev_err(&pdev->dev, "Unable to allocate private data\n"); | ||
| 627 | return -ENOMEM; | 624 | return -ENOMEM; |
| 628 | } | ||
| 629 | 625 | ||
| 630 | dcdc->wm831x = wm831x; | 626 | dcdc->wm831x = wm831x; |
| 631 | 627 | ||
| @@ -752,10 +748,8 @@ static int wm831x_boostp_probe(struct platform_device *pdev) | |||
| 752 | return -ENODEV; | 748 | return -ENODEV; |
| 753 | 749 | ||
| 754 | dcdc = devm_kzalloc(&pdev->dev, sizeof(struct wm831x_dcdc), GFP_KERNEL); | 750 | dcdc = devm_kzalloc(&pdev->dev, sizeof(struct wm831x_dcdc), GFP_KERNEL); |
| 755 | if (dcdc == NULL) { | 751 | if (!dcdc) |
| 756 | dev_err(&pdev->dev, "Unable to allocate private data\n"); | ||
| 757 | return -ENOMEM; | 752 | return -ENOMEM; |
| 758 | } | ||
| 759 | 753 | ||
| 760 | dcdc->wm831x = wm831x; | 754 | dcdc->wm831x = wm831x; |
| 761 | 755 | ||
| @@ -842,10 +836,8 @@ static int wm831x_epe_probe(struct platform_device *pdev) | |||
| 842 | dev_dbg(&pdev->dev, "Probing EPE%d\n", id + 1); | 836 | dev_dbg(&pdev->dev, "Probing EPE%d\n", id + 1); |
| 843 | 837 | ||
| 844 | dcdc = devm_kzalloc(&pdev->dev, sizeof(struct wm831x_dcdc), GFP_KERNEL); | 838 | dcdc = devm_kzalloc(&pdev->dev, sizeof(struct wm831x_dcdc), GFP_KERNEL); |
| 845 | if (dcdc == NULL) { | 839 | if (!dcdc) |
| 846 | dev_err(&pdev->dev, "Unable to allocate private data\n"); | ||
| 847 | return -ENOMEM; | 840 | return -ENOMEM; |
| 848 | } | ||
| 849 | 841 | ||
| 850 | dcdc->wm831x = wm831x; | 842 | dcdc->wm831x = wm831x; |
| 851 | 843 | ||
