diff options
author | Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> | 2023-04-15 12:43:04 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-04-20 14:15:07 +0200 |
commit | 4ccb0fc2a212d11e5491a4a1e705d6d84463c3a5 (patch) | |
tree | 1e7d1be25466d6b0571f95f65ff2ec7ed203185f /drivers/w1 | |
parent | w1: omap-hdq: remove unnecessary ENOMEM messages (diff) | |
download | linux-4ccb0fc2a212d11e5491a4a1e705d6d84463c3a5.tar.xz linux-4ccb0fc2a212d11e5491a4a1e705d6d84463c3a5.zip |
w1: gpio: remove unnecessary ENOMEM messages
Core already prints detailed reports on out of memory:
WARNING: Possible unnecessary 'out of memory' message
Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org>
Link: https://lore.kernel.org/r/20230415104304.104134-16-krzysztof.kozlowski@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/w1')
-rw-r--r-- | drivers/w1/masters/w1-gpio.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/drivers/w1/masters/w1-gpio.c b/drivers/w1/masters/w1-gpio.c index d4632aace402..ac7ad63f8f8d 100644 --- a/drivers/w1/masters/w1-gpio.c +++ b/drivers/w1/masters/w1-gpio.c @@ -101,10 +101,8 @@ static int w1_gpio_probe(struct platform_device *pdev) master = devm_kzalloc(dev, sizeof(struct w1_bus_master), GFP_KERNEL); - if (!master) { - dev_err(dev, "Out of memory\n"); + if (!master) return -ENOMEM; - } pdata->gpiod = devm_gpiod_get_index(dev, NULL, 0, gflags); if (IS_ERR(pdata->gpiod)) { |