diff options
author | Daniel Mack <daniel@caiaq.de> | 2010-04-12 07:17:25 -0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-05-20 16:21:38 -0400 |
commit | 997ea58eb92f9970b8af7aae48800d0ef43b9423 (patch) | |
tree | 65e021973e5a48ad7290d5be1f441940566468ad /drivers/input/misc/cm109.c | |
parent | 48679c6d772b1459a2945729e3a1256ac78fcabf (diff) |
USB: rename usb_buffer_alloc() and usb_buffer_free() users
For more clearance what the functions actually do,
usb_buffer_alloc() is renamed to usb_alloc_coherent()
usb_buffer_free() is renamed to usb_free_coherent()
They should only be used in code which really needs DMA coherency.
All call sites have been changed accordingly, except for staging
drivers.
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: Alan Stern <stern@rowland.harvard.edu>
Cc: Pedro Ribeiro <pedrib@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/input/misc/cm109.c')
-rw-r--r-- | drivers/input/misc/cm109.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/input/misc/cm109.c b/drivers/input/misc/cm109.c index 8d2d291ee508..2b0eba6619bd 100644 --- a/drivers/input/misc/cm109.c +++ b/drivers/input/misc/cm109.c | |||
@@ -630,11 +630,11 @@ static void cm109_usb_cleanup(struct cm109_dev *dev) | |||
630 | { | 630 | { |
631 | kfree(dev->ctl_req); | 631 | kfree(dev->ctl_req); |
632 | if (dev->ctl_data) | 632 | if (dev->ctl_data) |
633 | usb_buffer_free(dev->udev, USB_PKT_LEN, | 633 | usb_free_coherent(dev->udev, USB_PKT_LEN, |
634 | dev->ctl_data, dev->ctl_dma); | 634 | dev->ctl_data, dev->ctl_dma); |
635 | if (dev->irq_data) | 635 | if (dev->irq_data) |
636 | usb_buffer_free(dev->udev, USB_PKT_LEN, | 636 | usb_free_coherent(dev->udev, USB_PKT_LEN, |
637 | dev->irq_data, dev->irq_dma); | 637 | dev->irq_data, dev->irq_dma); |
638 | 638 | ||
639 | usb_free_urb(dev->urb_irq); /* parameter validation in core/urb */ | 639 | usb_free_urb(dev->urb_irq); /* parameter validation in core/urb */ |
640 | usb_free_urb(dev->urb_ctl); /* parameter validation in core/urb */ | 640 | usb_free_urb(dev->urb_ctl); /* parameter validation in core/urb */ |
@@ -683,13 +683,13 @@ static int cm109_usb_probe(struct usb_interface *intf, | |||
683 | goto err_out; | 683 | goto err_out; |
684 | 684 | ||
685 | /* allocate usb buffers */ | 685 | /* allocate usb buffers */ |
686 | dev->irq_data = usb_buffer_alloc(udev, USB_PKT_LEN, | 686 | dev->irq_data = usb_alloc_coherent(udev, USB_PKT_LEN, |
687 | GFP_KERNEL, &dev->irq_dma); | 687 | GFP_KERNEL, &dev->irq_dma); |
688 | if (!dev->irq_data) | 688 | if (!dev->irq_data) |
689 | goto err_out; | 689 | goto err_out; |
690 | 690 | ||
691 | dev->ctl_data = usb_buffer_alloc(udev, USB_PKT_LEN, | 691 | dev->ctl_data = usb_alloc_coherent(udev, USB_PKT_LEN, |
692 | GFP_KERNEL, &dev->ctl_dma); | 692 | GFP_KERNEL, &dev->ctl_dma); |
693 | if (!dev->ctl_data) | 693 | if (!dev->ctl_data) |
694 | goto err_out; | 694 | goto err_out; |
695 | 695 | ||