[PATCH 12/13] m68k: coldfire: disable platform device tree entries

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



If devicetree is enabled for ColdFire platforms then remove the devices
that are supported by a devicetree from the platform device table.

This is done conditionally for now, until a full conversion to use of
devicetree has been completed. Specifically the ColdFire UART and the
FEC ethernet module can currently be supported by devicetree entries.

Signed-off-by: Greg Ungerer <gerg@xxxxxxxxxxxxxx>
---
 arch/m68k/coldfire/device.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/m68k/coldfire/device.c b/arch/m68k/coldfire/device.c
index 8d7cec28f4d9..e802496d9852 100644
--- a/arch/m68k/coldfire/device.c
+++ b/arch/m68k/coldfire/device.c
@@ -24,6 +24,7 @@
 #include <linux/platform_data/dma-mcf-edma.h>
 #include <linux/platform_data/mmc-esdhc-mcf.h>
 
+#ifndef CONFIG_OF
 /*
  *	All current ColdFire parts contain from 2, 3, 4 or 10 UARTS.
  */
@@ -317,6 +318,7 @@ static struct platform_device mcf_fec1 = {
 	}
 };
 #endif /* MCFFEC_BASE1 */
+#endif /* !CONFIG_OF */
 
 #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI)
 /*
@@ -757,6 +759,7 @@ static struct platform_device mcf_flexcan0 = {
 #endif /* MCFFLEXCAN_SIZE */
 
 static struct platform_device *mcf_devices[] __initdata = {
+#ifndef CONFIG_OF
 	&mcf_uart0,
 #ifdef MCFUART_BASE1
 	&mcf_uart1,
@@ -791,6 +794,7 @@ static struct platform_device *mcf_devices[] __initdata = {
 #ifdef MCFFEC_BASE1
 	&mcf_fec1,
 #endif
+#endif /* !CONFIG_OF */
 #if IS_ENABLED(CONFIG_SPI_COLDFIRE_QSPI)
 	&mcf_qspi,
 #endif
-- 
2.43.0





[Index of Archives]     [Video for Linux]     [Yosemite News]     [Linux S/390]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux