diff options
Diffstat (limited to 'arch/arm/mach-orion5x/common.c')
-rw-r--r-- | arch/arm/mach-orion5x/common.c | 47 |
1 files changed, 42 insertions, 5 deletions
diff --git a/arch/arm/mach-orion5x/common.c b/arch/arm/mach-orion5x/common.c index 6af99ddabdfb..eafcc49009ea 100644 --- a/arch/arm/mach-orion5x/common.c +++ b/arch/arm/mach-orion5x/common.c | |||
@@ -31,7 +31,7 @@ | |||
31 | #include <plat/ehci-orion.h> | 31 | #include <plat/ehci-orion.h> |
32 | #include <plat/mv_xor.h> | 32 | #include <plat/mv_xor.h> |
33 | #include <plat/orion_nand.h> | 33 | #include <plat/orion_nand.h> |
34 | #include <plat/orion5x_wdt.h> | 34 | #include <plat/orion_wdt.h> |
35 | #include <plat/time.h> | 35 | #include <plat/time.h> |
36 | #include "common.h" | 36 | #include "common.h" |
37 | 37 | ||
@@ -188,6 +188,9 @@ static struct platform_device orion5x_eth = { | |||
188 | .id = 0, | 188 | .id = 0, |
189 | .num_resources = 1, | 189 | .num_resources = 1, |
190 | .resource = orion5x_eth_resources, | 190 | .resource = orion5x_eth_resources, |
191 | .dev = { | ||
192 | .coherent_dma_mask = 0xffffffff, | ||
193 | }, | ||
191 | }; | 194 | }; |
192 | 195 | ||
193 | void __init orion5x_eth_init(struct mv643xx_eth_platform_data *eth_data) | 196 | void __init orion5x_eth_init(struct mv643xx_eth_platform_data *eth_data) |
@@ -248,12 +251,10 @@ static struct mv64xxx_i2c_pdata orion5x_i2c_pdata = { | |||
248 | 251 | ||
249 | static struct resource orion5x_i2c_resources[] = { | 252 | static struct resource orion5x_i2c_resources[] = { |
250 | { | 253 | { |
251 | .name = "i2c base", | ||
252 | .start = I2C_PHYS_BASE, | 254 | .start = I2C_PHYS_BASE, |
253 | .end = I2C_PHYS_BASE + 0x1f, | 255 | .end = I2C_PHYS_BASE + 0x1f, |
254 | .flags = IORESOURCE_MEM, | 256 | .flags = IORESOURCE_MEM, |
255 | }, { | 257 | }, { |
256 | .name = "i2c irq", | ||
257 | .start = IRQ_ORION5X_I2C, | 258 | .start = IRQ_ORION5X_I2C, |
258 | .end = IRQ_ORION5X_I2C, | 259 | .end = IRQ_ORION5X_I2C, |
259 | .flags = IORESOURCE_IRQ, | 260 | .flags = IORESOURCE_IRQ, |
@@ -535,16 +536,52 @@ void __init orion5x_xor_init(void) | |||
535 | platform_device_register(&orion5x_xor1_channel); | 536 | platform_device_register(&orion5x_xor1_channel); |
536 | } | 537 | } |
537 | 538 | ||
539 | static struct resource orion5x_crypto_res[] = { | ||
540 | { | ||
541 | .name = "regs", | ||
542 | .start = ORION5X_CRYPTO_PHYS_BASE, | ||
543 | .end = ORION5X_CRYPTO_PHYS_BASE + 0xffff, | ||
544 | .flags = IORESOURCE_MEM, | ||
545 | }, { | ||
546 | .name = "sram", | ||
547 | .start = ORION5X_SRAM_PHYS_BASE, | ||
548 | .end = ORION5X_SRAM_PHYS_BASE + SZ_8K - 1, | ||
549 | .flags = IORESOURCE_MEM, | ||
550 | }, { | ||
551 | .name = "crypto interrupt", | ||
552 | .start = IRQ_ORION5X_CESA, | ||
553 | .end = IRQ_ORION5X_CESA, | ||
554 | .flags = IORESOURCE_IRQ, | ||
555 | }, | ||
556 | }; | ||
557 | |||
558 | static struct platform_device orion5x_crypto_device = { | ||
559 | .name = "mv_crypto", | ||
560 | .id = -1, | ||
561 | .num_resources = ARRAY_SIZE(orion5x_crypto_res), | ||
562 | .resource = orion5x_crypto_res, | ||
563 | }; | ||
564 | |||
565 | int __init orion5x_crypto_init(void) | ||
566 | { | ||
567 | int ret; | ||
568 | |||
569 | ret = orion5x_setup_sram_win(); | ||
570 | if (ret) | ||
571 | return ret; | ||
572 | |||
573 | return platform_device_register(&orion5x_crypto_device); | ||
574 | } | ||
538 | 575 | ||
539 | /***************************************************************************** | 576 | /***************************************************************************** |
540 | * Watchdog | 577 | * Watchdog |
541 | ****************************************************************************/ | 578 | ****************************************************************************/ |
542 | static struct orion5x_wdt_platform_data orion5x_wdt_data = { | 579 | static struct orion_wdt_platform_data orion5x_wdt_data = { |
543 | .tclk = 0, | 580 | .tclk = 0, |
544 | }; | 581 | }; |
545 | 582 | ||
546 | static struct platform_device orion5x_wdt_device = { | 583 | static struct platform_device orion5x_wdt_device = { |
547 | .name = "orion5x_wdt", | 584 | .name = "orion_wdt", |
548 | .id = -1, | 585 | .id = -1, |
549 | .dev = { | 586 | .dev = { |
550 | .platform_data = &orion5x_wdt_data, | 587 | .platform_data = &orion5x_wdt_data, |