diff options
author | Ben Dooks <ben@fluff.org> | 2008-03-05 00:09:06 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2008-04-20 04:10:24 +0200 |
commit | da009f39f85a3ee9deeb10f0f05ddd4efdd67020 (patch) | |
tree | ba04c23e0d5a831705f0f9bfe1a9be10aff99a78 /fs | |
parent | driver core: cpu: fix section mismatch in cpu.c:store_online (diff) | |
download | linux-da009f39f85a3ee9deeb10f0f05ddd4efdd67020.tar.xz linux-da009f39f85a3ee9deeb10f0f05ddd4efdd67020.zip |
sysdev: detect multiple driver registrations
I've just found how easy it is to accidentally register a sysdev_driver for
two different classes. When this happens, bad things happen as the
sysdev_driver structure keeps has the list entry for the driver
registration.
The following patch makes a WARN_ON() if this happens, although I think
BUG_ON or returning -EAGAIN could also be valid responses to this.
Signed-off-by: Ben Dooks <ben@fluff.org>
Cc: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to '')
0 files changed, 0 insertions, 0 deletions