]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
net: usb: asix_devices: Check return value of usbnet_get_endpoints
authorMiaoqian Lin <linmq006@gmail.com>
Sun, 26 Oct 2025 16:43:16 +0000 (00:43 +0800)
committerJakub Kicinski <kuba@kernel.org>
Thu, 30 Oct 2025 00:51:48 +0000 (17:51 -0700)
commitdc89548c6926d68dfdda11bebc1a5258bc41d887
tree32ef7da576a2d23a12e5ae636b04fdf9a46488f0
parentac345c5fff55262a51dad43bf8724c3d5d1fb006
net: usb: asix_devices: Check return value of usbnet_get_endpoints

The code did not check the return value of usbnet_get_endpoints.
Add checks and return the error if it fails to transfer the error.

Found via static anlaysis and this is similar to
commit 07161b2416f7 ("sr9800: Add check for usbnet_get_endpoints").

Fixes: 933a27d39e0e ("USB: asix - Add AX88178 support and many other changes")
Fixes: 2e55cc7210fe ("[PATCH] USB: usbnet (3/9) module for ASIX Ethernet adapters")
Cc: stable@vger.kernel.org
Signed-off-by: Miaoqian Lin <linmq006@gmail.com>
Link: https://patch.msgid.link/20251026164318.57624-1-linmq006@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
drivers/net/usb/asix_devices.c