All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/3] driver core: bus: Fix issues related to bus_rescan_devices_helper()
@ 2024-09-04 12:56 Zijun Hu
  2024-09-04 12:56 ` [PATCH 1/3] driver core: Mark impossible return values of bus_type's match() with unlikely() Zijun Hu
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Zijun Hu @ 2024-09-04 12:56 UTC (permalink / raw)
  To: Greg Kroah-Hartman, Rafael J. Wysocki; +Cc: Zijun Hu, linux-kernel, Zijun Hu

This patch series is to fix issues related to bus_rescan_devices_helper().

The function is currently used to scan drivers for both single and
all devices, but its return value can not cover expectations for both
scenarios as explained below:

for single device, user may care about precise scanning result, so
should not collapse error codes.

for all devices, user may want to scan drivers for devices as many as
possible, so need to ignore inconsequential error codes for a device to
continue to scan drivers for remaining devices.

Fixed by implementing bus_rescan_single_device() for single device and
correcting bus_rescan_devices_helper() for all devices.

Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
---
Zijun Hu (3):
      driver core: Mark impossible return values of bus_type's match() with unlikely()
      driver core: bus: Give error prompt for storing bus attribute drivers_probe failure
      driver core: bus: Correct API bus_rescan_devices() behavior

 drivers/base/bus.c         | 64 ++++++++++++++++++++++++++++++++++++----------
 drivers/base/dd.c          | 16 +++++++++---
 include/linux/device/bus.h |  9 +++----
 3 files changed, 67 insertions(+), 22 deletions(-)
---
base-commit: 888f67e621dda5c2804a696524e28d0ca4cf0a80
change-id: 20240830-bus_match_unlikely-abe9334bcfd2

Best regards,
-- 
Zijun Hu <quic_zijuhu@quicinc.com>


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2024-09-04 15:45 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-09-04 12:56 [PATCH 0/3] driver core: bus: Fix issues related to bus_rescan_devices_helper() Zijun Hu
2024-09-04 12:56 ` [PATCH 1/3] driver core: Mark impossible return values of bus_type's match() with unlikely() Zijun Hu
2024-09-04 13:53   ` Greg Kroah-Hartman
2024-09-04 15:45     ` Zijun Hu
2024-09-04 12:56 ` [PATCH 2/3] driver core: bus: Give error prompt for storing bus attribute drivers_probe failure Zijun Hu
2024-09-04 12:56 ` [PATCH 3/3] driver core: bus: Correct API bus_rescan_devices() behavior Zijun Hu
2024-09-04 13:54   ` Greg Kroah-Hartman
2024-09-04 14:26     ` Zijun Hu
2024-09-04 14:44       ` Greg Kroah-Hartman
2024-09-04 15:42         ` Zijun Hu

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.