]> git.karo-electronics.de Git - linux-beck.git/commitdiff
usb: dwc2: Move functions from header to source
authorRazmik Karapetyan <razmik@synopsys.com>
Wed, 16 Nov 2016 23:34:04 +0000 (15:34 -0800)
committerFelipe Balbi <felipe.balbi@linux.intel.com>
Fri, 18 Nov 2016 11:54:54 +0000 (13:54 +0200)
Removed extern specifier from dwc2_host_start(), dwc2_host_disconnect()
and dwc2_host_hub_info() functions. Moved those functions from header
to source. Then make them static.

Signed-off-by: Razmik Karapetyan <razmik@synopsys.com>
Signed-off-by: John Youn <johnyoun@synopsys.com>
Signed-off-by: Felipe Balbi <felipe.balbi@linux.intel.com>
drivers/usb/dwc2/hcd.c
drivers/usb/dwc2/hcd.h

index fb7f8e9784eea0d58229a53c909a10b572e921a9..911c3b36ac067028acdaa5d53bd0c9e8702f8942 100644 (file)
@@ -649,6 +649,35 @@ static void dwc2_dump_channel_info(struct dwc2_hsotg *hsotg,
 #endif /* VERBOSE_DEBUG */
 }
 
+static int _dwc2_hcd_start(struct usb_hcd *hcd);
+
+static void dwc2_host_start(struct dwc2_hsotg *hsotg)
+{
+       struct usb_hcd *hcd = dwc2_hsotg_to_hcd(hsotg);
+
+       hcd->self.is_b_host = dwc2_hcd_is_b_host(hsotg);
+       _dwc2_hcd_start(hcd);
+}
+
+static void dwc2_host_disconnect(struct dwc2_hsotg *hsotg)
+{
+       struct usb_hcd *hcd = dwc2_hsotg_to_hcd(hsotg);
+
+       hcd->self.is_b_host = 0;
+}
+
+static void dwc2_host_hub_info(struct dwc2_hsotg *hsotg, void *context,
+                              int *hub_addr, int *hub_port)
+{
+       struct urb *urb = context;
+
+       if (urb->dev->tt)
+               *hub_addr = urb->dev->tt->hub->devnum;
+       else
+               *hub_addr = 0;
+       *hub_port = urb->dev->ttport;
+}
+
 /*
  * =========================================================================
  *  Low Level Host Channel Access Functions
@@ -4022,35 +4051,6 @@ static struct dwc2_hsotg *dwc2_hcd_to_hsotg(struct usb_hcd *hcd)
        return p->hsotg;
 }
 
-static int _dwc2_hcd_start(struct usb_hcd *hcd);
-
-void dwc2_host_start(struct dwc2_hsotg *hsotg)
-{
-       struct usb_hcd *hcd = dwc2_hsotg_to_hcd(hsotg);
-
-       hcd->self.is_b_host = dwc2_hcd_is_b_host(hsotg);
-       _dwc2_hcd_start(hcd);
-}
-
-void dwc2_host_disconnect(struct dwc2_hsotg *hsotg)
-{
-       struct usb_hcd *hcd = dwc2_hsotg_to_hcd(hsotg);
-
-       hcd->self.is_b_host = 0;
-}
-
-void dwc2_host_hub_info(struct dwc2_hsotg *hsotg, void *context, int *hub_addr,
-                       int *hub_port)
-{
-       struct urb *urb = context;
-
-       if (urb->dev->tt)
-               *hub_addr = urb->dev->tt->hub->devnum;
-       else
-               *hub_addr = 0;
-       *hub_port = urb->dev->ttport;
-}
-
 /**
  * dwc2_host_get_tt_info() - Get the dwc2_tt associated with context
  *
index d92656d21b4d7ea5cf78213d6331922a16252503..1ed5fa2beff4a0b6a54486299419b70626ce89b5 100644 (file)
@@ -793,11 +793,6 @@ extern void dwc2_hcd_dump_frrem(struct dwc2_hsotg *hsotg);
 #define URB_SEND_ZERO_PACKET   0x2
 
 /* Host driver callbacks */
-
-extern void dwc2_host_start(struct dwc2_hsotg *hsotg);
-extern void dwc2_host_disconnect(struct dwc2_hsotg *hsotg);
-extern void dwc2_host_hub_info(struct dwc2_hsotg *hsotg, void *context,
-                              int *hub_addr, int *hub_port);
 extern struct dwc2_tt *dwc2_host_get_tt_info(struct dwc2_hsotg *hsotg,
                                             void *context, gfp_t mem_flags,
                                             int *ttport);