device create: mips: 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: Ralf Baechle <ralf@linux-mips.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
Greg Kroah-Hartman
2008-05-21 12:52:33 -07:00
parent 97cd790e3a
commit 43f98747d4
2 changed files with 4 additions and 3 deletions

View File

@@ -576,7 +576,8 @@ static int __init sbprof_tb_init(void)
tb_class = tbc;
dev = device_create(tbc, NULL, MKDEV(SBPROF_TB_MAJOR, 0), "tb");
dev = device_create_drvdata(tbc, NULL, MKDEV(SBPROF_TB_MAJOR, 0),
NULL, "tb");
if (IS_ERR(dev)) {
err = PTR_ERR(dev);
goto out_class;