mirror of
https://github.com/u-boot/u-boot.git
synced 2025-04-24 22:36:05 +00:00

Implement .handle_interrupts callback as a replacement for deprecated dm_usb_gadget_handle_interrupts() function. The new callback allows for each DM capable USB gadget controller driver to define its own IRQ handling implementation without colliding with other controller drivers. Keep the dm_usb_gadget_handle_interrupts() in this driver for non-DM case for now, until this driver gets fully converted to DM USB gadget. Signed-off-by: Marek Vasut <marek.vasut+renesas@mailbox.org> Reviewed-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> Tested-by: Mattijs Korpershoek <mkorpershoek@baylibre.com> # vim3 Link: https://lore.kernel.org/r/20240614005309.34433-3-marek.vasut+renesas@mailbox.org Signed-off-by: Mattijs Korpershoek <mkorpershoek@baylibre.com>
30 lines
653 B
C
30 lines
653 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/*
|
|
* Cadence USBSS DRD Driver - Gadget Export APIs.
|
|
*
|
|
* Copyright (C) 2017 NXP
|
|
* Copyright (C) 2017-2018 NXP
|
|
*
|
|
* Authors: Peter Chen <peter.chen@nxp.com>
|
|
*/
|
|
#ifndef __LINUX_CDNS3_GADGET_EXPORT
|
|
#define __LINUX_CDNS3_GADGET_EXPORT
|
|
|
|
#ifdef CONFIG_USB_CDNS3_GADGET
|
|
|
|
int cdns3_gadget_init(struct cdns3 *cdns);
|
|
void cdns3_gadget_exit(struct cdns3 *cdns);
|
|
#else
|
|
|
|
static inline int cdns3_gadget_init(struct cdns3 *cdns)
|
|
{
|
|
return -ENXIO;
|
|
}
|
|
|
|
static inline void cdns3_gadget_exit(struct cdns3 *cdns) { }
|
|
|
|
#endif
|
|
|
|
void cdns3_gadget_uboot_handle_interrupt(struct cdns3 *cdns);
|
|
|
|
#endif /* __LINUX_CDNS3_GADGET_EXPORT */
|