aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-ux500/cpu-db8500.c
diff options
context:
space:
mode:
authorOlof Johansson <olof@lixom.net>2013-05-27 23:09:53 -0400
committerOlof Johansson <olof@lixom.net>2013-05-27 23:10:04 -0400
commit6f39ef575df368ed77fcaa2f1d0f28191c7414fc (patch)
treee64a261770acf65a32e498f5b8f1f8323e14fbb7 /arch/arm/mach-ux500/cpu-db8500.c
parente4aa937ec75df0eea0bee03bffa3303ad36c986b (diff)
parent95e4bf98520c9a92cd1b87d12c89e8c60c5fe2ca (diff)
Merge tag 'ux500-dma40-for-arm-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson into next/drivers
From Linus Walleij: This is a set of patches from Lee Jones to start converting the ux500 to fetch DMA channels from the device tree: - Full DT support and channel mapping in the DMA40 driver - Dropping of platform data for migrated devices on the DT boot path. * tag 'ux500-dma40-for-arm-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/linusw/linux-stericsson: (36 commits) ARM: ux500: Register Cryp and Hash platform drivers on Snowball crypto: ux500/[cryp|hash] - Show successful start-up in the bootlog ARM: ux500: Stop passing Cryp DMA channel config information though pdata crypto: ux500/cryp - Set DMA configuration though dma_slave_config() crypto: ux500/cryp - Prepare clock before enabling it ARM: ux500: Stop passing Hash DMA channel config information though pdata crypto: ux500/hash - Set DMA configuration though dma_slave_config() crypto: ux500/hash - Prepare clock before enabling it ARM: ux500: Remove unnecessary attributes from DMA channel request pdata dmaengine: ste_dma40: Correct copy/paste error ARM: ux500: Remove DMA address look-up table dmaengine: ste_dma40: Remove redundant address fetching function dmaengine: ste_dma40: Only use addresses passed as configuration information ARM: ux500: Stop passing UART's platform data for Device Tree boots dmaengine: ste_dma40: Don't configure runtime configurable setup during allocate dmaengine: ste_dma40: Remove unnecessary call to d40_phy_cfg() dmaengine: ste_dma40: Separate Logical Global Interrupt Mask (GIM) unmasking ARM: ux500: Pass remnant platform data though to DMA40 driver dmaengine: ste_dma40: Supply full Device Tree parsing support dmaengine: ste_dma40: Allow driver to be probe()able when DT is enabled ... Signed-off-by: Olof Johansson <olof@lixom.net>
Diffstat (limited to 'arch/arm/mach-ux500/cpu-db8500.c')
-rw-r--r--arch/arm/mach-ux500/cpu-db8500.c52
1 files changed, 17 insertions, 35 deletions
diff --git a/arch/arm/mach-ux500/cpu-db8500.c b/arch/arm/mach-ux500/cpu-db8500.c
index 46cca52890bc..243b91b66ae0 100644
--- a/arch/arm/mach-ux500/cpu-db8500.c
+++ b/arch/arm/mach-ux500/cpu-db8500.c
@@ -162,26 +162,15 @@ static void __init db8500_add_gpios(struct device *parent)
162 dbx500_add_pinctrl(parent, "pinctrl-db8500", U8500_PRCMU_BASE); 162 dbx500_add_pinctrl(parent, "pinctrl-db8500", U8500_PRCMU_BASE);
163} 163}
164 164
165static int usb_db8500_rx_dma_cfg[] = { 165static int usb_db8500_dma_cfg[] = {
166 DB8500_DMA_DEV38_USB_OTG_IEP_1_9, 166 DB8500_DMA_DEV38_USB_OTG_IEP_AND_OEP_1_9,
167 DB8500_DMA_DEV37_USB_OTG_IEP_2_10, 167 DB8500_DMA_DEV37_USB_OTG_IEP_AND_OEP_2_10,
168 DB8500_DMA_DEV36_USB_OTG_IEP_3_11, 168 DB8500_DMA_DEV36_USB_OTG_IEP_AND_OEP_3_11,
169 DB8500_DMA_DEV19_USB_OTG_IEP_4_12, 169 DB8500_DMA_DEV19_USB_OTG_IEP_AND_OEP_4_12,
170 DB8500_DMA_DEV18_USB_OTG_IEP_5_13, 170 DB8500_DMA_DEV18_USB_OTG_IEP_AND_OEP_5_13,
171 DB8500_DMA_DEV17_USB_OTG_IEP_6_14, 171 DB8500_DMA_DEV17_USB_OTG_IEP_AND_OEP_6_14,
172 DB8500_DMA_DEV16_USB_OTG_IEP_7_15, 172 DB8500_DMA_DEV16_USB_OTG_IEP_AND_OEP_7_15,
173 DB8500_DMA_DEV39_USB_OTG_IEP_8 173 DB8500_DMA_DEV39_USB_OTG_IEP_AND_OEP_8
174};
175
176static int usb_db8500_tx_dma_cfg[] = {
177 DB8500_DMA_DEV38_USB_OTG_OEP_1_9,
178 DB8500_DMA_DEV37_USB_OTG_OEP_2_10,
179 DB8500_DMA_DEV36_USB_OTG_OEP_3_11,
180 DB8500_DMA_DEV19_USB_OTG_OEP_4_12,
181 DB8500_DMA_DEV18_USB_OTG_OEP_5_13,
182 DB8500_DMA_DEV17_USB_OTG_OEP_6_14,
183 DB8500_DMA_DEV16_USB_OTG_OEP_7_15,
184 DB8500_DMA_DEV39_USB_OTG_OEP_8
185}; 174};
186 175
187static const char *db8500_read_soc_id(void) 176static const char *db8500_read_soc_id(void)
@@ -215,7 +204,7 @@ struct device * __init u8500_init_devices(void)
215 204
216 db8500_add_rtc(parent); 205 db8500_add_rtc(parent);
217 db8500_add_gpios(parent); 206 db8500_add_gpios(parent);
218 db8500_add_usb(parent, usb_db8500_rx_dma_cfg, usb_db8500_tx_dma_cfg); 207 db8500_add_usb(parent, usb_db8500_dma_cfg, usb_db8500_dma_cfg);
219 208
220 for (i = 0; i < ARRAY_SIZE(platform_devs); i++) 209 for (i = 0; i < ARRAY_SIZE(platform_devs); i++)
221 platform_devs[i]->dev.parent = parent; 210 platform_devs[i]->dev.parent = parent;
@@ -232,17 +221,7 @@ static struct device * __init u8500_of_init_devices(void)
232{ 221{
233 struct device *parent = db8500_soc_device_init(); 222 struct device *parent = db8500_soc_device_init();
234 223
235 db8500_add_usb(parent, usb_db8500_rx_dma_cfg, usb_db8500_tx_dma_cfg); 224 db8500_add_usb(parent, usb_db8500_dma_cfg, usb_db8500_dma_cfg);
236
237 u8500_dma40_device.dev.parent = parent;
238
239 /*
240 * Devices to be DT:ed:
241 * u8500_dma40_device = todo
242 * db8500_pmu_device = done
243 * db8500_prcmu_device = done
244 */
245 platform_device_register(&u8500_dma40_device);
246 225
247 return parent; 226 return parent;
248} 227}
@@ -251,9 +230,9 @@ static struct of_dev_auxdata u8500_auxdata_lookup[] __initdata = {
251 /* Requires call-back bindings. */ 230 /* Requires call-back bindings. */
252 OF_DEV_AUXDATA("arm,cortex-a9-pmu", 0, "arm-pmu", &db8500_pmu_platdata), 231 OF_DEV_AUXDATA("arm,cortex-a9-pmu", 0, "arm-pmu", &db8500_pmu_platdata),
253 /* Requires DMA bindings. */ 232 /* Requires DMA bindings. */
254 OF_DEV_AUXDATA("arm,pl011", 0x80120000, "uart0", &uart0_plat), 233 OF_DEV_AUXDATA("arm,pl011", 0x80120000, "uart0", NULL),
255 OF_DEV_AUXDATA("arm,pl011", 0x80121000, "uart1", &uart1_plat), 234 OF_DEV_AUXDATA("arm,pl011", 0x80121000, "uart1", NULL),
256 OF_DEV_AUXDATA("arm,pl011", 0x80007000, "uart2", &uart2_plat), 235 OF_DEV_AUXDATA("arm,pl011", 0x80007000, "uart2", NULL),
257 OF_DEV_AUXDATA("arm,pl022", 0x80002000, "ssp0", &ssp0_plat), 236 OF_DEV_AUXDATA("arm,pl022", 0x80002000, "ssp0", &ssp0_plat),
258 OF_DEV_AUXDATA("arm,pl18x", 0x80126000, "sdi0", &mop500_sdi0_data), 237 OF_DEV_AUXDATA("arm,pl18x", 0x80126000, "sdi0", &mop500_sdi0_data),
259 OF_DEV_AUXDATA("arm,pl18x", 0x80118000, "sdi1", &mop500_sdi1_data), 238 OF_DEV_AUXDATA("arm,pl18x", 0x80118000, "sdi1", &mop500_sdi1_data),
@@ -289,6 +268,9 @@ static struct of_dev_auxdata u8500_auxdata_lookup[] __initdata = {
289 "ux500-msp-i2s.2", &msp2_platform_data), 268 "ux500-msp-i2s.2", &msp2_platform_data),
290 OF_DEV_AUXDATA("stericsson,ux500-msp-i2s", 0x80125000, 269 OF_DEV_AUXDATA("stericsson,ux500-msp-i2s", 0x80125000,
291 "ux500-msp-i2s.3", &msp3_platform_data), 270 "ux500-msp-i2s.3", &msp3_platform_data),
271 /* Requires clock name bindings and channel address lookup table. */
272 OF_DEV_AUXDATA("stericsson,db8500-dma40", 0x801C0000,
273 "dma40.0", &dma40_plat_data),
292 {}, 274 {},
293}; 275};
294 276