From be1f94812c2cc0aaf696d39fe23104763ea52b5b Mon Sep 17 00:00:00 2001 From: Tony Lindgren Date: Fri, 11 Jan 2013 11:24:19 -0800 Subject: ARM: OMAP: Fix dmaengine init for multiplatform Otherwise omap dmaengine will initialized when booted on other SoCs. Fix this by initializing the platform device in arch/arm/*omap*/dma.c instead. Cc: Russell King Cc: Dan Williams Cc: Vinod Koul Tested-by: Ezequiel Garcia Signed-off-by: Tony Lindgren --- drivers/dma/omap-dma.c | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) (limited to 'drivers') diff --git a/drivers/dma/omap-dma.c b/drivers/dma/omap-dma.c index 5a31264f2bd1..c4b4fd2acc42 100644 --- a/drivers/dma/omap-dma.c +++ b/drivers/dma/omap-dma.c @@ -661,32 +661,14 @@ bool omap_dma_filter_fn(struct dma_chan *chan, void *param) } EXPORT_SYMBOL_GPL(omap_dma_filter_fn); -static struct platform_device *pdev; - -static const struct platform_device_info omap_dma_dev_info = { - .name = "omap-dma-engine", - .id = -1, - .dma_mask = DMA_BIT_MASK(32), -}; - static int omap_dma_init(void) { - int rc = platform_driver_register(&omap_dma_driver); - - if (rc == 0) { - pdev = platform_device_register_full(&omap_dma_dev_info); - if (IS_ERR(pdev)) { - platform_driver_unregister(&omap_dma_driver); - rc = PTR_ERR(pdev); - } - } - return rc; + return platform_driver_register(&omap_dma_driver); } subsys_initcall(omap_dma_init); static void __exit omap_dma_exit(void) { - platform_device_unregister(pdev); platform_driver_unregister(&omap_dma_driver); } module_exit(omap_dma_exit); -- cgit v1.2.3 From a62a6e98c370ccca37d353a5f763b532411a4c14 Mon Sep 17 00:00:00 2001 From: Tony Lindgren Date: Fri, 11 Jan 2013 11:24:20 -0800 Subject: ARM: OMAP2+: Disable code that currently does not work with multiplaform MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We still need to fix up few places for multiplatform support, but that can proceed separately. Fix the issue by making the problem drivers depends !ARCH_MULTIPLATFORM for now. The remaining pieces that are not multiplatform compatible for omap2+ SoCs are: 1. Some drivers are using custom omap_dm_timer calls There are two drivers that are directly usign omap hardware timers for PWM and DSP clocking: drivers/media/rc/ir-rx51.c and drivers/staging/tidspbridge/core/dsp-clock.c. These can be fixed for multiplatform by allowing a minimal set of hardware timers to be accessed, and for some functionality by using the hrtimer framework. 2. Hardware OMAP4_ERRATA_I688 needs to be fixed up This can't be enabled for multiplatform configurations in it's current form. It may be possible to fix it up to do instruction replacement early on during init. Luckily it looks like this errata does not seem to get hit with mainline kernel code alone at least currently. 3. Legacy header needed for omap-sham.c Looks like it still needs mach/irqs.h for omap1 that does not exist for multiplatform systems. Just ifdef it for now. 4. Mailbox is waiting to get moved to drivers Disable it for now to avoid adding a dependency to the mailbox patches. Cc: Timo Kokkonen Cc: Sean Young Cc: "Víctor Manuel Jáquez Leal" Cc: Laurent Pinchart Cc: Mauro Carvalho Chehab Cc: Omar Ramirez Luna Cc: Herbert Xu Cc: Greg Kroah-Hartman Cc: Santosh Shilimkar Tested-by: Ezequiel Garcia [tony@atomide.com: updated to disable mailbox] Signed-off-by: Tony Lindgren --- arch/arm/mach-omap2/Kconfig | 2 +- arch/arm/plat-omap/Kconfig | 2 +- drivers/crypto/omap-sham.c | 3 +++ drivers/media/rc/Kconfig | 2 +- drivers/staging/tidspbridge/Kconfig | 2 +- 5 files changed, 7 insertions(+), 4 deletions(-) (limited to 'drivers') diff --git a/arch/arm/mach-omap2/Kconfig b/arch/arm/mach-omap2/Kconfig index 41b581fd0213..492d76466833 100644 --- a/arch/arm/mach-omap2/Kconfig +++ b/arch/arm/mach-omap2/Kconfig @@ -397,7 +397,7 @@ config OMAP3_SDRC_AC_TIMING config OMAP4_ERRATA_I688 bool "OMAP4 errata: Async Bridge Corruption" - depends on ARCH_OMAP4 + depends on ARCH_OMAP4 && !ARCH_MULTIPLATFORM select ARCH_HAS_BARRIERS help If a data is stalled inside asynchronous bridge because of back diff --git a/arch/arm/plat-omap/Kconfig b/arch/arm/plat-omap/Kconfig index 665870dce3c8..03f12525913e 100644 --- a/arch/arm/plat-omap/Kconfig +++ b/arch/arm/plat-omap/Kconfig @@ -118,7 +118,7 @@ config OMAP_MUX_WARNINGS config OMAP_MBOX_FWK tristate "Mailbox framework support" - depends on ARCH_OMAP + depends on ARCH_OMAP && !ARCH_MULTIPLATFORM help Say Y here if you want to use OMAP Mailbox framework support for DSP, IVA1.0 and IVA2 in OMAP1/2/3. diff --git a/drivers/crypto/omap-sham.c b/drivers/crypto/omap-sham.c index 90d34adc2a66..9e6947bc296f 100644 --- a/drivers/crypto/omap-sham.c +++ b/drivers/crypto/omap-sham.c @@ -38,7 +38,10 @@ #include #include + +#ifdef CONFIG_ARCH_OMAP1 #include +#endif #define SHA_REG_DIGEST(x) (0x00 + ((x) * 0x04)) #define SHA_REG_DIN(x) (0x1C + ((x) * 0x04)) diff --git a/drivers/media/rc/Kconfig b/drivers/media/rc/Kconfig index 79ba242fe263..19f3563c61da 100644 --- a/drivers/media/rc/Kconfig +++ b/drivers/media/rc/Kconfig @@ -291,7 +291,7 @@ config IR_TTUSBIR config IR_RX51 tristate "Nokia N900 IR transmitter diode" - depends on OMAP_DM_TIMER && LIRC + depends on OMAP_DM_TIMER && LIRC && !ARCH_MULTIPLATFORM ---help--- Say Y or M here if you want to enable support for the IR transmitter diode built in the Nokia N900 (RX51) device. diff --git a/drivers/staging/tidspbridge/Kconfig b/drivers/staging/tidspbridge/Kconfig index 0dd479f5638d..60848f198b48 100644 --- a/drivers/staging/tidspbridge/Kconfig +++ b/drivers/staging/tidspbridge/Kconfig @@ -4,7 +4,7 @@ menuconfig TIDSPBRIDGE tristate "DSP Bridge driver" - depends on ARCH_OMAP3 + depends on ARCH_OMAP3 && !ARCH_MULTIPLATFORM select OMAP_MBOX_FWK help DSP/BIOS Bridge is designed for platforms that contain a GPP and -- cgit v1.2.3 From c38cd8729c90495687ad027a993099d9972ffbf1 Mon Sep 17 00:00:00 2001 From: Arnd Bergmann Date: Thu, 14 Feb 2013 18:13:15 +0100 Subject: [media] davinci: do not include mach/hardware.h It is now possible to build the davinci vpss code on multiplatform kernels, which causes a problem since the driver tries to incude the davinci platform specific mach/hardware.h file. Fortunately that file is not required at all in the driver, so we can simply remove the #include statement. Without this patch, building allyesconfig results in: drivers/media/platform/davinci/vpss.c:28:27: fatal error: mach/hardware.h: No such file or directory compilation terminated. Signed-off-by: Arnd Bergmann Acked-by: "Lad, Prabhakar" Acked-by: Tony Lindgren Cc: Mauro Carvalho Chehab --- drivers/media/platform/davinci/vpss.c | 1 - 1 file changed, 1 deletion(-) (limited to 'drivers') diff --git a/drivers/media/platform/davinci/vpss.c b/drivers/media/platform/davinci/vpss.c index cdbff88e0f1e..684e815a81b6 100644 --- a/drivers/media/platform/davinci/vpss.c +++ b/drivers/media/platform/davinci/vpss.c @@ -25,7 +25,6 @@ #include #include #include -#include #include MODULE_LICENSE("GPL"); -- cgit v1.2.3 From 0bef6c933f3ec67c978e2cd0e20b389084ddc600 Mon Sep 17 00:00:00 2001 From: Arnd Bergmann Date: Thu, 14 Feb 2013 17:53:18 +0100 Subject: remoteproc: omap: depend on OMAP_MBOX_FWK Patch a62a6e98 "ARM: OMAP2+: Disable code that currently does not work with multiplaform" makes the OMAP_MBOX_FWK option depend on !MULTIPLATFORM, which means we cannot simply select that symbol from OMAP_REMOTEPROC. Turning the 'select' into 'depends on' ensures that all dependencies are correct until OMAP_MBOX_FWK loses its dependency. Without this patch, building allmodconfig results in: drivers/remoteproc/omap_remoteproc.c:31:26: fatal error: plat/mailbox.h: No such file or directory Signed-off-by: Arnd Bergmann Acked-by: Tony Lindgren Acked-by: Ohad Ben-Cohen --- drivers/remoteproc/Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers') diff --git a/drivers/remoteproc/Kconfig b/drivers/remoteproc/Kconfig index 96ce101b9067..c0c37b525303 100644 --- a/drivers/remoteproc/Kconfig +++ b/drivers/remoteproc/Kconfig @@ -14,8 +14,8 @@ config OMAP_REMOTEPROC depends on HAS_DMA depends on ARCH_OMAP4 depends on OMAP_IOMMU + depends on OMAP_MBOX_FWK select REMOTEPROC - select OMAP_MBOX_FWK select RPMSG help Say y here to support OMAP's remote processors (dual M3 -- cgit v1.2.3 From 6929e24e4cc46ce8d5b7dd8f8bdf4244c8d77f76 Mon Sep 17 00:00:00 2001 From: Arnd Bergmann Date: Thu, 14 Feb 2013 17:53:01 +0100 Subject: net: cwdavinci_cpdma: export symbols for cpsw With the support for ARM AM33xx in multiplatform kernels in 3.9, an older bug appears in ARM allmodconfig: When the cpsw driver is built as a module with cpdma support enabled, it uses symbols that the cpdma driver does not export. Without this patch, building allmodconfig results in: ERROR: "cpdma_ctlr_int_ctrl" [drivers/net/ethernet/ti/ti_cpsw.ko] undefined! ERROR: "cpdma_control_set" [drivers/net/ethernet/ti/ti_cpsw.ko] undefined! ERROR: "cpdma_ctlr_eoi" [drivers/net/ethernet/ti/ti_cpsw.ko] undefined! Signed-off-by: Arnd Bergmann Acked-by: David S. Miller Cc: Mugunthan V N Cc: Vaibhav Hiremath Cc: Richard Cochran Cc: netdev@vger.kernel.org --- drivers/net/ethernet/ti/davinci_cpdma.c | 3 +++ 1 file changed, 3 insertions(+) (limited to 'drivers') diff --git a/drivers/net/ethernet/ti/davinci_cpdma.c b/drivers/net/ethernet/ti/davinci_cpdma.c index 49956730cd8d..1abe0964a5ab 100644 --- a/drivers/net/ethernet/ti/davinci_cpdma.c +++ b/drivers/net/ethernet/ti/davinci_cpdma.c @@ -473,11 +473,13 @@ int cpdma_ctlr_int_ctrl(struct cpdma_ctlr *ctlr, bool enable) spin_unlock_irqrestore(&ctlr->lock, flags); return 0; } +EXPORT_SYMBOL_GPL(cpdma_ctlr_int_ctrl); void cpdma_ctlr_eoi(struct cpdma_ctlr *ctlr) { dma_reg_write(ctlr, CPDMA_MACEOIVECTOR, 0); } +EXPORT_SYMBOL_GPL(cpdma_ctlr_eoi); struct cpdma_chan *cpdma_chan_create(struct cpdma_ctlr *ctlr, int chan_num, cpdma_handler_fn handler) @@ -984,3 +986,4 @@ unlock_ret: spin_unlock_irqrestore(&ctlr->lock, flags); return ret; } +EXPORT_SYMBOL_GPL(cpdma_control_set); -- cgit v1.2.3