/kernel/linux/linux-5.10/drivers/usb/host/ |
D | ehci-hcd.c | 110 static unsigned ehci_moschip_read_frame_index(struct ehci_hcd *ehci) in ehci_moschip_read_frame_index() argument 114 uf = ehci_readl(ehci, &ehci->regs->frame_index); in ehci_moschip_read_frame_index() 116 uf = ehci_readl(ehci, &ehci->regs->frame_index); in ehci_moschip_read_frame_index() 120 static inline unsigned ehci_read_frame_index(struct ehci_hcd *ehci) in ehci_read_frame_index() argument 122 if (ehci->frame_index_bug) in ehci_read_frame_index() 123 return ehci_moschip_read_frame_index(ehci); in ehci_read_frame_index() 124 return ehci_readl(ehci, &ehci->regs->frame_index); in ehci_read_frame_index() 148 int ehci_handshake(struct ehci_hcd *ehci, void __iomem *ptr, in ehci_handshake() argument 154 result = ehci_readl(ehci, ptr); in ehci_handshake() 168 static int tdi_in_host_mode (struct ehci_hcd *ehci) in tdi_in_host_mode() argument [all …]
|
D | ehci-timer.c | 11 static void ehci_set_command_bit(struct ehci_hcd *ehci, u32 bit) in ehci_set_command_bit() argument 13 ehci->command |= bit; in ehci_set_command_bit() 14 ehci_writel(ehci, ehci->command, &ehci->regs->command); in ehci_set_command_bit() 17 ehci_readl(ehci, &ehci->regs->command); in ehci_set_command_bit() 21 static void ehci_clear_command_bit(struct ehci_hcd *ehci, u32 bit) in ehci_clear_command_bit() argument 23 ehci->command &= ~bit; in ehci_clear_command_bit() 24 ehci_writel(ehci, ehci->command, &ehci->regs->command); in ehci_clear_command_bit() 27 ehci_readl(ehci, &ehci->regs->command); in ehci_clear_command_bit() 76 static void ehci_enable_event(struct ehci_hcd *ehci, unsigned event, in ehci_enable_event() argument 79 ktime_t *timeout = &ehci->hr_timeouts[event]; in ehci_enable_event() [all …]
|
D | ehci-hub.c | 22 static void unlink_empty_async_suspended(struct ehci_hcd *ehci); 33 static void ehci_handover_companion_ports(struct ehci_hcd *ehci) in ehci_handover_companion_ports() argument 39 struct usb_hcd *hcd = ehci_to_hcd(ehci); in ehci_handover_companion_ports() 41 if (!ehci->owned_ports) in ehci_handover_companion_ports() 55 port = HCS_N_PORTS(ehci->hcs_params); in ehci_handover_companion_ports() 57 if (test_bit(port, &ehci->owned_ports)) { in ehci_handover_companion_ports() 58 reg = &ehci->regs->port_status[port]; in ehci_handover_companion_ports() 59 status = ehci_readl(ehci, reg) & ~PORT_RWC_BITS; in ehci_handover_companion_ports() 61 ehci_port_power(ehci, port, true); in ehci_handover_companion_ports() 68 spin_lock_irq(&ehci->lock); in ehci_handover_companion_ports() [all …]
|
D | ehci-mem.c | 25 static inline void ehci_qtd_init(struct ehci_hcd *ehci, struct ehci_qtd *qtd, in ehci_qtd_init() argument 30 qtd->hw_token = cpu_to_hc32(ehci, QTD_STS_HALT); in ehci_qtd_init() 31 qtd->hw_next = EHCI_LIST_END(ehci); in ehci_qtd_init() 32 qtd->hw_alt_next = EHCI_LIST_END(ehci); in ehci_qtd_init() 36 static struct ehci_qtd *ehci_qtd_alloc (struct ehci_hcd *ehci, gfp_t flags) in ehci_qtd_alloc() argument 41 qtd = dma_pool_alloc (ehci->qtd_pool, flags, &dma); in ehci_qtd_alloc() 43 ehci_qtd_init(ehci, qtd, dma); in ehci_qtd_alloc() 48 static inline void ehci_qtd_free (struct ehci_hcd *ehci, struct ehci_qtd *qtd) in ehci_qtd_free() argument 50 dma_pool_free (ehci->qtd_pool, qtd, qtd->qtd_dma); in ehci_qtd_free() 54 static void qh_destroy(struct ehci_hcd *ehci, struct ehci_qh *qh) in qh_destroy() argument [all …]
|
D | ehci-q.c | 37 qtd_fill(struct ehci_hcd *ehci, struct ehci_qtd *qtd, dma_addr_t buf, in qtd_fill() argument 44 qtd->hw_buf[0] = cpu_to_hc32(ehci, (u32)addr); in qtd_fill() 45 qtd->hw_buf_hi[0] = cpu_to_hc32(ehci, (u32)(addr >> 32)); in qtd_fill() 56 qtd->hw_buf[i] = cpu_to_hc32(ehci, (u32)addr); in qtd_fill() 57 qtd->hw_buf_hi[i] = cpu_to_hc32(ehci, in qtd_fill() 70 qtd->hw_token = cpu_to_hc32(ehci, (count << 16) | token); in qtd_fill() 79 qh_update (struct ehci_hcd *ehci, struct ehci_qh *qh, struct ehci_qtd *qtd) in qh_update() argument 86 hw->hw_qtd_next = QTD_NEXT(ehci, qtd->qtd_dma); in qh_update() 87 hw->hw_alt_next = EHCI_LIST_END(ehci); in qh_update() 94 if (!(hw->hw_info1 & cpu_to_hc32(ehci, QH_TOGGLE_CTL))) { in qh_update() [all …]
|
D | ehci-sched.c | 32 periodic_next_shadow(struct ehci_hcd *ehci, union ehci_shadow *periodic, in periodic_next_shadow() argument 35 switch (hc32_to_cpu(ehci, tag)) { in periodic_next_shadow() 49 shadow_next_periodic(struct ehci_hcd *ehci, union ehci_shadow *periodic, in shadow_next_periodic() argument 52 switch (hc32_to_cpu(ehci, tag)) { in shadow_next_periodic() 63 static void periodic_unlink(struct ehci_hcd *ehci, unsigned frame, void *ptr) in periodic_unlink() argument 65 union ehci_shadow *prev_p = &ehci->pshadow[frame]; in periodic_unlink() 66 __hc32 *hw_p = &ehci->periodic[frame]; in periodic_unlink() 71 prev_p = periodic_next_shadow(ehci, prev_p, in periodic_unlink() 72 Q_NEXT_TYPE(ehci, *hw_p)); in periodic_unlink() 73 hw_p = shadow_next_periodic(ehci, &here, in periodic_unlink() [all …]
|
D | ehci-dbg.c | 15 static void dbg_hcs_params(struct ehci_hcd *ehci, char *label) in dbg_hcs_params() argument 17 u32 params = ehci_readl(ehci, &ehci->caps->hcs_params); in dbg_hcs_params() 19 ehci_dbg(ehci, in dbg_hcs_params() 37 byte = readb(&ehci->caps->portroute[(i >> 1)]); in dbg_hcs_params() 42 ehci_dbg(ehci, "%s portroute %s\n", label, buf); in dbg_hcs_params() 51 static void dbg_hcc_params(struct ehci_hcd *ehci, char *label) in dbg_hcc_params() argument 53 u32 params = ehci_readl(ehci, &ehci->caps->hcc_params); in dbg_hcc_params() 56 ehci_dbg(ehci, in dbg_hcc_params() 63 ehci_dbg(ehci, in dbg_hcc_params() 80 dbg_qtd(const char *label, struct ehci_hcd *ehci, struct ehci_qtd *qtd) in dbg_qtd() argument [all …]
|
D | ehci-pci.c | 60 static int ehci_pci_reinit(struct ehci_hcd *ehci, struct pci_dev *pdev) in ehci_pci_reinit() argument 71 ehci_dbg(ehci, "MWI active\n"); in ehci_pci_reinit() 79 ehci_writel(ehci, INTEL_QUARK_X1000_EHCI_MAX_THRESHOLD, in ehci_pci_reinit() 80 ehci->regs->intel_quark_x1000_insnreg01); in ehci_pci_reinit() 89 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in ehci_pci_setup() local 94 ehci->caps = hcd->regs; in ehci_pci_setup() 110 ehci->big_endian_mmio = 1; in ehci_pci_setup() 112 ehci_warn(ehci, in ehci_pci_setup() 128 ehci_warn(ehci, "can't enable NVidia " in ehci_pci_setup() 137 ehci->no_selective_suspend = 1; in ehci_pci_setup() [all …]
|
D | ehci-fsl.c | 153 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in fsl_ehci_drv_probe() local 157 hcd, ehci, hcd->usb_phy); in fsl_ehci_drv_probe() 161 &ehci_to_hcd(ehci)->self); in fsl_ehci_drv_probe() 202 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in ehci_fsl_setup_phy() local 212 portsc = ehci_readl(ehci, &ehci->regs->port_status[port_offset]); in ehci_fsl_setup_phy() 289 ehci_writel(ehci, portsc, &ehci->regs->port_status[port_offset]); in ehci_fsl_setup_phy() 301 static int ehci_fsl_usb_setup(struct ehci_hcd *ehci) in ehci_fsl_usb_setup() argument 303 struct usb_hcd *hcd = ehci_to_hcd(ehci); in ehci_fsl_usb_setup() 326 ehci->has_fsl_hs_errata = 1; in ehci_fsl_usb_setup() 329 ehci->has_fsl_susp_errata = 1; in ehci_fsl_usb_setup() [all …]
|
D | ehci-sysfs.c | 14 struct ehci_hcd *ehci; in companion_show() local 19 ehci = hcd_to_ehci(dev_get_drvdata(dev)); in companion_show() 20 nports = HCS_N_PORTS(ehci->hcs_params); in companion_show() 23 if (test_bit(index, &ehci->companion_ports)) { in companion_show() 41 struct ehci_hcd *ehci; in companion_store() local 44 ehci = hcd_to_ehci(dev_get_drvdata(dev)); in companion_store() 52 if (portnum <= 0 || portnum > HCS_N_PORTS(ehci->hcs_params)) in companion_store() 56 set_bit(portnum, &ehci->companion_ports); in companion_store() 58 clear_bit(portnum, &ehci->companion_ports); in companion_store() 59 set_owner(ehci, portnum, new_owner); in companion_store() [all …]
|
D | ehci.h | 267 static inline struct usb_hcd *ehci_to_hcd(struct ehci_hcd *ehci) in ehci_to_hcd() argument 269 return container_of((void *) ehci, struct usb_hcd, hcd_priv); in ehci_to_hcd() 278 #define QTD_NEXT(ehci, dma) cpu_to_hc32(ehci, (u32)dma) argument 307 #define ACTIVE_BIT(ehci) cpu_to_hc32(ehci, QTD_STS_ACTIVE) argument 308 #define HALT_BIT(ehci) cpu_to_hc32(ehci, QTD_STS_HALT) argument 309 #define STATUS_BIT(ehci) cpu_to_hc32(ehci, QTD_STS_STS) argument 322 #define QTD_MASK(ehci) cpu_to_hc32(ehci, ~0x1f) argument 329 #define Q_NEXT_TYPE(ehci, dma) ((dma) & cpu_to_hc32(ehci, 3 << 1)) argument 345 #define QH_NEXT(ehci, dma) \ argument 346 (cpu_to_hc32(ehci, (((u32) dma) & ~0x01f) | Q_TYPE_QH)) [all …]
|
D | ehci-brcm.c | 27 static inline void ehci_brcm_wait_for_sof(struct ehci_hcd *ehci, u32 delay) in ehci_brcm_wait_for_sof() argument 29 u32 frame_idx = ehci_readl(ehci, &ehci->regs->frame_index); in ehci_brcm_wait_for_sof() 34 res = readl_relaxed_poll_timeout(&ehci->regs->frame_index, val, in ehci_brcm_wait_for_sof() 37 ehci_err(ehci, "Error waiting for SOF\n"); in ehci_brcm_wait_for_sof() 60 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in ehci_brcm_hub_control() local 61 int ports = HCS_N_PORTS(ehci->hcs_params); in ehci_brcm_hub_control() 66 status_reg = &ehci->regs->port_status[(wIndex & 0xff) - 1]; in ehci_brcm_hub_control() 74 ehci->reset_done[wIndex-1] && in ehci_brcm_hub_control() 75 time_after_eq(jiffies, ehci->reset_done[wIndex-1]) && in ehci_brcm_hub_control() 76 (ehci_readl(ehci, status_reg) & PORT_RESUME)) { in ehci_brcm_hub_control() [all …]
|
D | ehci-tegra.c | 104 struct ehci_hcd *ehci, in tegra_ehci_internal_port_reset() argument 114 spin_lock_irqsave(&ehci->lock, flags); in tegra_ehci_internal_port_reset() 115 saved_usbintr = ehci_readl(ehci, &ehci->regs->intr_enable); in tegra_ehci_internal_port_reset() 117 ehci_writel(ehci, 0, &ehci->regs->intr_enable); in tegra_ehci_internal_port_reset() 118 spin_unlock_irqrestore(&ehci->lock, flags); in tegra_ehci_internal_port_reset() 125 temp = ehci_readl(ehci, portsc_reg); in tegra_ehci_internal_port_reset() 127 ehci_writel(ehci, temp, portsc_reg); in tegra_ehci_internal_port_reset() 130 ehci_writel(ehci, temp, portsc_reg); in tegra_ehci_internal_port_reset() 141 temp = ehci_readl(ehci, portsc_reg); in tegra_ehci_internal_port_reset() 154 ehci_writel(ehci, PORT_CSC, portsc_reg); in tegra_ehci_internal_port_reset() [all …]
|
D | ehci-platform.c | 63 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in ehci_platform_reset() local 66 ehci->has_synopsys_hc_bug = pdata->has_synopsys_hc_bug; in ehci_platform_reset() 74 ehci->caps = hcd->regs + pdata->caps_offset; in ehci_platform_reset() 80 ehci->need_io_watchdog = 0; in ehci_platform_reset() 83 ehci_writel(ehci, BCM_USB_FIFO_THRESHOLD, in ehci_platform_reset() 84 &ehci->regs->bcm_iproc_insnreg01); in ehci_platform_reset() 145 static bool quirk_poll_check_port_status(struct ehci_hcd *ehci) in quirk_poll_check_port_status() argument 147 u32 port_status = ehci_readl(ehci, &ehci->regs->port_status[0]); in quirk_poll_check_port_status() 167 static void quirk_poll_rebind_companion(struct ehci_hcd *ehci) in quirk_poll_rebind_companion() argument 170 struct usb_hcd *hcd = ehci_to_hcd(ehci); in quirk_poll_rebind_companion() [all …]
|
D | ehci-ppc-of.c | 98 struct ehci_hcd *ehci = NULL; in ehci_hcd_ppc_of_probe() local 135 ehci = hcd_to_ehci(hcd); in ehci_hcd_ppc_of_probe() 140 ehci->ohci_hcctrl_reg = in ehci_hcd_ppc_of_probe() 146 if (!ehci->ohci_hcctrl_reg) { in ehci_hcd_ppc_of_probe() 149 ehci->has_amcc_usb23 = 1; in ehci_hcd_ppc_of_probe() 154 ehci->big_endian_mmio = 1; in ehci_hcd_ppc_of_probe() 155 ehci->big_endian_desc = 1; in ehci_hcd_ppc_of_probe() 158 ehci->big_endian_mmio = 1; in ehci_hcd_ppc_of_probe() 160 ehci->big_endian_desc = 1; in ehci_hcd_ppc_of_probe() 162 ehci->caps = hcd->regs; in ehci_hcd_ppc_of_probe() [all …]
|
D | Makefile | 40 obj-$(CONFIG_USB_EHCI_HCD) += ehci-hcd.o 41 obj-$(CONFIG_USB_EHCI_PCI) += ehci-pci.o 42 obj-$(CONFIG_USB_EHCI_HCD_PLATFORM) += ehci-platform.o 43 obj-$(CONFIG_USB_EHCI_MXC) += ehci-mxc.o 44 obj-$(CONFIG_USB_EHCI_HCD_NPCM7XX) += ehci-npcm7xx.o 45 obj-$(CONFIG_USB_EHCI_HCD_OMAP) += ehci-omap.o 46 obj-$(CONFIG_USB_EHCI_HCD_ORION) += ehci-orion.o 47 obj-$(CONFIG_USB_EHCI_HCD_SPEAR) += ehci-spear.o 48 obj-$(CONFIG_USB_EHCI_HCD_STI) += ehci-st.o 49 obj-$(CONFIG_USB_EHCI_EXYNOS) += ehci-exynos.o [all …]
|
D | ehci-pmcmsp.c | 39 static void usb_hcd_tdi_set_mode(struct ehci_hcd *ehci) in usb_hcd_tdi_set_mode() argument 45 struct ehci_regs *reg_base = ehci->regs; in usb_hcd_tdi_set_mode() 53 val = ehci_readl(ehci, (u32 *)base); in usb_hcd_tdi_set_mode() 54 ehci_writel(ehci, (val | USB_CTRL_MODE_STREAM_DISABLE), in usb_hcd_tdi_set_mode() 58 val = ehci_readl(ehci, (u32 *)statreg); in usb_hcd_tdi_set_mode() 60 ehci_writel(ehci, val, (u32 *)statreg); in usb_hcd_tdi_set_mode() 63 ehci_writel(ehci, USB_CTRL_FIFO_THRESH, (u32 *)fiforeg); in usb_hcd_tdi_set_mode() 72 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in ehci_msp_setup() local 75 ehci->big_endian_mmio = 1; in ehci_msp_setup() 76 ehci->big_endian_desc = 1; in ehci_msp_setup() [all …]
|
D | ehci-mxc.c | 45 struct ehci_hcd *ehci; in ehci_mxc_drv_probe() local 70 ehci = hcd_to_ehci(hcd); in ehci_mxc_drv_probe() 71 priv = (struct ehci_mxc_priv *) ehci->priv; in ehci_mxc_drv_probe() 107 ehci->caps = hcd->regs + 0x100; in ehci_mxc_drv_probe() 108 ehci->regs = hcd->regs + 0x100 + in ehci_mxc_drv_probe() 109 HC_LENGTH(ehci, ehci_readl(ehci, &ehci->caps->hc_capbase)); in ehci_mxc_drv_probe() 112 ehci_writel(ehci, pdata->portsc, &ehci->regs->port_status[0]); in ehci_mxc_drv_probe() 161 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in ehci_mxc_drv_remove() local 162 struct ehci_mxc_priv *priv = (struct ehci_mxc_priv *) ehci->priv; in ehci_mxc_drv_remove()
|
D | ehci-grlib.c | 76 struct ehci_hcd *ehci = NULL; in ehci_hcd_grlib_probe() local 115 ehci = hcd_to_ehci(hcd); in ehci_hcd_grlib_probe() 117 ehci->caps = hcd->regs; in ehci_hcd_grlib_probe() 120 hc_capbase = ehci_readl(ehci, &ehci->caps->hc_capbase); in ehci_hcd_grlib_probe() 121 if (HC_VERSION(ehci, hc_capbase) != GRUSBHC_HCIVERSION) { in ehci_hcd_grlib_probe() 122 ehci->big_endian_mmio = 1; in ehci_hcd_grlib_probe() 123 ehci->big_endian_desc = 1; in ehci_hcd_grlib_probe() 124 ehci->big_endian_capbase = 1; in ehci_hcd_grlib_probe()
|
D | ehci-mv.c | 70 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in mv_ehci_reset() local 86 status = ehci_readl(ehci, &ehci->regs->port_status[0]); in mv_ehci_reset() 88 ehci_writel(ehci, status, &ehci->regs->port_status[0]); in mv_ehci_reset() 90 ehci_writel(ehci, status, &ehci->regs->port_status[0]); in mv_ehci_reset() 107 struct ehci_hcd *ehci; in mv_ehci_probe() local 173 ehci = hcd_to_ehci(hcd); in mv_ehci_probe() 174 ehci->caps = (struct ehci_caps __iomem *) ehci_mv->cap_regs; in mv_ehci_probe() 213 status = ehci_readl(ehci, &ehci->regs->port_status[0]); in mv_ehci_probe() 217 ehci_writel(ehci, status, &ehci->regs->port_status[0]); in mv_ehci_probe()
|
D | ehci-xilinx-of.c | 120 struct ehci_hcd *ehci; in ehci_hcd_xilinx_of_probe() local 157 ehci = hcd_to_ehci(hcd); in ehci_hcd_xilinx_of_probe() 162 ehci->big_endian_mmio = 1; in ehci_hcd_xilinx_of_probe() 163 ehci->big_endian_desc = 1; in ehci_hcd_xilinx_of_probe() 169 ehci_dbg(ehci, "USB host controller supports FS devices\n"); in ehci_hcd_xilinx_of_probe() 172 ehci_dbg(ehci, in ehci_hcd_xilinx_of_probe() 179 ehci->caps = hcd->regs + 0x100; in ehci_hcd_xilinx_of_probe()
|
/kernel/linux/linux-5.10/drivers/usb/chipidea/ |
D | host.c | 34 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in ehci_ci_portpower() local 35 struct ehci_ci_priv *priv = (struct ehci_ci_priv *)ehci->priv; in ehci_ci_portpower() 39 int port = HCS_N_PORTS(ehci->hcs_params); in ehci_ci_portpower() 75 struct ehci_hcd *ehci = hcd_to_ehci(hcd); in ehci_ci_reset() local 82 ehci->need_io_watchdog = 0; in ehci_ci_reset() 110 struct ehci_hcd *ehci; in host_start() local 136 ehci = hcd_to_ehci(hcd); in host_start() 137 ehci->caps = ci->hw_bank.cap; in host_start() 138 ehci->has_hostpc = ci->hw_bank.lpm; in host_start() 139 ehci->has_tdi_phy_lpm = ci->hw_bank.lpm; in host_start() [all …]
|
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/mfd/ |
D | omap-usb-host.txt | 18 "ehci-phy", 19 "ehci-tll", 20 "ehci-hsic", 67 See Documentation/devicetree/bindings/usb/ehci-omap.txt and 87 usbhsehci: ehci@4a064c00 { 88 compatible = "ti,ehci-omap", "usb-ehci"; 96 port1-mode = "ehci-phy"; 97 port2-mode = "ehci-tll"; 98 port3-mode = "ehci-phy";
|
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/usb/ |
D | spear-usb.txt | 8 - compatible: "st,spear600-ehci" 13 ehci@e1800000 { 14 compatible = "st,spear600-ehci", "usb-ehci";
|
D | ehci-orion.txt | 5 "marvell,orion-ehci" 6 "marvell,armada-3700-ehci" 18 ehci@50000 { 19 compatible = "marvell,orion-ehci";
|