aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/mach-davinci/board-dm646x-evm.c35
-rw-r--r--arch/arm/mach-davinci/dm646x.c8
-rw-r--r--arch/arm/mach-davinci/include/mach/dm646x.h1
3 files changed, 43 insertions, 1 deletions
diff --git a/arch/arm/mach-davinci/board-dm646x-evm.c b/arch/arm/mach-davinci/board-dm646x-evm.c
index 6d8889342c9f..b8b1deca95e0 100644
--- a/arch/arm/mach-davinci/board-dm646x-evm.c
+++ b/arch/arm/mach-davinci/board-dm646x-evm.c
@@ -721,6 +721,39 @@ static struct davinci_uart_config uart_config __initdata = {
721#define DM646X_EVM_PHY_MASK (0x2) 721#define DM646X_EVM_PHY_MASK (0x2)
722#define DM646X_EVM_MDIO_FREQUENCY (2200000) /* PHY bus frequency */ 722#define DM646X_EVM_MDIO_FREQUENCY (2200000) /* PHY bus frequency */
723 723
724/*
725 * The following EDMA channels/slots are not being used by drivers (for
726 * example: Timer, GPIO, UART events etc) on dm646x, hence they are being
727 * reserved for codecs on the DSP side.
728 */
729static const s16 dm646x_dma_rsv_chans[][2] = {
730 /* (offset, number) */
731 { 0, 4},
732 {13, 3},
733 {24, 4},
734 {30, 2},
735 {54, 3},
736 {-1, -1}
737};
738
739static const s16 dm646x_dma_rsv_slots[][2] = {
740 /* (offset, number) */
741 { 0, 4},
742 {13, 3},
743 {24, 4},
744 {30, 2},
745 {54, 3},
746 {128, 384},
747 {-1, -1}
748};
749
750static struct edma_rsv_info dm646x_edma_rsv[] = {
751 {
752 .rsv_chans = dm646x_dma_rsv_chans,
753 .rsv_slots = dm646x_dma_rsv_slots,
754 },
755};
756
724static __init void evm_init(void) 757static __init void evm_init(void)
725{ 758{
726 struct davinci_soc_info *soc_info = &davinci_soc_info; 759 struct davinci_soc_info *soc_info = &davinci_soc_info;
@@ -732,6 +765,8 @@ static __init void evm_init(void)
732 765
733 platform_device_register(&davinci_nand_device); 766 platform_device_register(&davinci_nand_device);
734 767
768 dm646x_init_edma(dm646x_edma_rsv);
769
735 if (HAS_ATA) 770 if (HAS_ATA)
736 davinci_init_ide(); 771 davinci_init_ide();
737 772
diff --git a/arch/arm/mach-davinci/dm646x.c b/arch/arm/mach-davinci/dm646x.c
index bfc887e9f118..e4a3df1872ac 100644
--- a/arch/arm/mach-davinci/dm646x.c
+++ b/arch/arm/mach-davinci/dm646x.c
@@ -879,6 +879,13 @@ void dm646x_setup_vpif(struct vpif_display_config *display_config,
879 platform_device_register(&vpif_capture_dev); 879 platform_device_register(&vpif_capture_dev);
880} 880}
881 881
882int __init dm646x_init_edma(struct edma_rsv_info *rsv)
883{
884 edma_cc0_info.rsv = rsv;
885
886 return platform_device_register(&dm646x_edma_device);
887}
888
882void __init dm646x_init(void) 889void __init dm646x_init(void)
883{ 890{
884 dm646x_board_setup_refclk(&ref_clk); 891 dm646x_board_setup_refclk(&ref_clk);
@@ -890,7 +897,6 @@ static int __init dm646x_init_devices(void)
890 if (!cpu_is_davinci_dm646x()) 897 if (!cpu_is_davinci_dm646x())
891 return 0; 898 return 0;
892 899
893 platform_device_register(&dm646x_edma_device);
894 platform_device_register(&dm646x_emac_device); 900 platform_device_register(&dm646x_emac_device);
895 return 0; 901 return 0;
896} 902}
diff --git a/arch/arm/mach-davinci/include/mach/dm646x.h b/arch/arm/mach-davinci/include/mach/dm646x.h
index add6f794a362..0a27ee9a70e1 100644
--- a/arch/arm/mach-davinci/include/mach/dm646x.h
+++ b/arch/arm/mach-davinci/include/mach/dm646x.h
@@ -32,6 +32,7 @@ void __init dm646x_init(void);
32void __init dm646x_init_mcasp0(struct snd_platform_data *pdata); 32void __init dm646x_init_mcasp0(struct snd_platform_data *pdata);
33void __init dm646x_init_mcasp1(struct snd_platform_data *pdata); 33void __init dm646x_init_mcasp1(struct snd_platform_data *pdata);
34void __init dm646x_board_setup_refclk(struct clk *clk); 34void __init dm646x_board_setup_refclk(struct clk *clk);
35int __init dm646x_init_edma(struct edma_rsv_info *rsv);
35 36
36void dm646x_video_init(void); 37void dm646x_video_init(void);
37 38