Skip to content

Commit d6137f2

Browse files
Xichao Zhaodtor
authored andcommitted
Input: qnap-mcu-input - omit error message when memory allocation fails
The dev_err_probe() doesn't do anything when error is '-ENOMEM'. Therefore, remove the useless call to dev_err_probe(), and just return the value instead. Signed-off-by: Xichao Zhao <zhao.xichao@vivo.com> Link: https://patch.msgid.link/20250822034751.244248-2-zhao.xichao@vivo.com Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
1 parent fd1bf70 commit d6137f2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/input/misc/qnap-mcu-input.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ static int qnap_mcu_input_probe(struct platform_device *pdev)
103103

104104
input = devm_input_allocate_device(dev);
105105
if (!input)
106-
return dev_err_probe(dev, -ENOMEM, "no memory for input device\n");
106+
return -ENOMEM;
107107

108108
idev->input = input;
109109
idev->dev = dev;

0 commit comments

Comments
 (0)