]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
usb: gadget: atmel: Rename atmel_usba_start()/_stop() to usba_udc_enable()/_disable()
authorZixun LI <admin@hifiphile.com>
Thu, 25 Jul 2024 15:31:59 +0000 (17:31 +0200)
committerMattijs Korpershoek <mkorpershoek@baylibre.com>
Tue, 6 Aug 2024 12:58:14 +0000 (14:58 +0200)
Rename atmel_usba_start() / atmel_usba_stop() to usba_udc_enable()
/ usba_udc_disable(), remove atmel_ prefix to be inline with other
functions. Also avoid confusion with DM start() / stop() functions.

Signed-off-by: Zixun LI <admin@hifiphile.com>
Reviewed-by: Marek Vasut <marex@denx.de>
Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
Link: https://lore.kernel.org/r/20240725153204.358925-6-admin@hifiphile.com
Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
drivers/usb/gadget/atmel_usba_udc.c

index a3d24501ba8778b3a6981220f4e36a39c7fd8b33..ea9ad7585eb4de6058371a68dee2dfcaa5e89788 100644 (file)
@@ -1153,7 +1153,7 @@ static int usba_udc_irq(struct usba_udc *udc)
        return 0;
 }
 
-static int atmel_usba_start(struct usba_udc *udc)
+static int usba_udc_enable(struct usba_udc *udc)
 {
        udc->devstatus = 1 << USB_DEVICE_SELF_POWERED;
 
@@ -1168,7 +1168,7 @@ static int atmel_usba_start(struct usba_udc *udc)
        return 0;
 }
 
-static int atmel_usba_stop(struct usba_udc *udc)
+static int usba_udc_disable(struct usba_udc *udc)
 {
        udc->gadget.speed = USB_SPEED_UNKNOWN;
        reset_all_endpoints(udc);
@@ -1253,7 +1253,7 @@ int usb_gadget_register_driver(struct usb_gadget_driver *driver)
                return -EBUSY;
        }
 
-       atmel_usba_start(udc);
+       usba_udc_enable(udc);
 
        udc->driver = driver;
 
@@ -1279,7 +1279,7 @@ int usb_gadget_unregister_driver(struct usb_gadget_driver *driver)
        driver->unbind(&udc->gadget);
        udc->driver = NULL;
 
-       atmel_usba_stop(udc);
+       usba_udc_disable(udc);
 
        return 0;
 }