diff mbox

[5/8] ARM i.MX Allow to compile together i.MX1/21/25/27

Message ID 1305823648-2428-6-git-send-email-s.hauer@pengutronix.de
State New
Headers show

Commit Message

Sascha Hauer May 19, 2011, 4:47 p.m. UTC
This allows for all armv4 and armv5 based i.MX systems to be compiled
together in one kernel. To accomplish this we need ARM_PATCH_PHYS_VIRT
and AUTO_ZRELADDR which is selected in Kconfig. This breaks execute
in place support. It would be possible to keep XIP support, but the
needed Kconfig magix is just too ugly.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 arch/arm/mach-imx/Kconfig                    |   51 +++++++++-----------------
 arch/arm/mach-imx/Makefile                   |   10 +++---
 arch/arm/mach-imx/Makefile.boot              |   16 --------
 arch/arm/plat-mxc/Kconfig                    |   18 +++-------
 arch/arm/plat-mxc/devices/platform-imx-dma.c |    2 +-
 5 files changed, 29 insertions(+), 68 deletions(-)

Comments

Uwe Kleine-König May 19, 2011, 6:04 p.m. UTC | #1
On Thu, May 19, 2011 at 06:47:25PM +0200, Sascha Hauer wrote:
> This allows for all armv4 and armv5 based i.MX systems to be compiled
> together in one kernel. To accomplish this we need ARM_PATCH_PHYS_VIRT
> and AUTO_ZRELADDR which is selected in Kconfig. This breaks execute
> in place support. It would be possible to keep XIP support, but the
> needed Kconfig magix is just too ugly.
s/magix/magic/
I think the magic isn't that ugly (or the magic you think of is more
ugly than mine :-).


	choice
		prompt "Freescale CPU family:"
		default ARCH_MX3

	config TRALALA_MX1
		bool "MX1"
		select CAN_HAVE_IMX1
		...

	config TRALALA_MX21
		bool "i.MX21"
		select CAN_HAVE_IMX21
		...

	config TRALALA_ARM_V4_V5
		bool "i.MX1, i.MX21, i.MX25, i.MX27"
		depends on ARM_PATCH_PHYS_VIRT && AUTO_ZRELADDR
		select CAN_HAVE_IMX1
		select CAN_HAVE_IMX21
		select CAN_HAVE_IMX25
		select CAN_HAVE_IMX27

	config TRALALA_MX3
		....

	endchoice

Then the machine entries just need to depend on CAN_HAVE_IMX..

And if you want to can even let TRALALA_MX1 depend on
!ARM_PATCH_PHYS_VIRT || !AUTO_ZRELADDR.

> Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
> ---
>  arch/arm/mach-imx/Kconfig                    |   51 +++++++++-----------------
>  arch/arm/mach-imx/Makefile                   |   10 +++---
>  arch/arm/mach-imx/Makefile.boot              |   16 --------
>  arch/arm/plat-mxc/Kconfig                    |   18 +++-------
>  arch/arm/plat-mxc/devices/platform-imx-dma.c |    2 +-
>  5 files changed, 29 insertions(+), 68 deletions(-)
> 
> diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
> index 59c97a3..90550bc 100644
> --- a/arch/arm/mach-imx/Kconfig
> +++ b/arch/arm/mach-imx/Kconfig
> @@ -11,8 +11,21 @@ config ARCH_MX31
>  config ARCH_MX35
>  	bool
>  
> +config ARCH_MX1
> +	bool
> +
> +config ARCH_MX2
> +	bool
> +
> +config ARCH_MX25
> +	bool
> +
> +config MACH_MX27
> +	bool
> +
>  config SOC_IMX1
>  	bool
> +	select ARCH_MX1
>  	select CPU_ARM920T
>  	select IMX_HAVE_DMA_V1
>  	select IMX_HAVE_IOMUX_V1
> @@ -20,6 +33,7 @@ config SOC_IMX1
>  
>  config SOC_IMX21
>  	bool
> +	select ARCH_MX2
ARCH_MX21 isn't needed?

>  	select CPU_ARM926T
>  	select ARCH_MXC_AUDMUX_V1
>  	select IMX_HAVE_DMA_V1
> @@ -28,6 +42,7 @@ config SOC_IMX21
>  
>  config SOC_IMX25
>  	bool
> +	select ARCH_MX25
>  	select CPU_ARM926T
>  	select ARCH_MXC_AUDMUX_V2
>  	select ARCH_MXC_IOMUX_V3
> @@ -35,6 +50,8 @@ config SOC_IMX25
>  
>  config SOC_IMX27
>  	bool
> +	select MACH_MX27
> +	select ARCH_MX2
>  	select CPU_ARM926T
>  	select ARCH_MXC_AUDMUX_V1
>  	select IMX_HAVE_DMA_V1
> @@ -59,7 +76,7 @@ config SOC_IMX35
>  	select MXC_AVIC
>  
>  
> -if ARCH_MX1
> +if ARCH_IMX_V4_V5
>  
>  comment "MX1 platforms:"
>  config MACH_MXLADS
> @@ -87,30 +104,6 @@ config MACH_APF9328
>  	help
>  	  Say Yes here if you are using the Armadeus APF9328 development board
>  
> -endif
> -
> -if ARCH_MX2
> -
> -choice
> -	prompt "CPUs:"
> -	default MACH_MX21
> -
> -config MACH_MX21
> -	bool "i.MX21 support"
> -	help
> -	  This enables support for Freescale's MX2 based i.MX21 processor.
> -
> -config MACH_MX27
> -	bool "i.MX27 support"
> -	help
> -	  This enables support for Freescale's MX2 based i.MX27 processor.
> -
> -endchoice
> -
> -endif
> -
> -if MACH_MX21
> -
>  comment "MX21 platforms:"
>  
>  config MACH_MX21ADS
> @@ -124,10 +117,6 @@ config MACH_MX21ADS
>  	  Include support for MX21ADS platform. This includes specific
>  	  configurations for the board and its peripherals.
>  
> -endif
> -
> -if ARCH_MX25
> -
>  comment "MX25 platforms:"
>  
>  config MACH_MX25_3DS
> @@ -173,10 +162,6 @@ config MACH_EUKREA_MBIMXSD25_BASEBOARD
>  
>  endchoice
>  
> -endif
> -
> -if MACH_MX27
> -
>  comment "MX27 platforms:"
>  
>  config MACH_MX27ADS
> diff --git a/arch/arm/mach-imx/Makefile b/arch/arm/mach-imx/Makefile
> index e9eb36d..db6394a 100644
> --- a/arch/arm/mach-imx/Makefile
> +++ b/arch/arm/mach-imx/Makefile
> @@ -1,12 +1,12 @@
>  obj-$(CONFIG_IMX_HAVE_DMA_V1) += dma-v1.o
>  
> -obj-$(CONFIG_ARCH_MX1) += clock-imx1.o mm-imx1.o
> -obj-$(CONFIG_MACH_MX21) += clock-imx21.o mm-imx21.o
> +obj-$(CONFIG_SOC_IMX1) += clock-imx1.o mm-imx1.o
> +obj-$(CONFIG_SOC_IMX21) += clock-imx21.o mm-imx21.o
>  
> -obj-$(CONFIG_ARCH_MX25) += clock-imx25.o mm-imx25.o ehci-imx25.o
> +obj-$(CONFIG_SOC_IMX25) += clock-imx25.o mm-imx25.o ehci-imx25.o
>  
> -obj-$(CONFIG_MACH_MX27) += cpu-imx27.o pm-imx27.o
> -obj-$(CONFIG_MACH_MX27) += clock-imx27.o mm-imx27.o ehci-imx27.o
> +obj-$(CONFIG_SOC_IMX27) += cpu-imx27.o pm-imx27.o
> +obj-$(CONFIG_SOC_IMX27) += clock-imx27.o mm-imx27.o ehci-imx27.o
>  
>  obj-$(CONFIG_SOC_IMX31) += mm-imx31.o cpu-imx31.o clock-imx31.o iomux-imx31.o ehci-imx31.o
>  obj-$(CONFIG_SOC_IMX35) += mm-imx35.o cpu-imx35.o clock-imx35.o ehci-imx35.o
> diff --git a/arch/arm/mach-imx/Makefile.boot b/arch/arm/mach-imx/Makefile.boot
> index ebee18b..cdfe20f 100644
> --- a/arch/arm/mach-imx/Makefile.boot
> +++ b/arch/arm/mach-imx/Makefile.boot
> @@ -1,19 +1,3 @@
> -zreladdr-$(CONFIG_ARCH_MX1)	:= 0x08008000
> -params_phys-$(CONFIG_ARCH_MX1)	:= 0x08000100
> -initrd_phys-$(CONFIG_ARCH_MX1)	:= 0x08800000
> -
> -zreladdr-$(CONFIG_MACH_MX21)	:= 0xC0008000
> -params_phys-$(CONFIG_MACH_MX21)	:= 0xC0000100
> -initrd_phys-$(CONFIG_MACH_MX21)	:= 0xC0800000
> -
> -zreladdr-$(CONFIG_ARCH_MX25)	:= 0x80008000
> -params_phys-$(CONFIG_ARCH_MX25)	:= 0x80000100
> -initrd_phys-$(CONFIG_ARCH_MX25)	:= 0x80800000
> -
> -zreladdr-$(CONFIG_MACH_MX27)	:= 0xA0008000
> -params_phys-$(CONFIG_MACH_MX27)	:= 0xA0000100
> -initrd_phys-$(CONFIG_MACH_MX27)	:= 0xA0800000
> -
>  zreladdr-$(CONFIG_ARCH_MX3)	:= 0x80008000
>  params_phys-$(CONFIG_ARCH_MX3)	:= 0x80000100
>  initrd_phys-$(CONFIG_ARCH_MX3)	:= 0x80800000
> diff --git a/arch/arm/plat-mxc/Kconfig b/arch/arm/plat-mxc/Kconfig
> index a5353fc..0202ca0 100644
> --- a/arch/arm/plat-mxc/Kconfig
> +++ b/arch/arm/plat-mxc/Kconfig
> @@ -14,20 +14,12 @@ choice
>  	prompt "Freescale CPU family:"
>  	default ARCH_MX3
>  
> -config ARCH_MX1
> -	bool "MX1-based"
> +config ARCH_IMX_V4_V5
> +	select ARM_PATCH_PHYS_VIRT
> +	select AUTO_ZRELADDR
select EXPERIMENTAL

> +	bool "i.MX1, i.MX21, i.MX25, i.MX27"
>  	help
> -	  This enables support for systems based on the Freescale i.MX1 family
> -
> -config ARCH_MX2
> -	bool "MX2-based"
> -	help
> -	  This enables support for systems based on the Freescale i.MX2 family
> -
> -config ARCH_MX25
> -	bool "MX25-based"
> -	help
> -	  This enables support for systems based on the Freescale i.MX25 family
> +	  This enables support for armv4 and armv5 based i.MX systems
>  
>  config ARCH_MX3
>  	bool "MX3-based"
> diff --git a/arch/arm/plat-mxc/devices/platform-imx-dma.c b/arch/arm/plat-mxc/devices/platform-imx-dma.c
> index 3538b85..735b81d 100644
> --- a/arch/arm/plat-mxc/devices/platform-imx-dma.c
> +++ b/arch/arm/plat-mxc/devices/platform-imx-dma.c
> @@ -76,7 +76,7 @@ static struct platform_device __init __maybe_unused *imx_add_imx_dma(void)
>  	return imx_add_platform_device("imx-dma", -1, NULL, 0, NULL, 0);
>  }
>  
> -#ifdef CONFIG_ARCH_MX25
> +#ifdef CONFIG_SOC_IMX25
>  static struct sdma_script_start_addrs addr_imx25_to1 = {
>  	.ap_2_ap_addr = 729,
>  	.uart_2_mcu_addr = 904,

Best regards
Uwe
Sascha Hauer May 19, 2011, 7:03 p.m. UTC | #2
On Thu, May 19, 2011 at 08:04:56PM +0200, Uwe Kleine-König wrote:
> On Thu, May 19, 2011 at 06:47:25PM +0200, Sascha Hauer wrote:
> > This allows for all armv4 and armv5 based i.MX systems to be compiled
> > together in one kernel. To accomplish this we need ARM_PATCH_PHYS_VIRT
> > and AUTO_ZRELADDR which is selected in Kconfig. This breaks execute
> > in place support. It would be possible to keep XIP support, but the
> > needed Kconfig magix is just too ugly.
> s/magix/magic/
> I think the magic isn't that ugly (or the magic you think of is more
> ugly than mine :-).
> 
> 
> 	choice
> 		prompt "Freescale CPU family:"
> 		default ARCH_MX3
> 
> 	config TRALALA_MX1
> 		bool "MX1"
> 		select CAN_HAVE_IMX1
> 		...
> 
> 	config TRALALA_MX21
> 		bool "i.MX21"
> 		select CAN_HAVE_IMX21
> 		...
> 
> 	config TRALALA_ARM_V4_V5
> 		bool "i.MX1, i.MX21, i.MX25, i.MX27"
> 		depends on ARM_PATCH_PHYS_VIRT && AUTO_ZRELADDR
> 		select CAN_HAVE_IMX1
> 		select CAN_HAVE_IMX21
> 		select CAN_HAVE_IMX25
> 		select CAN_HAVE_IMX27
> 
> 	config TRALALA_MX3
> 		....

This is exactly the magic I had in mind and I don't really like another
set of *_IMX* kconfig entries.

> >  
> >  config SOC_IMX21
> >  	bool
> > +	select ARCH_MX2
> ARCH_MX21 isn't needed?

Nope, I removed it along the way. It's unused.

> > index a5353fc..0202ca0 100644
> > --- a/arch/arm/plat-mxc/Kconfig
> > +++ b/arch/arm/plat-mxc/Kconfig
> > @@ -14,20 +14,12 @@ choice
> >  	prompt "Freescale CPU family:"
> >  	default ARCH_MX3
> >  
> > -config ARCH_MX1
> > -	bool "MX1-based"
> > +config ARCH_IMX_V4_V5
> > +	select ARM_PATCH_PHYS_VIRT
> > +	select AUTO_ZRELADDR
> select EXPERIMENTAL

Hm, yes. Though I would really prefer removing the depency on
EXPERIMENTAL.

Sascha
Nicolas Pitre May 19, 2011, 7:44 p.m. UTC | #3
On Thu, 19 May 2011, Sascha Hauer wrote:

> On Thu, May 19, 2011 at 08:04:56PM +0200, Uwe Kleine-König wrote:
> > On Thu, May 19, 2011 at 06:47:25PM +0200, Sascha Hauer wrote:
> > > index a5353fc..0202ca0 100644
> > > --- a/arch/arm/plat-mxc/Kconfig
> > > +++ b/arch/arm/plat-mxc/Kconfig
> > > @@ -14,20 +14,12 @@ choice
> > >  	prompt "Freescale CPU family:"
> > >  	default ARCH_MX3
> > >  
> > > -config ARCH_MX1
> > > -	bool "MX1-based"
> > > +config ARCH_IMX_V4_V5
> > > +	select ARM_PATCH_PHYS_VIRT
> > > +	select AUTO_ZRELADDR
> > select EXPERIMENTAL
> 
> Hm, yes. Though I would really prefer removing the depency on
> EXPERIMENTAL.

If those features are actually used, relied upon, and therefore 
obviously tested, I think the experimental dependency doesn't make sense 
anymore.


Nicolas
Sascha Hauer May 19, 2011, 7:50 p.m. UTC | #4
On Thu, May 19, 2011 at 03:44:13PM -0400, Nicolas Pitre wrote:
> On Thu, 19 May 2011, Sascha Hauer wrote:
> 
> > On Thu, May 19, 2011 at 08:04:56PM +0200, Uwe Kleine-König wrote:
> > > On Thu, May 19, 2011 at 06:47:25PM +0200, Sascha Hauer wrote:
> > > > index a5353fc..0202ca0 100644
> > > > --- a/arch/arm/plat-mxc/Kconfig
> > > > +++ b/arch/arm/plat-mxc/Kconfig
> > > > @@ -14,20 +14,12 @@ choice
> > > >  	prompt "Freescale CPU family:"
> > > >  	default ARCH_MX3
> > > >  
> > > > -config ARCH_MX1
> > > > -	bool "MX1-based"
> > > > +config ARCH_IMX_V4_V5
> > > > +	select ARM_PATCH_PHYS_VIRT
> > > > +	select AUTO_ZRELADDR
> > > select EXPERIMENTAL
> > 
> > Hm, yes. Though I would really prefer removing the depency on
> > EXPERIMENTAL.
> 
> If those features are actually used, relied upon, and therefore 
> obviously tested, I think the experimental dependency doesn't make sense 
> anymore.

I'll add a patch for this to this series.

Sascha
diff mbox

Patch

diff --git a/arch/arm/mach-imx/Kconfig b/arch/arm/mach-imx/Kconfig
index 59c97a3..90550bc 100644
--- a/arch/arm/mach-imx/Kconfig
+++ b/arch/arm/mach-imx/Kconfig
@@ -11,8 +11,21 @@  config ARCH_MX31
 config ARCH_MX35
 	bool
 
+config ARCH_MX1
+	bool
+
+config ARCH_MX2
+	bool
+
+config ARCH_MX25
+	bool
+
+config MACH_MX27
+	bool
+
 config SOC_IMX1
 	bool
+	select ARCH_MX1
 	select CPU_ARM920T
 	select IMX_HAVE_DMA_V1
 	select IMX_HAVE_IOMUX_V1
@@ -20,6 +33,7 @@  config SOC_IMX1
 
 config SOC_IMX21
 	bool
+	select ARCH_MX2
 	select CPU_ARM926T
 	select ARCH_MXC_AUDMUX_V1
 	select IMX_HAVE_DMA_V1
@@ -28,6 +42,7 @@  config SOC_IMX21
 
 config SOC_IMX25
 	bool
+	select ARCH_MX25
 	select CPU_ARM926T
 	select ARCH_MXC_AUDMUX_V2
 	select ARCH_MXC_IOMUX_V3
@@ -35,6 +50,8 @@  config SOC_IMX25
 
 config SOC_IMX27
 	bool
+	select MACH_MX27
+	select ARCH_MX2
 	select CPU_ARM926T
 	select ARCH_MXC_AUDMUX_V1
 	select IMX_HAVE_DMA_V1
@@ -59,7 +76,7 @@  config SOC_IMX35
 	select MXC_AVIC
 
 
-if ARCH_MX1
+if ARCH_IMX_V4_V5
 
 comment "MX1 platforms:"
 config MACH_MXLADS
@@ -87,30 +104,6 @@  config MACH_APF9328
 	help
 	  Say Yes here if you are using the Armadeus APF9328 development board
 
-endif
-
-if ARCH_MX2
-
-choice
-	prompt "CPUs:"
-	default MACH_MX21
-
-config MACH_MX21
-	bool "i.MX21 support"
-	help
-	  This enables support for Freescale's MX2 based i.MX21 processor.
-
-config MACH_MX27
-	bool "i.MX27 support"
-	help
-	  This enables support for Freescale's MX2 based i.MX27 processor.
-
-endchoice
-
-endif
-
-if MACH_MX21
-
 comment "MX21 platforms:"
 
 config MACH_MX21ADS
@@ -124,10 +117,6 @@  config MACH_MX21ADS
 	  Include support for MX21ADS platform. This includes specific
 	  configurations for the board and its peripherals.
 
-endif
-
-if ARCH_MX25
-
 comment "MX25 platforms:"
 
 config MACH_MX25_3DS
@@ -173,10 +162,6 @@  config MACH_EUKREA_MBIMXSD25_BASEBOARD
 
 endchoice
 
-endif
-
-if MACH_MX27
-
 comment "MX27 platforms:"
 
 config MACH_MX27ADS
diff --git a/arch/arm/mach-imx/Makefile b/arch/arm/mach-imx/Makefile
index e9eb36d..db6394a 100644
--- a/arch/arm/mach-imx/Makefile
+++ b/arch/arm/mach-imx/Makefile
@@ -1,12 +1,12 @@ 
 obj-$(CONFIG_IMX_HAVE_DMA_V1) += dma-v1.o
 
-obj-$(CONFIG_ARCH_MX1) += clock-imx1.o mm-imx1.o
-obj-$(CONFIG_MACH_MX21) += clock-imx21.o mm-imx21.o
+obj-$(CONFIG_SOC_IMX1) += clock-imx1.o mm-imx1.o
+obj-$(CONFIG_SOC_IMX21) += clock-imx21.o mm-imx21.o
 
-obj-$(CONFIG_ARCH_MX25) += clock-imx25.o mm-imx25.o ehci-imx25.o
+obj-$(CONFIG_SOC_IMX25) += clock-imx25.o mm-imx25.o ehci-imx25.o
 
-obj-$(CONFIG_MACH_MX27) += cpu-imx27.o pm-imx27.o
-obj-$(CONFIG_MACH_MX27) += clock-imx27.o mm-imx27.o ehci-imx27.o
+obj-$(CONFIG_SOC_IMX27) += cpu-imx27.o pm-imx27.o
+obj-$(CONFIG_SOC_IMX27) += clock-imx27.o mm-imx27.o ehci-imx27.o
 
 obj-$(CONFIG_SOC_IMX31) += mm-imx31.o cpu-imx31.o clock-imx31.o iomux-imx31.o ehci-imx31.o
 obj-$(CONFIG_SOC_IMX35) += mm-imx35.o cpu-imx35.o clock-imx35.o ehci-imx35.o
diff --git a/arch/arm/mach-imx/Makefile.boot b/arch/arm/mach-imx/Makefile.boot
index ebee18b..cdfe20f 100644
--- a/arch/arm/mach-imx/Makefile.boot
+++ b/arch/arm/mach-imx/Makefile.boot
@@ -1,19 +1,3 @@ 
-zreladdr-$(CONFIG_ARCH_MX1)	:= 0x08008000
-params_phys-$(CONFIG_ARCH_MX1)	:= 0x08000100
-initrd_phys-$(CONFIG_ARCH_MX1)	:= 0x08800000
-
-zreladdr-$(CONFIG_MACH_MX21)	:= 0xC0008000
-params_phys-$(CONFIG_MACH_MX21)	:= 0xC0000100
-initrd_phys-$(CONFIG_MACH_MX21)	:= 0xC0800000
-
-zreladdr-$(CONFIG_ARCH_MX25)	:= 0x80008000
-params_phys-$(CONFIG_ARCH_MX25)	:= 0x80000100
-initrd_phys-$(CONFIG_ARCH_MX25)	:= 0x80800000
-
-zreladdr-$(CONFIG_MACH_MX27)	:= 0xA0008000
-params_phys-$(CONFIG_MACH_MX27)	:= 0xA0000100
-initrd_phys-$(CONFIG_MACH_MX27)	:= 0xA0800000
-
 zreladdr-$(CONFIG_ARCH_MX3)	:= 0x80008000
 params_phys-$(CONFIG_ARCH_MX3)	:= 0x80000100
 initrd_phys-$(CONFIG_ARCH_MX3)	:= 0x80800000
diff --git a/arch/arm/plat-mxc/Kconfig b/arch/arm/plat-mxc/Kconfig
index a5353fc..0202ca0 100644
--- a/arch/arm/plat-mxc/Kconfig
+++ b/arch/arm/plat-mxc/Kconfig
@@ -14,20 +14,12 @@  choice
 	prompt "Freescale CPU family:"
 	default ARCH_MX3
 
-config ARCH_MX1
-	bool "MX1-based"
+config ARCH_IMX_V4_V5
+	select ARM_PATCH_PHYS_VIRT
+	select AUTO_ZRELADDR
+	bool "i.MX1, i.MX21, i.MX25, i.MX27"
 	help
-	  This enables support for systems based on the Freescale i.MX1 family
-
-config ARCH_MX2
-	bool "MX2-based"
-	help
-	  This enables support for systems based on the Freescale i.MX2 family
-
-config ARCH_MX25
-	bool "MX25-based"
-	help
-	  This enables support for systems based on the Freescale i.MX25 family
+	  This enables support for armv4 and armv5 based i.MX systems
 
 config ARCH_MX3
 	bool "MX3-based"
diff --git a/arch/arm/plat-mxc/devices/platform-imx-dma.c b/arch/arm/plat-mxc/devices/platform-imx-dma.c
index 3538b85..735b81d 100644
--- a/arch/arm/plat-mxc/devices/platform-imx-dma.c
+++ b/arch/arm/plat-mxc/devices/platform-imx-dma.c
@@ -76,7 +76,7 @@  static struct platform_device __init __maybe_unused *imx_add_imx_dma(void)
 	return imx_add_platform_device("imx-dma", -1, NULL, 0, NULL, 0);
 }
 
-#ifdef CONFIG_ARCH_MX25
+#ifdef CONFIG_SOC_IMX25
 static struct sdma_script_start_addrs addr_imx25_to1 = {
 	.ap_2_ap_addr = 729,
 	.uart_2_mcu_addr = 904,