From fb572e2f2347ece90e1b1002fb1595d57b8aed93 Mon Sep 17 00:00:00 2001 From: Denis Benato Date: Fri, 19 Jun 2026 00:11:00 +0000 Subject: [PATCH] HID: asus: remove extraneous OOM error If devm_kzalloc fails an allocation error is already being reported: no need to repeat it. For new code this behavior is disincentivized and checkpatch.pl reports a warning. Reviewed-by: Antheas Kapenekakis Signed-off-by: Denis Benato Signed-off-by: Jiri Kosina --- drivers/hid/hid-asus.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/hid/hid-asus.c b/drivers/hid/hid-asus.c index 98597e097e71..c7850ae2f8e1 100644 --- a/drivers/hid/hid-asus.c +++ b/drivers/hid/hid-asus.c @@ -1379,10 +1379,8 @@ static int asus_probe(struct hid_device *hdev, const struct hid_device_id *id) int ret; drvdata = devm_kzalloc(&hdev->dev, sizeof(*drvdata), GFP_KERNEL); - if (drvdata == NULL) { - hid_err(hdev, "Can't alloc Asus descriptor\n"); + if (drvdata == NULL) return -ENOMEM; - } hid_set_drvdata(hdev, drvdata);