]> git.sur5r.net Git - u-boot/blobdiff - drivers/usb/musb/musb_core.c
SPDX: Convert all of our single license tags to Linux Kernel style
[u-boot] / drivers / usb / musb / musb_core.c
index 6fe2c39bce800cb6eac58008431f8c3a2fb36f10..c6d47bef56a94b428fb192fdd90b78577ee2e124 100644 (file)
@@ -1,24 +1,10 @@
+// SPDX-License-Identifier: GPL-2.0+
 /*
  * Mentor USB OTG Core functionality common for both Host and Device
  * functionality.
  *
  * Copyright (c) 2008 Texas Instruments
  *
- * This program is free software; you can redistribute it and/or
- * modify it under the terms of the GNU General Public License as
- * published by the Free Software Foundation; either version 2 of
- * the License, or (at your option) any later version.
- *
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU General Public License for more details.
- *
- * You should have received a copy of the GNU General Public License
- * along with this program; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
- * MA 02111-1307 USA
- *
  * Author: Thomas Abraham t-abraham@ti.com, Texas Instruments
  */
 
@@ -32,7 +18,7 @@ struct musb_regs *musbr;
  */
 void musb_start(void)
 {
-#if defined(CONFIG_MUSB_HCD)
+#if defined(CONFIG_USB_MUSB_HCD)
        u8 devctl;
        u8 busctl;
 #endif
@@ -45,7 +31,7 @@ void musb_start(void)
 
        /* put into basic highspeed mode and start session */
        writeb(MUSB_POWER_HSENAB, &musbr->power);
-#if defined(CONFIG_MUSB_HCD)
+#if defined(CONFIG_USB_MUSB_HCD)
        /* Program PHY to use EXT VBUS if required */
        if (musb_cfg.extvbus == 1) {
                busctl = musb_read_ulpi_buscontrol(musbr);
@@ -76,7 +62,7 @@ void musb_start(void)
  * epinfo      - Pointer to EP configuration table
  * cnt         - Number of entries in the EP conf table.
  */
-void musb_configure_ep(struct musb_epinfo *epinfo, u8 cnt)
+void musb_configure_ep(const struct musb_epinfo *epinfo, u8 cnt)
 {
        u16 csr;
        u16 fifoaddr = 64; /* First 64 bytes of FIFO reserved for EP0 */
@@ -94,7 +80,7 @@ void musb_configure_ep(struct musb_epinfo *epinfo, u8 cnt)
                        config_fifo(tx, idx, fifoaddr);
 
                        csr = readw(&musbr->txcsr);
-#if defined(CONFIG_MUSB_HCD)
+#if defined(CONFIG_USB_MUSB_HCD)
                        /* clear the data toggle bit */
                        writew(csr | MUSB_TXCSR_CLRDATATOG, &musbr->txcsr);
 #endif
@@ -107,7 +93,7 @@ void musb_configure_ep(struct musb_epinfo *epinfo, u8 cnt)
                        config_fifo(rx, idx, fifoaddr);
 
                        csr = readw(&musbr->rxcsr);
-#if defined(CONFIG_MUSB_HCD)
+#if defined(CONFIG_USB_MUSB_HCD)
                        /* clear the data toggle bit */
                        writew(csr | MUSB_RXCSR_CLRDATATOG, &musbr->rxcsr);
 #endif