aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/joystick/xpad.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2010-05-21 00:26:12 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2010-05-21 00:26:12 -0400
commit7a9b149212f3716c598afe973b6261fd58453b7a (patch)
tree477716d84c71da124448b72278e98da28aadbd3d /drivers/input/joystick/xpad.c
parent3d62e3fdce8ef265a3706c52ae1ca6ab84e30f0e (diff)
parente26bcf37234c67624f62d9fc95f922b8dbda1363 (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/usb-2.6: (229 commits) USB: remove unused usb_buffer_alloc and usb_buffer_free macros usb: musb: update gfp/slab.h includes USB: ftdi_sio: fix legacy SIO-device header USB: kl5usb105: reimplement using generic framework USB: kl5usb105: minor clean ups USB: kl5usb105: fix memory leak USB: io_ti: use kfifo to implement write buffering USB: io_ti: remove unsused private counter USB: ti_usb: use kfifo to implement write buffering USB: ir-usb: fix incorrect write-buffer length USB: aircable: fix incorrect write-buffer length USB: safe_serial: straighten out read processing USB: safe_serial: reimplement read using generic framework USB: safe_serial: reimplement write using generic framework usb-storage: always print quirks USB: usb-storage: trivial debug improvements USB: oti6858: use port write fifo USB: oti6858: use kfifo to implement write buffering USB: cypress_m8: use kfifo to implement write buffering USB: cypress_m8: remove unused drain define ... Fix up conflicts (due to usb_buffer_alloc/free renaming) in drivers/input/tablet/acecad.c drivers/input/tablet/kbtab.c drivers/input/tablet/wacom_sys.c drivers/media/video/gspca/gspca.c sound/usb/usbaudio.c
Diffstat (limited to 'drivers/input/joystick/xpad.c')
-rw-r--r--drivers/input/joystick/xpad.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c
index 9b3353b404da..c1087ce4cef9 100644
--- a/drivers/input/joystick/xpad.c
+++ b/drivers/input/joystick/xpad.c
@@ -533,8 +533,8 @@ static int xpad_init_output(struct usb_interface *intf, struct usb_xpad *xpad)
533 if (xpad->xtype != XTYPE_XBOX360 && xpad->xtype != XTYPE_XBOX) 533 if (xpad->xtype != XTYPE_XBOX360 && xpad->xtype != XTYPE_XBOX)
534 return 0; 534 return 0;
535 535
536 xpad->odata = usb_buffer_alloc(xpad->udev, XPAD_PKT_LEN, 536 xpad->odata = usb_alloc_coherent(xpad->udev, XPAD_PKT_LEN,
537 GFP_KERNEL, &xpad->odata_dma); 537 GFP_KERNEL, &xpad->odata_dma);
538 if (!xpad->odata) 538 if (!xpad->odata)
539 goto fail1; 539 goto fail1;
540 540
@@ -554,7 +554,7 @@ static int xpad_init_output(struct usb_interface *intf, struct usb_xpad *xpad)
554 554
555 return 0; 555 return 0;
556 556
557 fail2: usb_buffer_free(xpad->udev, XPAD_PKT_LEN, xpad->odata, xpad->odata_dma); 557 fail2: usb_free_coherent(xpad->udev, XPAD_PKT_LEN, xpad->odata, xpad->odata_dma);
558 fail1: return error; 558 fail1: return error;
559} 559}
560 560
@@ -568,7 +568,7 @@ static void xpad_deinit_output(struct usb_xpad *xpad)
568{ 568{
569 if (xpad->xtype == XTYPE_XBOX360 || xpad->xtype == XTYPE_XBOX) { 569 if (xpad->xtype == XTYPE_XBOX360 || xpad->xtype == XTYPE_XBOX) {
570 usb_free_urb(xpad->irq_out); 570 usb_free_urb(xpad->irq_out);
571 usb_buffer_free(xpad->udev, XPAD_PKT_LEN, 571 usb_free_coherent(xpad->udev, XPAD_PKT_LEN,
572 xpad->odata, xpad->odata_dma); 572 xpad->odata, xpad->odata_dma);
573 } 573 }
574} 574}
@@ -788,8 +788,8 @@ static int xpad_probe(struct usb_interface *intf, const struct usb_device_id *id
788 if (!xpad || !input_dev) 788 if (!xpad || !input_dev)
789 goto fail1; 789 goto fail1;
790 790
791 xpad->idata = usb_buffer_alloc(udev, XPAD_PKT_LEN, 791 xpad->idata = usb_alloc_coherent(udev, XPAD_PKT_LEN,
792 GFP_KERNEL, &xpad->idata_dma); 792 GFP_KERNEL, &xpad->idata_dma);
793 if (!xpad->idata) 793 if (!xpad->idata)
794 goto fail1; 794 goto fail1;
795 795
@@ -942,7 +942,7 @@ static int xpad_probe(struct usb_interface *intf, const struct usb_device_id *id
942 fail5: usb_kill_urb(xpad->irq_in); 942 fail5: usb_kill_urb(xpad->irq_in);
943 fail4: usb_free_urb(xpad->irq_in); 943 fail4: usb_free_urb(xpad->irq_in);
944 fail3: xpad_deinit_output(xpad); 944 fail3: xpad_deinit_output(xpad);
945 fail2: usb_buffer_free(udev, XPAD_PKT_LEN, xpad->idata, xpad->idata_dma); 945 fail2: usb_free_coherent(udev, XPAD_PKT_LEN, xpad->idata, xpad->idata_dma);
946 fail1: input_free_device(input_dev); 946 fail1: input_free_device(input_dev);
947 kfree(xpad); 947 kfree(xpad);
948 return error; 948 return error;
@@ -964,7 +964,7 @@ static void xpad_disconnect(struct usb_interface *intf)
964 usb_kill_urb(xpad->irq_in); 964 usb_kill_urb(xpad->irq_in);
965 } 965 }
966 usb_free_urb(xpad->irq_in); 966 usb_free_urb(xpad->irq_in);
967 usb_buffer_free(xpad->udev, XPAD_PKT_LEN, 967 usb_free_coherent(xpad->udev, XPAD_PKT_LEN,
968 xpad->idata, xpad->idata_dma); 968 xpad->idata, xpad->idata_dma);
969 kfree(xpad); 969 kfree(xpad);
970 } 970 }