linux/drivers/usb/host/ehci-brcm.c

// SPDX-License-Identifier: GPL-2.0
/* Copyright (c) 2020, Broadcom */

#include <linux/clk.h>
#include <linux/dma-mapping.h>
#include <linux/err.h>
#include <linux/kernel.h>
#include <linux/io.h>
#include <linux/module.h>
#include <linux/platform_device.h>
#include <linux/usb.h>
#include <linux/usb/hcd.h>
#include <linux/iopoll.h>

#include "ehci.h"

#define hcd_to_ehci_priv(h)

struct brcm_priv {};

/*
 * ehci_brcm_wait_for_sof
 * Wait for start of next microframe, then wait extra delay microseconds
 */
static inline void ehci_brcm_wait_for_sof(struct ehci_hcd *ehci, u32 delay)
{}

/*
 * ehci_brcm_hub_control
 * The EHCI controller has a bug where it can violate the SOF
 * interval between the first two SOF's transmitted after resume
 * if the resume occurs near the end of the microframe. This causees
 * the controller to detect babble on the suspended port and
 * will eventually cause the controller to reset the port.
 * The fix is to Intercept the echi-hcd request to complete RESUME and
 * align it to the start of the next microframe.
 * See SWLINUX-1909 for more details
 */
static int ehci_brcm_hub_control(
	struct usb_hcd	*hcd,
	u16		typeReq,
	u16		wValue,
	u16		wIndex,
	char		*buf,
	u16		wLength)
{}

static int ehci_brcm_reset(struct usb_hcd *hcd)
{}

static struct hc_driver __read_mostly ehci_brcm_hc_driver;

static const struct ehci_driver_overrides brcm_overrides __initconst =;

static int ehci_brcm_probe(struct platform_device *pdev)
{}

static void ehci_brcm_remove(struct platform_device *dev)
{}

static int __maybe_unused ehci_brcm_suspend(struct device *dev)
{}

static int __maybe_unused ehci_brcm_resume(struct device *dev)
{}

static SIMPLE_DEV_PM_OPS(ehci_brcm_pm_ops, ehci_brcm_suspend,
		ehci_brcm_resume);

static const struct of_device_id brcm_ehci_of_match[] =;

static struct platform_driver ehci_brcm_driver =;

static int __init ehci_brcm_init(void)
{}
module_init();

static void __exit ehci_brcm_exit(void)
{}
module_exit(ehci_brcm_exit);

MODULE_ALIAS();
MODULE_DESCRIPTION();
MODULE_AUTHOR();
MODULE_LICENSE();