summaryrefslogtreecommitdiffstats
path: root/drivers/macintosh/adb.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2008-05-21 21:52:33 +0200
committerGreg Kroah-Hartman <gregkh@suse.de>2008-07-22 06:54:43 +0200
commit97cd790e3a9cf2855676a461ac5c448f5843017d (patch)
tree53d59a64ec1ce983fcc15f37640a2b6a22f94a5b /drivers/macintosh/adb.c
parentdevice create: isdn: convert device_create to device_create_drvdata (diff)
downloadlinux-97cd790e3a9cf2855676a461ac5c448f5843017d.tar.xz
linux-97cd790e3a9cf2855676a461ac5c448f5843017d.zip
device create: macintosh: convert device_create to device_create_drvdata
device_create() is race-prone, so use the race-free device_create_drvdata() instead as device_create() is going away. Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/macintosh/adb.c')
-rw-r--r--drivers/macintosh/adb.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/macintosh/adb.c b/drivers/macintosh/adb.c
index e5d446804d32..cae52485208a 100644
--- a/drivers/macintosh/adb.c
+++ b/drivers/macintosh/adb.c
@@ -862,7 +862,8 @@ adbdev_init(void)
adb_dev_class = class_create(THIS_MODULE, "adb");
if (IS_ERR(adb_dev_class))
return;
- device_create(adb_dev_class, NULL, MKDEV(ADB_MAJOR, 0), "adb");
+ device_create_drvdata(adb_dev_class, NULL, MKDEV(ADB_MAJOR, 0), NULL,
+ "adb");
platform_device_register(&adb_pfdev);
platform_driver_probe(&adb_pfdrv, adb_dummy_probe);