From a60ae0b779d2ac133a2de9283d41019ed552c16e Mon Sep 17 00:00:00 2001 From: Felipe Balbi Date: Fri, 11 Apr 2008 11:28:23 +0300 Subject: [PATCH] USB: MUSB: checkpatch.pl fixes to musb_gadget.c Misc cleanup patch. Signed-off-by: Felipe Balbi Signed-off-by: Tony Lindgren --- drivers/usb/musb/musb_gadget.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/usb/musb/musb_gadget.c b/drivers/usb/musb/musb_gadget.c index 0fb96357801..303b6f6cfbd 100644 --- a/drivers/usb/musb/musb_gadget.c +++ b/drivers/usb/musb/musb_gadget.c @@ -321,8 +321,7 @@ static void txstate(struct musb *musb, struct musb_request *req) csr |= (MUSB_TXCSR_DMAENAB | MUSB_TXCSR_MODE); /* against programming guide */ - } - else + } else csr |= (MUSB_TXCSR_AUTOSET | MUSB_TXCSR_DMAENAB | MUSB_TXCSR_DMAMODE @@ -812,7 +811,7 @@ void musb_g_rx(struct musb *musb, u8 epnum) } /* incomplete, and not short? wait for next IN packet */ - if ((request->actual < request->length) + if ((request->actual < request->length) && (musb_ep->dma->actual_len == musb_ep->packet_sz)) goto done; @@ -1482,7 +1481,7 @@ static void musb_pullup(struct musb *musb, int is_on) #if 0 static int musb_gadget_vbus_session(struct usb_gadget *gadget, int is_active) { - DBG(2, "<= %s =>\n", __FUNCTION__); + DBG(2, "<= %s =>\n", __func__); /* * FIXME iff driver's softconnect flag is set (as it is during probe, @@ -1543,7 +1542,7 @@ static struct musb *the_gadget; static void musb_gadget_release(struct device *dev) { /* kref_put(WHAT) */ - dev_dbg(dev, "%s\n", __FUNCTION__); + dev_dbg(dev, "%s\n", __func__); } @@ -1689,7 +1688,7 @@ int usb_gadget_register_driver(struct usb_gadget_driver *driver) /* driver must be initialized to support peripheral mode */ if (!musb || !(musb->board_mode == MUSB_OTG || musb->board_mode != MUSB_OTG)) { - DBG(1,"%s, no dev??\n", __FUNCTION__); + DBG(1, "%s, no dev??\n", __func__); return -ENODEV; } @@ -1803,7 +1802,7 @@ static void stop_activity(struct musb *musb, struct usb_gadget_driver *driver) } spin_unlock(&musb->lock); - driver->disconnect (&musb->g); + driver->disconnect(&musb->g); spin_lock(&musb->lock); } } -- 2.41.1