Commit 166b8639 authored by Chase Metzger's avatar Chase Metzger Committed by Greg Kroah-Hartman

usb: core: hub.c: Removed some warnings generated by checkpatch.pl

Removed some checkpatch.pl warnings saying there was an unwanted space between
function names and their arguments.
Signed-off-by: default avatarChase Metzger <chasemetzger15@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent f355e830
...@@ -50,8 +50,8 @@ DEFINE_MUTEX(usb_port_peer_mutex); ...@@ -50,8 +50,8 @@ DEFINE_MUTEX(usb_port_peer_mutex);
/* cycle leds on hubs that aren't blinking for attention */ /* cycle leds on hubs that aren't blinking for attention */
static bool blinkenlights = 0; static bool blinkenlights = 0;
module_param (blinkenlights, bool, S_IRUGO); module_param(blinkenlights, bool, S_IRUGO);
MODULE_PARM_DESC (blinkenlights, "true to cycle leds on hubs"); MODULE_PARM_DESC(blinkenlights, "true to cycle leds on hubs");
/* /*
* Device SATA8000 FW1.0 from DATAST0R Technology Corp requires about * Device SATA8000 FW1.0 from DATAST0R Technology Corp requires about
...@@ -439,7 +439,7 @@ static void set_port_led(struct usb_hub *hub, int port1, int selector) ...@@ -439,7 +439,7 @@ static void set_port_led(struct usb_hub *hub, int port1, int selector)
#define LED_CYCLE_PERIOD ((2*HZ)/3) #define LED_CYCLE_PERIOD ((2*HZ)/3)
static void led_work (struct work_struct *work) static void led_work(struct work_struct *work)
{ {
struct usb_hub *hub = struct usb_hub *hub =
container_of(work, struct usb_hub, leds.work); container_of(work, struct usb_hub, leds.work);
...@@ -646,7 +646,7 @@ static void hub_irq(struct urb *urb) ...@@ -646,7 +646,7 @@ static void hub_irq(struct urb *urb)
default: /* presumably an error */ default: /* presumably an error */
/* Cause a hub reset after 10 consecutive errors */ /* Cause a hub reset after 10 consecutive errors */
dev_dbg (hub->intfdev, "transfer --> %d\n", status); dev_dbg(hub->intfdev, "transfer --> %d\n", status);
if ((++hub->nerrors < 10) || hub->error) if ((++hub->nerrors < 10) || hub->error)
goto resubmit; goto resubmit;
hub->error = status; hub->error = status;
...@@ -671,14 +671,14 @@ static void hub_irq(struct urb *urb) ...@@ -671,14 +671,14 @@ static void hub_irq(struct urb *urb)
if (hub->quiescing) if (hub->quiescing)
return; return;
if ((status = usb_submit_urb (hub->urb, GFP_ATOMIC)) != 0 if ((status = usb_submit_urb(hub->urb, GFP_ATOMIC)) != 0
&& status != -ENODEV && status != -EPERM) && status != -ENODEV && status != -EPERM)
dev_err (hub->intfdev, "resubmit --> %d\n", status); dev_err(hub->intfdev, "resubmit --> %d\n", status);
} }
/* USB 2.0 spec Section 11.24.2.3 */ /* USB 2.0 spec Section 11.24.2.3 */
static inline int static inline int
hub_clear_tt_buffer (struct usb_device *hdev, u16 devinfo, u16 tt) hub_clear_tt_buffer(struct usb_device *hdev, u16 devinfo, u16 tt)
{ {
/* Need to clear both directions for control ep */ /* Need to clear both directions for control ep */
if (((devinfo >> 11) & USB_ENDPOINT_XFERTYPE_MASK) == if (((devinfo >> 11) & USB_ENDPOINT_XFERTYPE_MASK) ==
...@@ -706,7 +706,7 @@ static void hub_tt_work(struct work_struct *work) ...@@ -706,7 +706,7 @@ static void hub_tt_work(struct work_struct *work)
container_of(work, struct usb_hub, tt.clear_work); container_of(work, struct usb_hub, tt.clear_work);
unsigned long flags; unsigned long flags;
spin_lock_irqsave (&hub->tt.lock, flags); spin_lock_irqsave(&hub->tt.lock, flags);
while (!list_empty(&hub->tt.clear_list)) { while (!list_empty(&hub->tt.clear_list)) {
struct list_head *next; struct list_head *next;
struct usb_tt_clear *clear; struct usb_tt_clear *clear;
...@@ -715,14 +715,14 @@ static void hub_tt_work(struct work_struct *work) ...@@ -715,14 +715,14 @@ static void hub_tt_work(struct work_struct *work)
int status; int status;
next = hub->tt.clear_list.next; next = hub->tt.clear_list.next;
clear = list_entry (next, struct usb_tt_clear, clear_list); clear = list_entry(next, struct usb_tt_clear, clear_list);
list_del (&clear->clear_list); list_del(&clear->clear_list);
/* drop lock so HCD can concurrently report other TT errors */ /* drop lock so HCD can concurrently report other TT errors */
spin_unlock_irqrestore (&hub->tt.lock, flags); spin_unlock_irqrestore(&hub->tt.lock, flags);
status = hub_clear_tt_buffer (hdev, clear->devinfo, clear->tt); status = hub_clear_tt_buffer(hdev, clear->devinfo, clear->tt);
if (status && status != -ENODEV) if (status && status != -ENODEV)
dev_err (&hdev->dev, dev_err(&hdev->dev,
"clear tt %d (%04x) error %d\n", "clear tt %d (%04x) error %d\n",
clear->tt, clear->devinfo, status); clear->tt, clear->devinfo, status);
...@@ -734,7 +734,7 @@ static void hub_tt_work(struct work_struct *work) ...@@ -734,7 +734,7 @@ static void hub_tt_work(struct work_struct *work)
kfree(clear); kfree(clear);
spin_lock_irqsave(&hub->tt.lock, flags); spin_lock_irqsave(&hub->tt.lock, flags);
} }
spin_unlock_irqrestore (&hub->tt.lock, flags); spin_unlock_irqrestore(&hub->tt.lock, flags);
} }
/** /**
...@@ -797,7 +797,7 @@ int usb_hub_clear_tt_buffer(struct urb *urb) ...@@ -797,7 +797,7 @@ int usb_hub_clear_tt_buffer(struct urb *urb)
*/ */
clear = kmalloc(sizeof *clear, GFP_ATOMIC); clear = kmalloc(sizeof *clear, GFP_ATOMIC);
if (clear == NULL) { if (clear == NULL) {
dev_err (&udev->dev, "can't save CLEAR_TT_BUFFER state\n"); dev_err(&udev->dev, "can't save CLEAR_TT_BUFFER state\n");
/* FIXME recover somehow ... RESET_TT? */ /* FIXME recover somehow ... RESET_TT? */
return -ENOMEM; return -ENOMEM;
} }
...@@ -806,10 +806,10 @@ int usb_hub_clear_tt_buffer(struct urb *urb) ...@@ -806,10 +806,10 @@ int usb_hub_clear_tt_buffer(struct urb *urb)
clear->tt = tt->multi ? udev->ttport : 1; clear->tt = tt->multi ? udev->ttport : 1;
clear->devinfo = usb_pipeendpoint (pipe); clear->devinfo = usb_pipeendpoint (pipe);
clear->devinfo |= udev->devnum << 4; clear->devinfo |= udev->devnum << 4;
clear->devinfo |= usb_pipecontrol (pipe) clear->devinfo |= usb_pipecontrol(pipe)
? (USB_ENDPOINT_XFER_CONTROL << 11) ? (USB_ENDPOINT_XFER_CONTROL << 11)
: (USB_ENDPOINT_XFER_BULK << 11); : (USB_ENDPOINT_XFER_BULK << 11);
if (usb_pipein (pipe)) if (usb_pipein(pipe))
clear->devinfo |= 1 << 15; clear->devinfo |= 1 << 15;
/* info for completion callback */ /* info for completion callback */
...@@ -817,10 +817,10 @@ int usb_hub_clear_tt_buffer(struct urb *urb) ...@@ -817,10 +817,10 @@ int usb_hub_clear_tt_buffer(struct urb *urb)
clear->ep = urb->ep; clear->ep = urb->ep;
/* tell keventd to clear state for this TT */ /* tell keventd to clear state for this TT */
spin_lock_irqsave (&tt->lock, flags); spin_lock_irqsave(&tt->lock, flags);
list_add_tail (&clear->clear_list, &tt->clear_list); list_add_tail(&clear->clear_list, &tt->clear_list);
schedule_work(&tt->clear_work); schedule_work(&tt->clear_work);
spin_unlock_irqrestore (&tt->lock, flags); spin_unlock_irqrestore(&tt->lock, flags);
return 0; return 0;
} }
EXPORT_SYMBOL_GPL(usb_hub_clear_tt_buffer); EXPORT_SYMBOL_GPL(usb_hub_clear_tt_buffer);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment