ChangeSet 1.965, 2002/12/27 15:03:57-08:00, greg@kroah.com [PATCH] USB input drivers: remove direct calls to dev_set* and dev_get* change dev_set_drvdata() and dev_get_drvdata() to usb_set_intfdata() and usb_get_intfdata() diff -Nru a/drivers/usb/input/aiptek.c b/drivers/usb/input/aiptek.c --- a/drivers/usb/input/aiptek.c Fri Dec 27 23:55:51 2002 +++ b/drivers/usb/input/aiptek.c Fri Dec 27 23:55:51 2002 @@ -330,16 +330,16 @@ printk(KERN_INFO "input: %s on usb%d:%d\n", aiptek->features->name, dev->bus->busnum, dev->devnum); - dev_set_drvdata(&intf->dev, aiptek); + usb_set_intfdata(intf, aiptek); return 0; } static void aiptek_disconnect(struct usb_interface *intf) { - struct aiptek *aiptek = dev_get_drvdata(&intf->dev); + struct aiptek *aiptek = usb_get_intfdata (intf); - dev_set_drvdata(&intf->dev, NULL); + usb_set_intfdata(intf, NULL); if (aiptek) { usb_unlink_urb(aiptek->irq); input_unregister_device(&aiptek->dev); diff -Nru a/drivers/usb/input/hid-core.c b/drivers/usb/input/hid-core.c --- a/drivers/usb/input/hid-core.c Fri Dec 27 23:55:51 2002 +++ b/drivers/usb/input/hid-core.c Fri Dec 27 23:55:51 2002 @@ -1545,12 +1545,12 @@ static void hid_disconnect(struct usb_interface *intf) { - struct hid_device *hid = dev_get_drvdata(&intf->dev); + struct hid_device *hid = usb_get_intfdata (intf); if (!hid) return; - dev_set_drvdata (&intf->dev, NULL); + usb_set_intfdata(intf, NULL); usb_unlink_urb(hid->urbin); usb_unlink_urb(hid->urbout); usb_unlink_urb(hid->urbctrl); @@ -1592,7 +1592,7 @@ if (!hiddev_connect(hid)) hid->claimed |= HID_CLAIMED_HIDDEV; - dev_set_drvdata(&intf->dev, hid); + usb_set_intfdata(intf, hid); if (!hid->claimed) { printk ("HID device not claimed by input or hiddev\n"); diff -Nru a/drivers/usb/input/powermate.c b/drivers/usb/input/powermate.c --- a/drivers/usb/input/powermate.c Fri Dec 27 23:55:51 2002 +++ b/drivers/usb/input/powermate.c Fri Dec 27 23:55:51 2002 @@ -388,16 +388,16 @@ pm->requires_update = UPDATE_PULSE_ASLEEP | UPDATE_PULSE_AWAKE | UPDATE_PULSE_MODE | UPDATE_STATIC_BRIGHTNESS; powermate_pulse_led(pm, 0x80, 255, 0, 1, 0); // set default pulse parameters - dev_set_drvdata(&intf->dev, pm); + usb_set_intfdata(intf, pm); return 0; } /* Called when a USB device we've accepted ownership of is removed */ static void powermate_disconnect(struct usb_interface *intf) { - struct powermate_device *pm = dev_get_drvdata(&intf->dev); + struct powermate_device *pm = usb_get_intfdata (intf); - dev_set_drvdata(&intf->dev, NULL); + usb_set_intfdata(intf, NULL); if (pm) { down(&pm->lock); pm->requires_update = 0; diff -Nru a/drivers/usb/input/usbkbd.c b/drivers/usb/input/usbkbd.c --- a/drivers/usb/input/usbkbd.c Fri Dec 27 23:55:51 2002 +++ b/drivers/usb/input/usbkbd.c Fri Dec 27 23:55:51 2002 @@ -328,15 +328,15 @@ printk(KERN_INFO "input: %s on %s\n", kbd->name, path); - dev_set_drvdata(&iface->dev, kbd); + usb_set_intfdata(iface, kbd); return 0; } static void usb_kbd_disconnect(struct usb_interface *intf) { - struct usb_kbd *kbd = dev_get_drvdata(&intf->dev); + struct usb_kbd *kbd = usb_get_intfdata (intf); - dev_set_drvdata(&intf->dev, NULL); + usb_set_intfdata(intf, NULL); if (kbd) { usb_unlink_urb(kbd->irq); input_unregister_device(&kbd->dev); diff -Nru a/drivers/usb/input/usbmouse.c b/drivers/usb/input/usbmouse.c --- a/drivers/usb/input/usbmouse.c Fri Dec 27 23:55:51 2002 +++ b/drivers/usb/input/usbmouse.c Fri Dec 27 23:55:51 2002 @@ -211,15 +211,15 @@ input_register_device(&mouse->dev); printk(KERN_INFO "input: %s on %s\n", mouse->name, path); - dev_set_drvdata(&intf->dev, mouse); + usb_set_intfdata(intf, mouse); return 0; } static void usb_mouse_disconnect(struct usb_interface *intf) { - struct usb_mouse *mouse = dev_get_drvdata(&intf->dev); + struct usb_mouse *mouse = usb_get_intfdata (intf); - dev_set_drvdata(&intf->dev, NULL); + usb_set_intfdata(intf, NULL); if (mouse) { usb_unlink_urb(mouse->irq); input_unregister_device(&mouse->dev); diff -Nru a/drivers/usb/input/wacom.c b/drivers/usb/input/wacom.c --- a/drivers/usb/input/wacom.c Fri Dec 27 23:55:51 2002 +++ b/drivers/usb/input/wacom.c Fri Dec 27 23:55:51 2002 @@ -583,16 +583,16 @@ printk(KERN_INFO "input: %s on %s\n", wacom->features->name, path); - dev_set_drvdata(&intf->dev, wacom); + usb_set_intfdata(intf, wacom); return 0; } static void wacom_disconnect(struct usb_interface *intf) { - struct wacom *wacom = dev_get_drvdata(&intf->dev); + struct wacom *wacom = usb_get_intfdata (intf); - dev_set_drvdata(&intf->dev, NULL); + usb_set_intfdata(intf, NULL); if (wacom) { usb_unlink_urb(wacom->irq); input_unregister_device(&wacom->dev); diff -Nru a/drivers/usb/input/xpad.c b/drivers/usb/input/xpad.c --- a/drivers/usb/input/xpad.c Fri Dec 27 23:55:51 2002 +++ b/drivers/usb/input/xpad.c Fri Dec 27 23:55:51 2002 @@ -311,15 +311,15 @@ printk(KERN_INFO "input: %s on %s", xpad->dev.name, path); - dev_set_drvdata(&intf->dev, xpad); + usb_set_intfdata(intf, xpad); return 0; } static void xpad_disconnect(struct usb_interface *intf) { - struct usb_xpad *xpad = dev_get_drvdata(&intf->dev); + struct usb_xpad *xpad = usb_get_intfdata (intf); - dev_set_drvdata(&intf->dev, NULL); + usb_set_intfdata(intf, NULL); if (xpad) { usb_unlink_urb(xpad->irq_in); input_unregister_device(&xpad->dev);