diff options
author | Dmitry Torokhov <dtor@insightbb.com> | 2007-04-12 09:34:39 +0400 |
---|---|---|
committer | Dmitry Torokhov <dtor@insightbb.com> | 2007-04-12 09:34:39 +0400 |
commit | 7791bdae71243050132ede7ea1558c828b69458f (patch) | |
tree | f6c3291deff0b7b8720405432245b6acf7cce218 /drivers/usb/input/appletouch.c | |
parent | 373f9713dccc8fc8e076157001a60133455c0550 (diff) | |
download | linux-7791bdae71243050132ede7ea1558c828b69458f.tar.xz |
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/appletouch.c')
-rw-r--r-- | drivers/usb/input/appletouch.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/usb/input/appletouch.c b/drivers/usb/input/appletouch.c index 36221329a4ef..ef6166ab8fe7 100644 --- a/drivers/usb/input/appletouch.c +++ b/drivers/usb/input/appletouch.c @@ -466,7 +466,7 @@ exit: static int atp_open(struct input_dev *input) { - struct atp *dev = input->private; + struct atp *dev = input_get_drvdata(input); if (usb_submit_urb(dev->urb, GFP_ATOMIC)) return -EIO; @@ -477,7 +477,7 @@ static int atp_open(struct input_dev *input) static void atp_close(struct input_dev *input) { - struct atp *dev = input->private; + struct atp *dev = input_get_drvdata(input); usb_kill_urb(dev->urb); dev->open = 0; @@ -586,7 +586,8 @@ static int atp_probe(struct usb_interface *iface, const struct usb_device_id *id usb_to_input_id(dev->udev, &input_dev->id); input_dev->cdev.dev = &iface->dev; - input_dev->private = dev; + input_set_drvdata(input_dev, dev); + input_dev->open = atp_open; input_dev->close = atp_close; |