Driver core: allow certain drivers prohibit bind/unbind via sysfs
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Tue, 13 Oct 2009 03:17:41 +0000 (20:17 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Fri, 30 Oct 2009 21:59:51 +0000 (14:59 -0700)
commit1a6f2a7512021ceae3c4201c7aab07f032e9ce91
tree03fdca9848003b3a6fda57113b3e750ec1e22a55
parent39acbc12affcaa23ef1d887ba3d197baca8e6e47
Driver core: allow certain drivers prohibit bind/unbind via sysfs

Platform drivers registered via platform_driver_probe() can be bound
to devices only once, upon registration, because discard their probe()
routines to save memory. Unbinding the driver through sysfs 'unbind'
leaves the device stranded and confuses users so let's not create
bind and unbind attributes for such drivers.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Cc: √Čric Piel <eric.piel@tremplin-utc.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/base/bus.c
drivers/base/platform.c
include/linux/device.h