]> www.infradead.org Git - users/jedix/linux-maple.git/commit
driver core: class: Correct WARN() message in APIs class_(for_each|find)_device()
authorZijun Hu <quic_zijuhu@quicinc.com>
Tue, 5 Nov 2024 00:20:23 +0000 (08:20 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 12 Nov 2024 12:10:43 +0000 (13:10 +0100)
commitf659e8fb8f075dfcc0bd6800935f78ec021c7f25
tree217919edc22ec7ad5c74ba10b88d9cc3627f9fce
parent2d038efcb4b3e3b9a1d117b3c971364926e59082
driver core: class: Correct WARN() message in APIs class_(for_each|find)_device()

For both API class_for_each_device(const struct class *class, ...) and
class_find_device(const struct class *class, ...), their WARN() messages
prompt @class was not initialized when suffer class_to_subsys(@class)
error, but the error actually means @class was not registered, so these
warning messages are not accurate.

Fix by replacing term initialized with registered within these messages.

Signed-off-by: Zijun Hu <quic_zijuhu@quicinc.com>
Link: https://lore.kernel.org/r/20241105-class_fix-v1-2-80866f9994a5@quicinc.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/base/class.c