aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/s390/char/raw3270.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@suse.de>2008-05-21 15:52:33 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2008-07-22 00:54:44 -0400
commit05675de250c4efcefbd488e6a556639b63898af8 (patch)
tree13e87c0219764a0f125d296c3cadcbdc943074af /drivers/s390/char/raw3270.c
parente17da9c4c5fc19e16ddcb0ae020ee4425ca0c96f (diff)
device create: s390: 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: Martin Schwidefsky <schwidefsky@de.ibm.com> Cc: Heiko Carstens <heiko.carstens@de.ibm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/s390/char/raw3270.c')
-rw-r--r--drivers/s390/char/raw3270.c14
1 files changed, 8 insertions, 6 deletions
diff --git a/drivers/s390/char/raw3270.c b/drivers/s390/char/raw3270.c
index 81a96e019080..c3dee900a5c8 100644
--- a/drivers/s390/char/raw3270.c
+++ b/drivers/s390/char/raw3270.c
@@ -1168,17 +1168,19 @@ static int raw3270_create_attributes(struct raw3270 *rp)
1168 if (rc) 1168 if (rc)
1169 goto out; 1169 goto out;
1170 1170
1171 rp->clttydev = device_create(class3270, &rp->cdev->dev, 1171 rp->clttydev = device_create_drvdata(class3270, &rp->cdev->dev,
1172 MKDEV(IBM_TTY3270_MAJOR, rp->minor), 1172 MKDEV(IBM_TTY3270_MAJOR, rp->minor),
1173 "tty%s", rp->cdev->dev.bus_id); 1173 NULL,
1174 "tty%s", rp->cdev->dev.bus_id);
1174 if (IS_ERR(rp->clttydev)) { 1175 if (IS_ERR(rp->clttydev)) {
1175 rc = PTR_ERR(rp->clttydev); 1176 rc = PTR_ERR(rp->clttydev);
1176 goto out_ttydev; 1177 goto out_ttydev;
1177 } 1178 }
1178 1179
1179 rp->cltubdev = device_create(class3270, &rp->cdev->dev, 1180 rp->cltubdev = device_create_drvdata(class3270, &rp->cdev->dev,
1180 MKDEV(IBM_FS3270_MAJOR, rp->minor), 1181 MKDEV(IBM_FS3270_MAJOR, rp->minor),
1181 "tub%s", rp->cdev->dev.bus_id); 1182 NULL,
1183 "tub%s", rp->cdev->dev.bus_id);
1182 if (!IS_ERR(rp->cltubdev)) 1184 if (!IS_ERR(rp->cltubdev))
1183 goto out; 1185 goto out;
1184 1186