device create: usb: convert device_create_drvdata to device_create
Now that device_create() has been audited, rename things back to the original call to be sane. Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
@@ -595,9 +595,8 @@ static int interfacekit_probe(struct usb_interface *intf, const struct usb_devic
|
||||
} while(value);
|
||||
kit->dev_no = bit;
|
||||
|
||||
kit->dev = device_create_drvdata(phidget_class, &kit->udev->dev,
|
||||
MKDEV(0, 0), kit,
|
||||
"interfacekit%d", kit->dev_no);
|
||||
kit->dev = device_create(phidget_class, &kit->udev->dev, MKDEV(0, 0),
|
||||
kit, "interfacekit%d", kit->dev_no);
|
||||
if (IS_ERR(kit->dev)) {
|
||||
rc = PTR_ERR(kit->dev);
|
||||
kit->dev = NULL;
|
||||
|
@@ -365,9 +365,8 @@ static int motorcontrol_probe(struct usb_interface *intf, const struct usb_devic
|
||||
} while(value);
|
||||
mc->dev_no = bit;
|
||||
|
||||
mc->dev = device_create_drvdata(phidget_class, &mc->udev->dev,
|
||||
MKDEV(0, 0), mc,
|
||||
"motorcontrol%d", mc->dev_no);
|
||||
mc->dev = device_create(phidget_class, &mc->udev->dev, MKDEV(0, 0), mc,
|
||||
"motorcontrol%d", mc->dev_no);
|
||||
if (IS_ERR(mc->dev)) {
|
||||
rc = PTR_ERR(mc->dev);
|
||||
mc->dev = NULL;
|
||||
|
@@ -275,9 +275,8 @@ servo_probe(struct usb_interface *interface, const struct usb_device_id *id)
|
||||
} while (value);
|
||||
dev->dev_no = bit;
|
||||
|
||||
dev->dev = device_create_drvdata(phidget_class, &dev->udev->dev,
|
||||
MKDEV(0, 0), dev,
|
||||
"servo%d", dev->dev_no);
|
||||
dev->dev = device_create(phidget_class, &dev->udev->dev, MKDEV(0, 0),
|
||||
dev, "servo%d", dev->dev_no);
|
||||
if (IS_ERR(dev->dev)) {
|
||||
rc = PTR_ERR(dev->dev);
|
||||
dev->dev = NULL;
|
||||
|
Reference in New Issue
Block a user