[mips] Pin control configuration for MediaTek RT2880
RT2880 is MIPS4Kc SoC used in many SOHO routers. This commits adds GPIO pin control configuration of RT2880. Submitted by: Hiroki Mori <yamori83@yahoo.co.jp> Reviewed by: mizhka, sgalabov Differential Revision: https://reviews.freebsd.org/D12648
This commit is contained in:
parent
29181cc4cb
commit
b2e673ff7f
@ -169,6 +169,9 @@ mtk_pinctrl_configure(device_t dev, phandle_t cfgxref)
|
||||
socid = mtk_soc_get_socid();
|
||||
|
||||
switch (socid) {
|
||||
case MTK_SOC_RT2880:
|
||||
pintable = rt2880_pintable;
|
||||
break;
|
||||
case MTK_SOC_RT3050: /* fallthrough */
|
||||
case MTK_SOC_RT3052:
|
||||
case MTK_SOC_RT3350:
|
||||
|
@ -118,6 +118,14 @@ DECL_FUNC(gex_func) = {
|
||||
FUNC("ge1", 0), FUNC("ge2", 0), FUNC("gpio", 1)
|
||||
};
|
||||
|
||||
DECL_FUNC(rt2880_uartf_func) = {
|
||||
FUNC("uartf", 0), FUNC("gpio", 1)
|
||||
};
|
||||
|
||||
DECL_FUNC(rt2880_pci_func) = {
|
||||
FUNC("pci", 0), FUNC("gpio", 1)
|
||||
};
|
||||
|
||||
DECL_FUNC(rt3883_pci_func) = {
|
||||
FUNC("pci-dev", 0), FUNC("pci-host2", 1), FUNC("pci-host1", 2),
|
||||
FUNC("pci-fnc", 3), FUNC("gpio", 7)
|
||||
@ -298,6 +306,18 @@ DECL_TABLE(mt7620_pintable) = {
|
||||
GROUP_END
|
||||
};
|
||||
|
||||
DECL_TABLE(rt2880_pintable) = {
|
||||
GROUP("i2c", SYSCTL_GPIOMODE, 0, 1, i2c_func),
|
||||
GROUP("uartf", SYSCTL_GPIOMODE, 1, 1, rt2880_uartf_func),
|
||||
GROUP("spi", SYSCTL_GPIOMODE, 2, 1, spi_func),
|
||||
GROUP("uartlite", SYSCTL_GPIOMODE, 3, 1, uartlite_func),
|
||||
GROUP("jtag", SYSCTL_GPIOMODE, 4, 1, jtag_func),
|
||||
GROUP("mdio", SYSCTL_GPIOMODE, 5, 1, mdio_func),
|
||||
GROUP("sdram", SYSCTL_GPIOMODE, 6, 1, sdram_func),
|
||||
GROUP("pci", SYSCTL_GPIOMODE, 7, 1, rt2880_pci_func),
|
||||
GROUP_END
|
||||
};
|
||||
|
||||
DECL_TABLE(rt3050_pintable) = {
|
||||
GROUP("i2c", SYSCTL_GPIOMODE, 0, 1, i2c_func),
|
||||
GROUP("spi", SYSCTL_GPIOMODE, 1, 1, spi_func),
|
||||
|
Loading…
Reference in New Issue
Block a user