device create: infiniband: convert device_create_drvdata to device_create
authorGreg Kroah-Hartman <gregkh@suse.de>
Tue, 22 Jul 2008 03:03:34 +0000 (20:03 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Thu, 16 Oct 2008 16:24:42 +0000 (09:24 -0700)
Now that device_create() has been audited, rename things back to the
original call to be sane.

Cc: Roland Dreier <rolandd@cisco.com>
Cc: Sean Hefty <sean.hefty@intel.com>
Cc: Hal Rosenstock <hal.rosenstock@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/infiniband/core/cm.c
drivers/infiniband/core/user_mad.c
drivers/infiniband/core/uverbs_main.c
drivers/infiniband/hw/ipath/ipath_file_ops.c

index 3cab0cedfca21f54d83027a78f1f6c6a3c1a1b8e..a78d35aecee3de339520308358d6ca565d69cdd1 100644 (file)
@@ -3691,9 +3691,9 @@ static void cm_add_one(struct ib_device *ib_device)
        cm_dev->ib_device = ib_device;
        cm_get_ack_delay(cm_dev);
 
-       cm_dev->device = device_create_drvdata(&cm_class, &ib_device->dev,
-                                              MKDEV(0, 0), NULL,
-                                              "%s", ib_device->name);
+       cm_dev->device = device_create(&cm_class, &ib_device->dev,
+                                      MKDEV(0, 0), NULL,
+                                      "%s", ib_device->name);
        if (!cm_dev->device) {
                kfree(cm_dev);
                return;
index 268a2d23b7c9a8e9092877ca319989891e99e90d..8c46f2257098cf2d7e01ba472c31a48dc5ffb77a 100644 (file)
@@ -1016,9 +1016,9 @@ static int ib_umad_init_port(struct ib_device *device, int port_num,
        if (cdev_add(port->cdev, base_dev + port->dev_num, 1))
                goto err_cdev;
 
-       port->dev = device_create_drvdata(umad_class, device->dma_device,
-                                         port->cdev->dev, port,
-                                         "umad%d", port->dev_num);
+       port->dev = device_create(umad_class, device->dma_device,
+                                 port->cdev->dev, port,
+                                 "umad%d", port->dev_num);
        if (IS_ERR(port->dev))
                goto err_cdev;
 
@@ -1036,9 +1036,9 @@ static int ib_umad_init_port(struct ib_device *device, int port_num,
        if (cdev_add(port->sm_cdev, base_dev + port->dev_num + IB_UMAD_MAX_PORTS, 1))
                goto err_sm_cdev;
 
-       port->sm_dev = device_create_drvdata(umad_class, device->dma_device,
-                                            port->sm_cdev->dev, port,
-                                            "issm%d", port->dev_num);
+       port->sm_dev = device_create(umad_class, device->dma_device,
+                                    port->sm_cdev->dev, port,
+                                    "issm%d", port->dev_num);
        if (IS_ERR(port->sm_dev))
                goto err_sm_cdev;
 
index aeee856c4060648f4898c4014d30ed2c73065bdd..d85af1b670274466f5ec13a518d8011da1cb7da0 100644 (file)
@@ -764,12 +764,9 @@ static void ib_uverbs_add_one(struct ib_device *device)
        if (cdev_add(uverbs_dev->cdev, IB_UVERBS_BASE_DEV + uverbs_dev->devnum, 1))
                goto err_cdev;
 
-       uverbs_dev->dev = device_create_drvdata(uverbs_class,
-                                               device->dma_device,
-                                               uverbs_dev->cdev->dev,
-                                               uverbs_dev,
-                                               "uverbs%d",
-                                               uverbs_dev->devnum);
+       uverbs_dev->dev = device_create(uverbs_class, device->dma_device,
+                                       uverbs_dev->cdev->dev, uverbs_dev,
+                                       "uverbs%d", uverbs_dev->devnum);
        if (IS_ERR(uverbs_dev->dev))
                goto err_cdev;
 
index 56c0eda3c0772816f09e9b975090707929b826f3..1af1f3a907c6eb25a7930a6fd2e22ca36ad7135b 100644 (file)
@@ -2455,7 +2455,7 @@ static int init_cdev(int minor, char *name, const struct file_operations *fops,
                goto err_cdev;
        }
 
-       device = device_create_drvdata(ipath_class, NULL, dev, NULL, name);
+       device = device_create(ipath_class, NULL, dev, NULL, name);
 
        if (IS_ERR(device)) {
                ret = PTR_ERR(device);