diff options
author | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-27 17:47:31 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-06-27 17:47:31 -0400 |
commit | 3e0777b8fa96f7073ed5d13d3bc1d573b766bef9 (patch) | |
tree | 3849e8457dd8f038ab7da025c708e275b43ea9c1 /drivers/usb/input/touchkitusb.c | |
parent | a94130e00038ebeb2f66901a4a4a9e05a03051c1 (diff) | |
parent | e5119885f00874453e837e3407014b73de2f4741 (diff) |
Merge rsync://rsync.kernel.org/pub/scm/linux/kernel/git/dtor/input.git manually
Some manual fixups required due to clashes with the PF_FREEZE cleanups.
Diffstat (limited to 'drivers/usb/input/touchkitusb.c')
-rw-r--r-- | drivers/usb/input/touchkitusb.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/drivers/usb/input/touchkitusb.c b/drivers/usb/input/touchkitusb.c index a71f1bbd0a17..386595ee21c0 100644 --- a/drivers/usb/input/touchkitusb.c +++ b/drivers/usb/input/touchkitusb.c | |||
@@ -69,7 +69,6 @@ struct touchkit_usb { | |||
69 | struct urb *irq; | 69 | struct urb *irq; |
70 | struct usb_device *udev; | 70 | struct usb_device *udev; |
71 | struct input_dev input; | 71 | struct input_dev input; |
72 | int open; | ||
73 | char name[128]; | 72 | char name[128]; |
74 | char phys[64]; | 73 | char phys[64]; |
75 | }; | 74 | }; |
@@ -134,15 +133,10 @@ static int touchkit_open(struct input_dev *input) | |||
134 | { | 133 | { |
135 | struct touchkit_usb *touchkit = input->private; | 134 | struct touchkit_usb *touchkit = input->private; |
136 | 135 | ||
137 | if (touchkit->open++) | ||
138 | return 0; | ||
139 | |||
140 | touchkit->irq->dev = touchkit->udev; | 136 | touchkit->irq->dev = touchkit->udev; |
141 | 137 | ||
142 | if (usb_submit_urb(touchkit->irq, GFP_ATOMIC)) { | 138 | if (usb_submit_urb(touchkit->irq, GFP_ATOMIC)) |
143 | touchkit->open--; | ||
144 | return -EIO; | 139 | return -EIO; |
145 | } | ||
146 | 140 | ||
147 | return 0; | 141 | return 0; |
148 | } | 142 | } |
@@ -151,8 +145,7 @@ static void touchkit_close(struct input_dev *input) | |||
151 | { | 145 | { |
152 | struct touchkit_usb *touchkit = input->private; | 146 | struct touchkit_usb *touchkit = input->private; |
153 | 147 | ||
154 | if (!--touchkit->open) | 148 | usb_kill_urb(touchkit->irq); |
155 | usb_kill_urb(touchkit->irq); | ||
156 | } | 149 | } |
157 | 150 | ||
158 | static int touchkit_alloc_buffers(struct usb_device *udev, | 151 | static int touchkit_alloc_buffers(struct usb_device *udev, |