]> git.karo-electronics.de Git - linux-beck.git/commitdiff
usb: dwc2: gadget: rename sent_zlp to send_zlp
authorMian Yousaf Kaukab <yousaf.kaukab@intel.com>
Fri, 9 Jan 2015 12:39:03 +0000 (13:39 +0100)
committerFelipe Balbi <balbi@ti.com>
Mon, 12 Jan 2015 21:34:27 +0000 (15:34 -0600)
This flag is set before sending the zlp. So use present tense instead
of the past tense.

Tested-by: Robert Baldyga <r.baldyga@samsung.com>
Acked-by: Paul Zimmerman <paulz@synopsys.com>
Signed-off-by: Mian Yousaf Kaukab <yousaf.kaukab@intel.com>
Signed-off-by: Felipe Balbi <balbi@ti.com>
drivers/usb/dwc2/core.h
drivers/usb/dwc2/gadget.c

index e963aef1daa2f8c250e29f2ba587431c2a3294cd..f09b3deffdeee6f976f5c369378b6f523c2000c8 100644 (file)
@@ -108,7 +108,7 @@ struct s3c_hsotg_req;
  * @halted: Set if the endpoint has been halted.
  * @periodic: Set if this is a periodic ep, such as Interrupt
  * @isochronous: Set if this is a isochronous ep
- * @sent_zlp: Set if we've sent a zero-length packet.
+ * @send_zlp: Set if we need to send a zero-length packet.
  * @total_data: The total number of data bytes done.
  * @fifo_size: The size of the FIFO (for periodic IN endpoints)
  * @fifo_load: The amount of data loaded into the FIFO (periodic IN)
@@ -149,7 +149,7 @@ struct s3c_hsotg_ep {
        unsigned int            halted:1;
        unsigned int            periodic:1;
        unsigned int            isochronous:1;
-       unsigned int            sent_zlp:1;
+       unsigned int            send_zlp:1;
 
        char                    name[10];
 };
index 65ec0f2dfab1010f681335f1da58beb047fe1a6f..5fdc3f54f2a833912090f393f2193b6d55cc6823 100644 (file)
@@ -607,7 +607,7 @@ static void s3c_hsotg_start_req(struct dwc2_hsotg *hsotg,
                /* Test if zlp is actually required. */
                if ((ureq->length >= hs_ep->ep.maxpacket) &&
                                        !(ureq->length % hs_ep->ep.maxpacket))
-                       hs_ep->sent_zlp = 1;
+                       hs_ep->send_zlp = 1;
        }
 
        epsize |= DXEPTSIZ_PKTCNT(packets);
@@ -1193,7 +1193,7 @@ static void s3c_hsotg_enqueue_setup(struct dwc2_hsotg *hsotg)
        }
 
        hsotg->eps_out[0]->dir_in = 0;
-       hsotg->eps_out[0]->sent_zlp = 0;
+       hsotg->eps_out[0]->send_zlp = 0;
        hsotg->ep0_state = DWC2_EP0_SETUP;
 
        ret = s3c_hsotg_ep_queue(&hsotg->eps_out[0]->ep, req, GFP_ATOMIC);
@@ -1757,9 +1757,9 @@ static void s3c_hsotg_complete_in(struct dwc2_hsotg *hsotg,
        }
 
        /* Zlp for all endpoints, for ep0 only in DATA IN stage */
-       if (hs_ep->sent_zlp) {
+       if (hs_ep->send_zlp) {
                s3c_hsotg_program_zlp(hsotg, hs_ep);
-               hs_ep->sent_zlp = 0;
+               hs_ep->send_zlp = 0;
                /* transfer will be completed on next complete interrupt */
                return;
        }