Skip to content

Commit 0cbd4b3

Browse files
Chunfeng Yungregkh
authored andcommitted
xhci: mediatek: support MTK xHCI host controller
There some vendor quirks for MTK xhci host controller: 1. It defines some extra SW scheduling parameters for HW to minimize the scheduling effort for synchronous and interrupt endpoints. The parameters are put into reseved DWs of slot context and endpoint context. 2. Its IMODI unit for Interrupter Moderation register is 8 times as much as that defined in xHCI spec. 3. Its TDS in Normal TRB defines a number of packets that remains to be transferred for a TD after processing all Max packets in all previous TRBs. Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Tested-by: Daniel Thompson <daniel.thompson@linaro.org> Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org> Signed-off-by: Mathias Nyman <mathias.nyman@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent c74732e commit 0cbd4b3

File tree

8 files changed

+1383
-6
lines changed

8 files changed

+1383
-6
lines changed

drivers/usb/host/Kconfig

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,15 @@ config USB_XHCI_PLATFORM
4141

4242
If unsure, say N.
4343

44+
config USB_XHCI_MTK
45+
tristate "xHCI support for Mediatek MT65xx"
46+
select MFD_SYSCON
47+
depends on ARCH_MEDIATEK || COMPILE_TEST
48+
---help---
49+
Say 'Y' to enable the support for the xHCI host controller
50+
found in Mediatek MT65xx SoCs.
51+
If unsure, say N.
52+
4453
config USB_XHCI_MVEBU
4554
tristate "xHCI support for Marvell Armada 375/38x"
4655
select USB_XHCI_PLATFORM

drivers/usb/host/Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ fhci-$(CONFIG_FHCI_DEBUG) += fhci-dbg.o
1313
xhci-hcd-y := xhci.o xhci-mem.o
1414
xhci-hcd-y += xhci-ring.o xhci-hub.o xhci-dbg.o
1515
xhci-hcd-y += xhci-trace.o
16+
ifneq ($(CONFIG_USB_XHCI_MTK), )
17+
xhci-hcd-y += xhci-mtk-sch.o
18+
endif
1619

1720
xhci-plat-hcd-y := xhci-plat.o
1821
ifneq ($(CONFIG_USB_XHCI_MVEBU), )
@@ -64,6 +67,7 @@ obj-$(CONFIG_USB_FHCI_HCD) += fhci.o
6467
obj-$(CONFIG_USB_XHCI_HCD) += xhci-hcd.o
6568
obj-$(CONFIG_USB_XHCI_PCI) += xhci-pci.o
6669
obj-$(CONFIG_USB_XHCI_PLATFORM) += xhci-plat-hcd.o
70+
obj-$(CONFIG_USB_XHCI_MTK) += xhci-mtk.o
6771
obj-$(CONFIG_USB_SL811_HCD) += sl811-hcd.o
6872
obj-$(CONFIG_USB_SL811_CS) += sl811_cs.o
6973
obj-$(CONFIG_USB_U132_HCD) += u132-hcd.o

0 commit comments

Comments
 (0)