aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMariusz Kozlowski <m.kozlowski@tuxland.pl>2006-11-06 11:37:20 -0500
committerGreg Kroah-Hartman <gregkh@suse.de>2006-12-01 17:23:37 -0500
commit54ecf1fba683f779a1b36abed9c843decafc7d5b (patch)
tree0a57c3371593d131fa91e5f6813e8ecd11e01437
parent8bb22d2bdaac415965e7be1af8da2b8f3ee35f31 (diff)
USB: idmouse cleanup
Just digging through code and found these needless variable initializations. So here is the patch. Signed-off-by: Mariusz Kozlowski <m.kozlowski@tuxland.pl> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/usb/misc/idmouse.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/usb/misc/idmouse.c b/drivers/usb/misc/idmouse.c
index c5fee0033a84..c9418535bef8 100644
--- a/drivers/usb/misc/idmouse.c
+++ b/drivers/usb/misc/idmouse.c
@@ -125,12 +125,12 @@ static DEFINE_MUTEX(disconnect_mutex);
125 125
126static int idmouse_create_image(struct usb_idmouse *dev) 126static int idmouse_create_image(struct usb_idmouse *dev)
127{ 127{
128 int bytes_read = 0; 128 int bytes_read;
129 int bulk_read = 0; 129 int bulk_read;
130 int result = 0; 130 int result;
131 131
132 memcpy(dev->bulk_in_buffer, HEADER, sizeof(HEADER)-1); 132 memcpy(dev->bulk_in_buffer, HEADER, sizeof(HEADER)-1);
133 bytes_read += sizeof(HEADER)-1; 133 bytes_read = sizeof(HEADER)-1;
134 134
135 /* reset the device and set a fast blink rate */ 135 /* reset the device and set a fast blink rate */
136 result = ftip_command(dev, FTIP_RELEASE, 0, 0); 136 result = ftip_command(dev, FTIP_RELEASE, 0, 0);
@@ -208,9 +208,9 @@ static inline void idmouse_delete(struct usb_idmouse *dev)
208 208
209static int idmouse_open(struct inode *inode, struct file *file) 209static int idmouse_open(struct inode *inode, struct file *file)
210{ 210{
211 struct usb_idmouse *dev = NULL; 211 struct usb_idmouse *dev;
212 struct usb_interface *interface; 212 struct usb_interface *interface;
213 int result = 0; 213 int result;
214 214
215 /* prevent disconnects */ 215 /* prevent disconnects */
216 mutex_lock(&disconnect_mutex); 216 mutex_lock(&disconnect_mutex);
@@ -305,7 +305,7 @@ static ssize_t idmouse_read(struct file *file, char __user *buffer, size_t count
305 loff_t * ppos) 305 loff_t * ppos)
306{ 306{
307 struct usb_idmouse *dev; 307 struct usb_idmouse *dev;
308 int result = 0; 308 int result;
309 309
310 dev = (struct usb_idmouse *) file->private_data; 310 dev = (struct usb_idmouse *) file->private_data;
311 311
@@ -329,7 +329,7 @@ static int idmouse_probe(struct usb_interface *interface,
329 const struct usb_device_id *id) 329 const struct usb_device_id *id)
330{ 330{
331 struct usb_device *udev = interface_to_usbdev(interface); 331 struct usb_device *udev = interface_to_usbdev(interface);
332 struct usb_idmouse *dev = NULL; 332 struct usb_idmouse *dev;
333 struct usb_host_interface *iface_desc; 333 struct usb_host_interface *iface_desc;
334 struct usb_endpoint_descriptor *endpoint; 334 struct usb_endpoint_descriptor *endpoint;
335 int result; 335 int result;