Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 55983
b: refs/heads/master
c: 6675c5b
h: refs/heads/master
i:
  55981: 6c79dbc
  55979: db17017
  55975: 9a4a4b2
  55967: 0b8d712
v: v3
  • Loading branch information
Dmitry Torokhov authored and Jiri Kosina committed May 9, 2007
1 parent ccff5f4 commit c980aab
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 15 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 66da876962f782a3974b4a957d12f20656584a4d
refs/heads/master: 6675c5bd2a0ec223888b42cf97bc7dc900bf31fb
12 changes: 4 additions & 8 deletions trunk/drivers/hid/usbhid/hid-core.c
Original file line number Diff line number Diff line change
Expand Up @@ -626,14 +626,10 @@ static void hid_free_buffers(struct usb_device *dev, struct hid_device *hid)
{
struct usbhid_device *usbhid = hid->driver_data;

if (usbhid->inbuf)
usb_buffer_free(dev, usbhid->bufsize, usbhid->inbuf, usbhid->inbuf_dma);
if (usbhid->outbuf)
usb_buffer_free(dev, usbhid->bufsize, usbhid->outbuf, usbhid->outbuf_dma);
if (usbhid->cr)
usb_buffer_free(dev, sizeof(*(usbhid->cr)), usbhid->cr, usbhid->cr_dma);
if (usbhid->ctrlbuf)
usb_buffer_free(dev, usbhid->bufsize, usbhid->ctrlbuf, usbhid->ctrlbuf_dma);
usb_buffer_free(dev, usbhid->bufsize, usbhid->inbuf, usbhid->inbuf_dma);
usb_buffer_free(dev, usbhid->bufsize, usbhid->outbuf, usbhid->outbuf_dma);
usb_buffer_free(dev, sizeof(*(usbhid->cr)), usbhid->cr, usbhid->cr_dma);
usb_buffer_free(dev, usbhid->bufsize, usbhid->ctrlbuf, usbhid->ctrlbuf_dma);
}

/*
Expand Down
9 changes: 3 additions & 6 deletions trunk/drivers/hid/usbhid/usbkbd.c
Original file line number Diff line number Diff line change
Expand Up @@ -211,12 +211,9 @@ static void usb_kbd_free_mem(struct usb_device *dev, struct usb_kbd *kbd)
{
usb_free_urb(kbd->irq);
usb_free_urb(kbd->led);
if (kbd->new)
usb_buffer_free(dev, 8, kbd->new, kbd->new_dma);
if (kbd->cr)
usb_buffer_free(dev, sizeof(struct usb_ctrlrequest), kbd->cr, kbd->cr_dma);
if (kbd->leds)
usb_buffer_free(dev, 1, kbd->leds, kbd->leds_dma);
usb_buffer_free(dev, 8, kbd->new, kbd->new_dma);
usb_buffer_free(dev, sizeof(struct usb_ctrlrequest), kbd->cr, kbd->cr_dma);
usb_buffer_free(dev, 1, kbd->leds, kbd->leds_dma);
}

static int usb_kbd_probe(struct usb_interface *iface,
Expand Down

0 comments on commit c980aab

Please sign in to comment.