USB: fix compilation warning
authorwlf <wulf@rock-chips.com>
Wed, 17 Sep 2014 11:23:52 +0000 (19:23 +0800)
committerwlf <wulf@rock-chips.com>
Wed, 17 Sep 2014 11:23:52 +0000 (19:23 +0800)
drivers/usb/dwc_otg_310/dwc_otg_hcd.c
drivers/usb/dwc_otg_310/dwc_otg_hcd_intr.c
drivers/usb/dwc_otg_310/dwc_otg_hcd_linux.c

index 13f76b4664c9daea188c4407de381e332e3be908..20aaba08ff30702e25db25a8718492d91f8bb959 100755 (executable)
@@ -443,11 +443,10 @@ static int dwc_otg_hcd_sleep_cb(void *p)
  *
  * @param p void pointer to the <code>struct usb_hcd</code>
  */
-extern inline struct usb_hcd *dwc_otg_hcd_to_hcd(dwc_otg_hcd_t *dwc_otg_hcd);
 static int dwc_otg_hcd_rem_wakeup_cb(void *p)
 {
        dwc_otg_hcd_t *dwc_otg_hcd = p;
-       struct usb_hcd *hcd = dwc_otg_hcd_to_hcd(dwc_otg_hcd);
+       struct usb_hcd *hcd = dwc_otg_hcd_get_priv_data(dwc_otg_hcd);
 
        if (dwc_otg_hcd->core_if->lx_state == DWC_OTG_L2) {
                dwc_otg_hcd->flags.b.port_suspend_change = 1;
index 9065863c30483965b43dbfb51b3eb29c04e11efe..c803e39a22d6359b3ded67589ab529cecf8905cd 100755 (executable)
@@ -308,7 +308,6 @@ int32_t dwc_otg_hcd_handle_perio_tx_fifo_empty_intr(dwc_otg_hcd_t *dwc_otg_hcd)
        return 1;
 }
 
-extern inline struct usb_hcd *dwc_otg_hcd_to_hcd(dwc_otg_hcd_t *dwc_otg_hcd);
 /** There are multiple conditions that can cause a port interrupt. This function
  * determines which interrupt conditions have occurred and handles them
  * appropriately. */
@@ -317,7 +316,7 @@ int32_t dwc_otg_hcd_handle_port_intr(dwc_otg_hcd_t *dwc_otg_hcd)
        int retval = 0;
        hprt0_data_t hprt0;
        hprt0_data_t hprt0_modify;
-       struct usb_hcd *hcd = dwc_otg_hcd_to_hcd(dwc_otg_hcd);
+       struct usb_hcd *hcd = dwc_otg_hcd_get_priv_data(dwc_otg_hcd);
        struct usb_bus *bus = hcd_to_bus(hcd);
 
        hprt0.d32 = DWC_READ_REG32(dwc_otg_hcd->core_if->host_if->hprt0);
index 046d1ee8270f50d6f5ef32a67ee7757037fca2e8..0f6eb8a95c99f6c8c26c6a8bb0394d7a745981d7 100755 (executable)
@@ -146,13 +146,11 @@ static inline dwc_otg_hcd_t *hcd_to_dwc_otg_hcd(struct usb_hcd *hcd)
 }
 
 /** Gets the struct usb_hcd that contains a dwc_otg_hcd_t. */
-inline struct usb_hcd *dwc_otg_hcd_to_hcd(dwc_otg_hcd_t *dwc_otg_hcd)
+static inline struct usb_hcd *dwc_otg_hcd_to_hcd(dwc_otg_hcd_t *dwc_otg_hcd)
 {
        return dwc_otg_hcd_get_priv_data(dwc_otg_hcd);
 }
 
-EXPORT_SYMBOL(dwc_otg_hcd_to_hcd);
-
 /** Gets the usb_host_endpoint associated with an URB. */
 inline struct usb_host_endpoint *dwc_urb_to_endpoint(struct urb *urb)
 {