diff options
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-dove/common.c | 3 | ||||
-rw-r--r-- | arch/arm/mach-kirkwood/common.c | 12 | ||||
-rw-r--r-- | arch/arm/mach-mv78xx0/common.c | 8 | ||||
-rw-r--r-- | arch/arm/mach-orion5x/common.c | 2 | ||||
-rw-r--r-- | arch/arm/plat-orion/common.c | 26 | ||||
-rw-r--r-- | arch/arm/plat-orion/include/plat/common.h | 13 |
6 files changed, 30 insertions, 34 deletions
diff --git a/arch/arm/mach-dove/common.c b/arch/arm/mach-dove/common.c index da5b4047464d..02766960480d 100644 --- a/arch/arm/mach-dove/common.c +++ b/arch/arm/mach-dove/common.c | |||
@@ -102,8 +102,7 @@ void __init dove_ehci1_init(void) | |||
102 | void __init dove_ge00_init(struct mv643xx_eth_platform_data *eth_data) | 102 | void __init dove_ge00_init(struct mv643xx_eth_platform_data *eth_data) |
103 | { | 103 | { |
104 | orion_ge00_init(eth_data, | 104 | orion_ge00_init(eth_data, |
105 | DOVE_GE00_PHYS_BASE, IRQ_DOVE_GE00_SUM, | 105 | DOVE_GE00_PHYS_BASE, IRQ_DOVE_GE00_SUM, 0); |
106 | 0, get_tclk()); | ||
107 | } | 106 | } |
108 | 107 | ||
109 | /***************************************************************************** | 108 | /***************************************************************************** |
diff --git a/arch/arm/mach-kirkwood/common.c b/arch/arm/mach-kirkwood/common.c index 476e0b941db7..c22354405297 100644 --- a/arch/arm/mach-kirkwood/common.c +++ b/arch/arm/mach-kirkwood/common.c | |||
@@ -86,14 +86,14 @@ static struct clk __init *kirkwood_register_gate(const char *name, u8 bit_idx) | |||
86 | 86 | ||
87 | void __init kirkwood_clk_init(void) | 87 | void __init kirkwood_clk_init(void) |
88 | { | 88 | { |
89 | struct clk *runit; | 89 | struct clk *runit, *ge0, *ge1; |
90 | 90 | ||
91 | tclk = clk_register_fixed_rate(NULL, "tclk", NULL, | 91 | tclk = clk_register_fixed_rate(NULL, "tclk", NULL, |
92 | CLK_IS_ROOT, kirkwood_tclk); | 92 | CLK_IS_ROOT, kirkwood_tclk); |
93 | 93 | ||
94 | runit = kirkwood_register_gate("runit", CGC_BIT_RUNIT); | 94 | runit = kirkwood_register_gate("runit", CGC_BIT_RUNIT); |
95 | kirkwood_register_gate("ge0", CGC_BIT_GE0); | 95 | ge0 = kirkwood_register_gate("ge0", CGC_BIT_GE0); |
96 | kirkwood_register_gate("ge1", CGC_BIT_GE1); | 96 | ge1 = kirkwood_register_gate("ge1", CGC_BIT_GE1); |
97 | kirkwood_register_gate("sata0", CGC_BIT_SATA0); | 97 | kirkwood_register_gate("sata0", CGC_BIT_SATA0); |
98 | kirkwood_register_gate("sata1", CGC_BIT_SATA1); | 98 | kirkwood_register_gate("sata1", CGC_BIT_SATA1); |
99 | kirkwood_register_gate("usb0", CGC_BIT_USB0); | 99 | kirkwood_register_gate("usb0", CGC_BIT_USB0); |
@@ -110,6 +110,8 @@ void __init kirkwood_clk_init(void) | |||
110 | /* clkdev entries, mapping clks to devices */ | 110 | /* clkdev entries, mapping clks to devices */ |
111 | orion_clkdev_add(NULL, "orion_spi.0", runit); | 111 | orion_clkdev_add(NULL, "orion_spi.0", runit); |
112 | orion_clkdev_add(NULL, "orion_spi.1", runit); | 112 | orion_clkdev_add(NULL, "orion_spi.1", runit); |
113 | orion_clkdev_add(NULL, MV643XX_ETH_NAME ".0", ge0); | ||
114 | orion_clkdev_add(NULL, MV643XX_ETH_NAME ".1", ge1); | ||
113 | } | 115 | } |
114 | 116 | ||
115 | /***************************************************************************** | 117 | /***************************************************************************** |
@@ -131,7 +133,7 @@ void __init kirkwood_ge00_init(struct mv643xx_eth_platform_data *eth_data) | |||
131 | 133 | ||
132 | orion_ge00_init(eth_data, | 134 | orion_ge00_init(eth_data, |
133 | GE00_PHYS_BASE, IRQ_KIRKWOOD_GE00_SUM, | 135 | GE00_PHYS_BASE, IRQ_KIRKWOOD_GE00_SUM, |
134 | IRQ_KIRKWOOD_GE00_ERR, kirkwood_tclk); | 136 | IRQ_KIRKWOOD_GE00_ERR); |
135 | } | 137 | } |
136 | 138 | ||
137 | 139 | ||
@@ -145,7 +147,7 @@ void __init kirkwood_ge01_init(struct mv643xx_eth_platform_data *eth_data) | |||
145 | 147 | ||
146 | orion_ge01_init(eth_data, | 148 | orion_ge01_init(eth_data, |
147 | GE01_PHYS_BASE, IRQ_KIRKWOOD_GE01_SUM, | 149 | GE01_PHYS_BASE, IRQ_KIRKWOOD_GE01_SUM, |
148 | IRQ_KIRKWOOD_GE01_ERR, kirkwood_tclk); | 150 | IRQ_KIRKWOOD_GE01_ERR); |
149 | } | 151 | } |
150 | 152 | ||
151 | 153 | ||
diff --git a/arch/arm/mach-mv78xx0/common.c b/arch/arm/mach-mv78xx0/common.c index 4c24b46520aa..ad4d037bbcd3 100644 --- a/arch/arm/mach-mv78xx0/common.c +++ b/arch/arm/mach-mv78xx0/common.c | |||
@@ -213,7 +213,7 @@ void __init mv78xx0_ge00_init(struct mv643xx_eth_platform_data *eth_data) | |||
213 | { | 213 | { |
214 | orion_ge00_init(eth_data, | 214 | orion_ge00_init(eth_data, |
215 | GE00_PHYS_BASE, IRQ_MV78XX0_GE00_SUM, | 215 | GE00_PHYS_BASE, IRQ_MV78XX0_GE00_SUM, |
216 | IRQ_MV78XX0_GE_ERR, get_tclk()); | 216 | IRQ_MV78XX0_GE_ERR); |
217 | } | 217 | } |
218 | 218 | ||
219 | 219 | ||
@@ -224,7 +224,7 @@ void __init mv78xx0_ge01_init(struct mv643xx_eth_platform_data *eth_data) | |||
224 | { | 224 | { |
225 | orion_ge01_init(eth_data, | 225 | orion_ge01_init(eth_data, |
226 | GE01_PHYS_BASE, IRQ_MV78XX0_GE01_SUM, | 226 | GE01_PHYS_BASE, IRQ_MV78XX0_GE01_SUM, |
227 | NO_IRQ, get_tclk()); | 227 | NO_IRQ); |
228 | } | 228 | } |
229 | 229 | ||
230 | 230 | ||
@@ -248,7 +248,7 @@ void __init mv78xx0_ge10_init(struct mv643xx_eth_platform_data *eth_data) | |||
248 | 248 | ||
249 | orion_ge10_init(eth_data, | 249 | orion_ge10_init(eth_data, |
250 | GE10_PHYS_BASE, IRQ_MV78XX0_GE10_SUM, | 250 | GE10_PHYS_BASE, IRQ_MV78XX0_GE10_SUM, |
251 | NO_IRQ, get_tclk()); | 251 | NO_IRQ); |
252 | } | 252 | } |
253 | 253 | ||
254 | 254 | ||
@@ -272,7 +272,7 @@ void __init mv78xx0_ge11_init(struct mv643xx_eth_platform_data *eth_data) | |||
272 | 272 | ||
273 | orion_ge11_init(eth_data, | 273 | orion_ge11_init(eth_data, |
274 | GE11_PHYS_BASE, IRQ_MV78XX0_GE11_SUM, | 274 | GE11_PHYS_BASE, IRQ_MV78XX0_GE11_SUM, |
275 | NO_IRQ, get_tclk()); | 275 | NO_IRQ); |
276 | } | 276 | } |
277 | 277 | ||
278 | /***************************************************************************** | 278 | /***************************************************************************** |
diff --git a/arch/arm/mach-orion5x/common.c b/arch/arm/mach-orion5x/common.c index 2ef82e2f511d..3fc731824e9c 100644 --- a/arch/arm/mach-orion5x/common.c +++ b/arch/arm/mach-orion5x/common.c | |||
@@ -109,7 +109,7 @@ void __init orion5x_eth_init(struct mv643xx_eth_platform_data *eth_data) | |||
109 | { | 109 | { |
110 | orion_ge00_init(eth_data, | 110 | orion_ge00_init(eth_data, |
111 | ORION5X_ETH_PHYS_BASE, IRQ_ORION5X_ETH_SUM, | 111 | ORION5X_ETH_PHYS_BASE, IRQ_ORION5X_ETH_SUM, |
112 | IRQ_ORION5X_ETH_ERR, orion5x_tclk); | 112 | IRQ_ORION5X_ETH_ERR); |
113 | } | 113 | } |
114 | 114 | ||
115 | 115 | ||
diff --git a/arch/arm/plat-orion/common.c b/arch/arm/plat-orion/common.c index bbe50a948710..a33733bb380d 100644 --- a/arch/arm/plat-orion/common.c +++ b/arch/arm/plat-orion/common.c | |||
@@ -43,6 +43,10 @@ void __init orion_clkdev_init(struct clk *tclk) | |||
43 | { | 43 | { |
44 | orion_clkdev_add(NULL, "orion_spi.0", tclk); | 44 | orion_clkdev_add(NULL, "orion_spi.0", tclk); |
45 | orion_clkdev_add(NULL, "orion_spi.1", tclk); | 45 | orion_clkdev_add(NULL, "orion_spi.1", tclk); |
46 | orion_clkdev_add(NULL, MV643XX_ETH_NAME ".0", tclk); | ||
47 | orion_clkdev_add(NULL, MV643XX_ETH_NAME ".1", tclk); | ||
48 | orion_clkdev_add(NULL, MV643XX_ETH_NAME ".2", tclk); | ||
49 | orion_clkdev_add(NULL, MV643XX_ETH_NAME ".3", tclk); | ||
46 | } | 50 | } |
47 | 51 | ||
48 | /* Fill in the resources structure and link it into the platform | 52 | /* Fill in the resources structure and link it into the platform |
@@ -225,13 +229,11 @@ void __init orion_rtc_init(unsigned long mapbase, | |||
225 | ****************************************************************************/ | 229 | ****************************************************************************/ |
226 | static __init void ge_complete( | 230 | static __init void ge_complete( |
227 | struct mv643xx_eth_shared_platform_data *orion_ge_shared_data, | 231 | struct mv643xx_eth_shared_platform_data *orion_ge_shared_data, |
228 | int tclk, | ||
229 | struct resource *orion_ge_resource, unsigned long irq, | 232 | struct resource *orion_ge_resource, unsigned long irq, |
230 | struct platform_device *orion_ge_shared, | 233 | struct platform_device *orion_ge_shared, |
231 | struct mv643xx_eth_platform_data *eth_data, | 234 | struct mv643xx_eth_platform_data *eth_data, |
232 | struct platform_device *orion_ge) | 235 | struct platform_device *orion_ge) |
233 | { | 236 | { |
234 | orion_ge_shared_data->t_clk = tclk; | ||
235 | orion_ge_resource->start = irq; | 237 | orion_ge_resource->start = irq; |
236 | orion_ge_resource->end = irq; | 238 | orion_ge_resource->end = irq; |
237 | eth_data->shared = orion_ge_shared; | 239 | eth_data->shared = orion_ge_shared; |
@@ -282,12 +284,11 @@ static struct platform_device orion_ge00 = { | |||
282 | void __init orion_ge00_init(struct mv643xx_eth_platform_data *eth_data, | 284 | void __init orion_ge00_init(struct mv643xx_eth_platform_data *eth_data, |
283 | unsigned long mapbase, | 285 | unsigned long mapbase, |
284 | unsigned long irq, | 286 | unsigned long irq, |
285 | unsigned long irq_err, | 287 | unsigned long irq_err) |
286 | int tclk) | ||
287 | { | 288 | { |
288 | fill_resources(&orion_ge00_shared, orion_ge00_shared_resources, | 289 | fill_resources(&orion_ge00_shared, orion_ge00_shared_resources, |
289 | mapbase + 0x2000, SZ_16K - 1, irq_err); | 290 | mapbase + 0x2000, SZ_16K - 1, irq_err); |
290 | ge_complete(&orion_ge00_shared_data, tclk, | 291 | ge_complete(&orion_ge00_shared_data, |
291 | orion_ge00_resources, irq, &orion_ge00_shared, | 292 | orion_ge00_resources, irq, &orion_ge00_shared, |
292 | eth_data, &orion_ge00); | 293 | eth_data, &orion_ge00); |
293 | } | 294 | } |
@@ -335,12 +336,11 @@ static struct platform_device orion_ge01 = { | |||
335 | void __init orion_ge01_init(struct mv643xx_eth_platform_data *eth_data, | 336 | void __init orion_ge01_init(struct mv643xx_eth_platform_data *eth_data, |
336 | unsigned long mapbase, | 337 | unsigned long mapbase, |
337 | unsigned long irq, | 338 | unsigned long irq, |
338 | unsigned long irq_err, | 339 | unsigned long irq_err) |
339 | int tclk) | ||
340 | { | 340 | { |
341 | fill_resources(&orion_ge01_shared, orion_ge01_shared_resources, | 341 | fill_resources(&orion_ge01_shared, orion_ge01_shared_resources, |
342 | mapbase + 0x2000, SZ_16K - 1, irq_err); | 342 | mapbase + 0x2000, SZ_16K - 1, irq_err); |
343 | ge_complete(&orion_ge01_shared_data, tclk, | 343 | ge_complete(&orion_ge01_shared_data, |
344 | orion_ge01_resources, irq, &orion_ge01_shared, | 344 | orion_ge01_resources, irq, &orion_ge01_shared, |
345 | eth_data, &orion_ge01); | 345 | eth_data, &orion_ge01); |
346 | } | 346 | } |
@@ -388,12 +388,11 @@ static struct platform_device orion_ge10 = { | |||
388 | void __init orion_ge10_init(struct mv643xx_eth_platform_data *eth_data, | 388 | void __init orion_ge10_init(struct mv643xx_eth_platform_data *eth_data, |
389 | unsigned long mapbase, | 389 | unsigned long mapbase, |
390 | unsigned long irq, | 390 | unsigned long irq, |
391 | unsigned long irq_err, | 391 | unsigned long irq_err) |
392 | int tclk) | ||
393 | { | 392 | { |
394 | fill_resources(&orion_ge10_shared, orion_ge10_shared_resources, | 393 | fill_resources(&orion_ge10_shared, orion_ge10_shared_resources, |
395 | mapbase + 0x2000, SZ_16K - 1, irq_err); | 394 | mapbase + 0x2000, SZ_16K - 1, irq_err); |
396 | ge_complete(&orion_ge10_shared_data, tclk, | 395 | ge_complete(&orion_ge10_shared_data, |
397 | orion_ge10_resources, irq, &orion_ge10_shared, | 396 | orion_ge10_resources, irq, &orion_ge10_shared, |
398 | eth_data, &orion_ge10); | 397 | eth_data, &orion_ge10); |
399 | } | 398 | } |
@@ -441,12 +440,11 @@ static struct platform_device orion_ge11 = { | |||
441 | void __init orion_ge11_init(struct mv643xx_eth_platform_data *eth_data, | 440 | void __init orion_ge11_init(struct mv643xx_eth_platform_data *eth_data, |
442 | unsigned long mapbase, | 441 | unsigned long mapbase, |
443 | unsigned long irq, | 442 | unsigned long irq, |
444 | unsigned long irq_err, | 443 | unsigned long irq_err) |
445 | int tclk) | ||
446 | { | 444 | { |
447 | fill_resources(&orion_ge11_shared, orion_ge11_shared_resources, | 445 | fill_resources(&orion_ge11_shared, orion_ge11_shared_resources, |
448 | mapbase + 0x2000, SZ_16K - 1, irq_err); | 446 | mapbase + 0x2000, SZ_16K - 1, irq_err); |
449 | ge_complete(&orion_ge11_shared_data, tclk, | 447 | ge_complete(&orion_ge11_shared_data, |
450 | orion_ge11_resources, irq, &orion_ge11_shared, | 448 | orion_ge11_resources, irq, &orion_ge11_shared, |
451 | eth_data, &orion_ge11); | 449 | eth_data, &orion_ge11); |
452 | } | 450 | } |
diff --git a/arch/arm/plat-orion/include/plat/common.h b/arch/arm/plat-orion/include/plat/common.h index d188a1aa6f56..00d8761c7d28 100644 --- a/arch/arm/plat-orion/include/plat/common.h +++ b/arch/arm/plat-orion/include/plat/common.h | |||
@@ -39,29 +39,26 @@ void __init orion_rtc_init(unsigned long mapbase, | |||
39 | void __init orion_ge00_init(struct mv643xx_eth_platform_data *eth_data, | 39 | void __init orion_ge00_init(struct mv643xx_eth_platform_data *eth_data, |
40 | unsigned long mapbase, | 40 | unsigned long mapbase, |
41 | unsigned long irq, | 41 | unsigned long irq, |
42 | unsigned long irq_err, | 42 | unsigned long irq_err); |
43 | int tclk); | ||
44 | 43 | ||
45 | void __init orion_ge01_init(struct mv643xx_eth_platform_data *eth_data, | 44 | void __init orion_ge01_init(struct mv643xx_eth_platform_data *eth_data, |
46 | unsigned long mapbase, | 45 | unsigned long mapbase, |
47 | unsigned long irq, | 46 | unsigned long irq, |
48 | unsigned long irq_err, | 47 | unsigned long irq_err); |
49 | int tclk); | ||
50 | 48 | ||
51 | void __init orion_ge10_init(struct mv643xx_eth_platform_data *eth_data, | 49 | void __init orion_ge10_init(struct mv643xx_eth_platform_data *eth_data, |
52 | unsigned long mapbase, | 50 | unsigned long mapbase, |
53 | unsigned long irq, | 51 | unsigned long irq, |
54 | unsigned long irq_err, | 52 | unsigned long irq_err); |
55 | int tclk); | ||
56 | 53 | ||
57 | void __init orion_ge11_init(struct mv643xx_eth_platform_data *eth_data, | 54 | void __init orion_ge11_init(struct mv643xx_eth_platform_data *eth_data, |
58 | unsigned long mapbase, | 55 | unsigned long mapbase, |
59 | unsigned long irq, | 56 | unsigned long irq, |
60 | unsigned long irq_err, | 57 | unsigned long irq_err); |
61 | int tclk); | ||
62 | 58 | ||
63 | void __init orion_ge00_switch_init(struct dsa_platform_data *d, | 59 | void __init orion_ge00_switch_init(struct dsa_platform_data *d, |
64 | int irq); | 60 | int irq); |
61 | |||
65 | void __init orion_i2c_init(unsigned long mapbase, | 62 | void __init orion_i2c_init(unsigned long mapbase, |
66 | unsigned long irq, | 63 | unsigned long irq, |
67 | unsigned long freq_m); | 64 | unsigned long freq_m); |