lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-Id: <20240126105412.1353037-1-ingyujang25@unist.ac.kr>
Date: Fri, 26 Jan 2024 19:54:12 +0900
From: Ingyu Jang <ingyujang25@...st.ac.kr>
To: gregkh@...uxfoundation.org
Cc: linux-usb@...r.kernel.org,
	linux-kernel@...r.kernel.org,
	ysjeon@...st.ac.kr
Subject: [PATCH] Remove redundant check for usb_generic_driver_probe

usb_generic_driver_probe only returns 0.
Inside this function, there are only errors that are marked as not fatal.
No need to change usb_generic_driver_probe to return error, only remove redundant error check.
---
 drivers/usb/core/driver.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/usb/core/driver.c b/drivers/usb/core/driver.c
index e01b1913d02b..b6274580b7ca 100644
--- a/drivers/usb/core/driver.c
+++ b/drivers/usb/core/driver.c
@@ -266,8 +266,6 @@ static int usb_probe_device(struct device *dev)
 
 	if (udriver->generic_subclass)
 		error = usb_generic_driver_probe(udev);
-	if (error)
-		return error;
 
 	/* Probe the USB device with the driver in hand, but only
 	 * defer to a generic driver in case the current USB
-- 
2.34.1


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ