1menu "MediaTek MIPS platforms"
2	depends on ARCH_MTMIPS
3
4config SYS_VENDOR
5	default "mediatek" if BOARD_MT7628_RFB || BOARD_MT7620_RFB || BOARD_MT7620_MT7530_RFB
6
7config SYS_MALLOC_F_LEN
8	default 0x1000
9
10config SYS_SOC
11	default "mt7620" if SOC_MT7620
12	default "mt7621" if SOC_MT7621
13	default "mt7628" if SOC_MT7628
14
15config SYS_DCACHE_SIZE
16	default 32768
17
18config SYS_DCACHE_LINE_SIZE
19	default 32
20
21config SYS_ICACHE_SIZE
22	default 65536 if SOC_MT7620 || SOC_MT7628
23	default 32768 if SOC_MT7621
24
25config SYS_ICACHE_LINE_SIZE
26	default 32
27
28config SYS_SCACHE_LINE_SIZE
29	default 32 if SOC_MT7621
30
31config TEXT_BASE
32	default 0x9c000000 if !SPL && !SOC_MT7621
33	default 0x80200000 if SPL || SOC_MT7621
34
35config SPL_TEXT_BASE
36	default 0x9c000000 if !SOC_MT7621
37	default 0x80100000 if SOC_MT7621
38
39config SPL_SIZE_LIMIT
40	default 0x30000 if SOC_MT7621
41
42config TPL_TEXT_BASE
43	default 0xbfc00000 if SOC_MT7621
44
45config TPL_MAX_SIZE
46	default 4096 if SOC_MT7621
47
48config SPL_PAYLOAD
49	default "u-boot-lzma.img" if SPL_LZMA
50
51config BUILD_TARGET
52	default "u-boot-with-spl.bin" if SPL && !SOC_MT7621
53	default "u-boot-lzma.img" if SOC_MT7621
54	default "u-boot.bin"
55
56config MAX_MEM_SIZE
57	int
58	default 256 if SOC_MT7620 || SOC_MT7628
59	default 512 if SOC_MT7621
60
61choice
62	prompt "MediaTek MIPS SoC select"
63
64config SOC_MT7620
65	bool "MT7620"
66	select SYS_CACHE_SHIFT_5
67	select SYS_MIPS_CACHE_INIT_RAM_LOAD
68	select PINCTRL_MT7620
69	select MT7620_SERIAL
70	select MISC
71	select SPL_SEPARATE_BSS if SPL
72	select SPL_LOADER_SUPPORT if SPL
73	select SPL_OF_CONTROL if SPL_DM
74	select SPL_OF_PLATDATA if SPL_DM
75	select SPL_DM_SERIAL if SPL_DM
76	help
77	  This supports MediaTek MT7620.
78
79config SOC_MT7621
80	bool "MT7621"
81	select MIPS_CM
82	select MIPS_L2_CACHE
83	select SYS_CACHE_SHIFT_5
84	select SYS_MIPS_CACHE_INIT_RAM_LOAD
85	select PINCTRL_MT7621
86	select MTK_SERIAL
87	select REGMAP
88	select SYSCON
89	select BINMAN
90	select SUPPORT_TPL
91	select SPL_LOADER_SUPPORT if SPL
92	select SPL_INIT_STACK_WITHOUT_MALLOC_F if SPL
93	help
94	  This supports MediaTek MT7621.
95
96config SOC_MT7628
97	bool "MT7628"
98	select SYS_CACHE_SHIFT_5
99	select MIPS_INIT_STACK_IN_SRAM
100	select MIPS_SRAM_INIT
101	select SYS_MIPS_CACHE_INIT_RAM_LOAD
102	select PINCTRL_MT7628
103	select MTK_SERIAL
104	select SYSRESET
105	select SYSRESET_RESETCTL
106	select SPL_SEPARATE_BSS if SPL
107	select SPL_INIT_STACK_WITHOUT_MALLOC_F if SPL
108	select SPL_LOADER_SUPPORT if SPL
109	select SPL_OF_CONTROL if SPL_DM
110	select SPL_SIMPLE_BUS if SPL_DM
111	select SPL_DM_SERIAL if SPL_DM
112	select SPL_CLK if SPL_DM && SPL_SERIAL
113	select SPL_SYSRESET if SPL_DM
114	select SPL_OF_LIBFDT if SPL_OF_CONTROL
115	help
116	  This supports MediaTek MT7628/MT7688.
117
118endchoice
119
120source "arch/mips/mach-mtmips/mt7620/Kconfig"
121source "arch/mips/mach-mtmips/mt7621/Kconfig"
122source "arch/mips/mach-mtmips/mt7628/Kconfig"
123
124endmenu
125