mediatek: Add support for Xiaomi Redmi Router AX6S
[openwrt/openwrt.git] / target / linux / bcm63xx / patches-5.4 / 031-v5.9-MIPS-BCM63xx-add-endif-comments.patch
1 From c425423a075718eac625c78351fa5907d4f3a9de Mon Sep 17 00:00:00 2001
2 From: =?UTF-8?q?=C3=81lvaro=20Fern=C3=A1ndez=20Rojas?= <noltari@gmail.com>
3 Date: Mon, 8 Jun 2020 12:18:28 +0200
4 Subject: [PATCH] MIPS: BCM63xx: add endif comments
5 MIME-Version: 1.0
6 Content-Type: text/plain; charset=UTF-8
7 Content-Transfer-Encoding: 8bit
8
9 There are plenty of ifdefs in board_bcm963xx.c without endif comments.
10 Let's make the code easier to follow by adding proper comments.
11
12 Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
13 Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
14 ---
15 arch/mips/bcm63xx/boards/board_bcm963xx.c | 33 +++++++++++------------
16 1 file changed, 15 insertions(+), 18 deletions(-)
17
18 --- a/arch/mips/bcm63xx/boards/board_bcm963xx.c
19 +++ b/arch/mips/bcm63xx/boards/board_bcm963xx.c
20 @@ -67,7 +67,7 @@ static struct board_info __initdata boar
21 .ephy_reset_gpio = 36,
22 .ephy_reset_gpio_flags = GPIOF_INIT_HIGH,
23 };
24 -#endif
25 +#endif /* CONFIG_BCM63XX_CPU_3368 */
26
27 /*
28 * known 6328 boards
29 @@ -115,7 +115,7 @@ static struct board_info __initdata boar
30 },
31 },
32 };
33 -#endif
34 +#endif /* CONFIG_BCM63XX_CPU_6328 */
35
36 /*
37 * known 6338 boards
38 @@ -204,7 +204,7 @@ static struct board_info __initdata boar
39 },
40 },
41 };
42 -#endif
43 +#endif /* CONFIG_BCM63XX_CPU_6338 */
44
45 /*
46 * known 6345 boards
47 @@ -216,7 +216,7 @@ static struct board_info __initdata boar
48
49 .has_uart0 = 1,
50 };
51 -#endif
52 +#endif /* CONFIG_BCM63XX_CPU_6345 */
53
54 /*
55 * known 6348 boards
56 @@ -464,7 +464,6 @@ static struct board_info __initdata boar
57 },
58 };
59
60 -
61 static struct board_info __initdata board_DV201AMR = {
62 .name = "DV201AMR",
63 .expected_cpu_id = 0x6348,
64 @@ -505,7 +504,7 @@ static struct board_info __initdata boar
65
66 .has_ohci0 = 1,
67 };
68 -#endif
69 +#endif /* CONFIG_BCM63XX_CPU_6348 */
70
71 /*
72 * known 6358 boards
73 @@ -530,7 +529,6 @@ static struct board_info __initdata boar
74 .force_duplex_full = 1,
75 },
76
77 -
78 .has_ohci0 = 1,
79 .has_pccard = 1,
80 .has_ehci0 = 1,
81 @@ -654,7 +652,7 @@ static struct board_info __initdata boar
82
83 .has_ohci0 = 1,
84 };
85 -#endif
86 +#endif /* CONFIG_BCM63XX_CPU_6358 */
87
88 /*
89 * all boards
90 @@ -662,17 +660,17 @@ static struct board_info __initdata boar
91 static const struct board_info __initconst *bcm963xx_boards[] = {
92 #ifdef CONFIG_BCM63XX_CPU_3368
93 &board_cvg834g,
94 -#endif
95 +#endif /* CONFIG_BCM63XX_CPU_3368 */
96 #ifdef CONFIG_BCM63XX_CPU_6328
97 &board_96328avng,
98 -#endif
99 +#endif /* CONFIG_BCM63XX_CPU_6328 */
100 #ifdef CONFIG_BCM63XX_CPU_6338
101 &board_96338gw,
102 &board_96338w,
103 -#endif
104 +#endif /* CONFIG_BCM63XX_CPU_6338 */
105 #ifdef CONFIG_BCM63XX_CPU_6345
106 &board_96345gw2,
107 -#endif
108 +#endif /* CONFIG_BCM63XX_CPU_6345 */
109 #ifdef CONFIG_BCM63XX_CPU_6348
110 &board_96348r,
111 &board_96348gw,
112 @@ -682,14 +680,13 @@ static const struct board_info __initcon
113 &board_DV201AMR,
114 &board_96348gw_a,
115 &board_rta1025w_16,
116 -#endif
117 -
118 +#endif /* CONFIG_BCM63XX_CPU_6348 */
119 #ifdef CONFIG_BCM63XX_CPU_6358
120 &board_96358vw,
121 &board_96358vw2,
122 &board_AGPFS0,
123 &board_DWVS0,
124 -#endif
125 +#endif /* CONFIG_BCM63XX_CPU_6358 */
126 };
127
128 /*
129 @@ -728,7 +725,7 @@ int bcm63xx_get_fallback_sprom(struct ss
130 return -EINVAL;
131 }
132 }
133 -#endif
134 +#endif /* CONFIG_SSB_PCIHOST */
135
136 /*
137 * return board name for /proc/cpuinfo
138 @@ -807,7 +804,7 @@ void __init board_prom_init(void)
139 if (BCMCPU_IS_6348())
140 val |= GPIO_MODE_6348_G2_PCI;
141 }
142 -#endif
143 +#endif /* CONFIG_PCI */
144
145 if (board.has_pccard) {
146 if (BCMCPU_IS_6348())
147 @@ -892,7 +889,7 @@ int __init board_register_devices(void)
148 &bcm63xx_get_fallback_sprom) < 0)
149 pr_err("failed to register fallback SPROM\n");
150 }
151 -#endif
152 +#endif /* CONFIG_SSB_PCIHOST */
153
154 bcm63xx_spi_register();
155