summaryrefslogtreecommitdiffstats
path: root/drivers/macintosh
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2008-05-21 12:52:33 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2008-07-21 21:54:43 -0700
commit97cd790e3a9cf2855676a461ac5c448f5843017d (patch)
tree53d59a64ec1ce983fcc15f37640a2b6a22f94a5b /drivers/macintosh
parent24d0b416f988fcdfa2615a25c7c33c21cc2a65a9 (diff)
downloadkernel-crypto-97cd790e3a9cf2855676a461ac5c448f5843017d.tar.gz
kernel-crypto-97cd790e3a9cf2855676a461ac5c448f5843017d.tar.xz
kernel-crypto-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')
-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 e5d446804d3..cae52485208 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);