diff options
author | Dmitry Torokhov <dtor@insightbb.com> | 2007-04-12 01:34:39 -0400 |
---|---|---|
committer | Dmitry Torokhov <dtor@insightbb.com> | 2007-04-12 01:34:39 -0400 |
commit | 7791bdae71243050132ede7ea1558c828b69458f (patch) | |
tree | f6c3291deff0b7b8720405432245b6acf7cce218 /drivers/usb/input/keyspan_remote.c | |
parent | 373f9713dccc8fc8e076157001a60133455c0550 (diff) | |
download | blackbird-op-linux-7791bdae71243050132ede7ea1558c828b69458f.tar.gz blackbird-op-linux-7791bdae71243050132ede7ea1558c828b69458f.zip |
Input: drivers/usb/input - don't access dev->private directly
Use input_get_drvdata() and input_set_drvdata() instead.
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/usb/input/keyspan_remote.c')
-rw-r--r-- | drivers/usb/input/keyspan_remote.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/usb/input/keyspan_remote.c b/drivers/usb/input/keyspan_remote.c index d32a7684de94..daf8f218a1f4 100644 --- a/drivers/usb/input/keyspan_remote.c +++ b/drivers/usb/input/keyspan_remote.c @@ -394,7 +394,7 @@ resubmit: static int keyspan_open(struct input_dev *dev) { - struct usb_keyspan *remote = dev->private; + struct usb_keyspan *remote = input_get_drvdata(dev); remote->irq_urb->dev = remote->udev; if (usb_submit_urb(remote->irq_urb, GFP_KERNEL)) @@ -405,7 +405,7 @@ static int keyspan_open(struct input_dev *dev) static void keyspan_close(struct input_dev *dev) { - struct usb_keyspan *remote = dev->private; + struct usb_keyspan *remote = input_get_drvdata(dev); usb_kill_urb(remote->irq_urb); } @@ -502,7 +502,8 @@ static int keyspan_probe(struct usb_interface *interface, const struct usb_devic if (keyspan_key_table[i] != KEY_RESERVED) set_bit(keyspan_key_table[i], input_dev->keybit); - input_dev->private = remote; + input_set_drvdata(input_dev, remote); + input_dev->open = keyspan_open; input_dev->close = keyspan_close; |