aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input/joystick
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2008-04-27 00:10:11 -0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2008-04-27 00:10:11 -0400
commit20430214cc0073dc7e817b032e32ae2ae54b4911 (patch)
tree60b25f7ece8d118b002b1c70b52e653ef7effd85 /drivers/input/joystick
parent308f0a5898033691d050374a949bbfe173987a16 (diff)
Input: xpad - fix build failure
If both CONFIG_JOYSTICK_XPAD_FF and CONFIG_JOYSTICK_XPAD_LEDS are unset xpad_bulk_out is not defined and build fails. Move it out of the #ifdef block so it is always defined. Reported-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/joystick')
-rw-r--r--drivers/input/joystick/xpad.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/drivers/input/joystick/xpad.c b/drivers/input/joystick/xpad.c
index 52ddb04644ab..d1c0e720d3f5 100644
--- a/drivers/input/joystick/xpad.c
+++ b/drivers/input/joystick/xpad.c
@@ -442,6 +442,23 @@ exit:
442 __FUNCTION__, retval); 442 __FUNCTION__, retval);
443} 443}
444 444
445static void xpad_bulk_out(struct urb *urb)
446{
447 switch (urb->status) {
448 case 0:
449 /* success */
450 break;
451 case -ECONNRESET:
452 case -ENOENT:
453 case -ESHUTDOWN:
454 /* this urb is terminated, clean up */
455 dbg("%s - urb shutting down with status: %d", __FUNCTION__, urb->status);
456 break;
457 default:
458 dbg("%s - nonzero urb status received: %d", __FUNCTION__, urb->status);
459 }
460}
461
445#if defined(CONFIG_JOYSTICK_XPAD_FF) || defined(CONFIG_JOYSTICK_XPAD_LEDS) 462#if defined(CONFIG_JOYSTICK_XPAD_FF) || defined(CONFIG_JOYSTICK_XPAD_LEDS)
446static void xpad_irq_out(struct urb *urb) 463static void xpad_irq_out(struct urb *urb)
447{ 464{
@@ -471,23 +488,6 @@ exit:
471 __FUNCTION__, retval); 488 __FUNCTION__, retval);
472} 489}
473 490
474static void xpad_bulk_out(struct urb *urb)
475{
476 switch (urb->status) {
477 case 0:
478 /* success */
479 break;
480 case -ECONNRESET:
481 case -ENOENT:
482 case -ESHUTDOWN:
483 /* this urb is terminated, clean up */
484 dbg("%s - urb shutting down with status: %d", __FUNCTION__, urb->status);
485 break;
486 default:
487 dbg("%s - nonzero urb status received: %d", __FUNCTION__, urb->status);
488 }
489}
490
491static int xpad_init_output(struct usb_interface *intf, struct usb_xpad *xpad) 491static int xpad_init_output(struct usb_interface *intf, struct usb_xpad *xpad)
492{ 492{
493 struct usb_endpoint_descriptor *ep_irq_out; 493 struct usb_endpoint_descriptor *ep_irq_out;