MX: set a common place to share code for Freescale i.MX
Subsystems (3)
PATCH 1/1 MX: set a common place to share code for Freescale i.MX
Up now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
---
Makefile | 4 ++--
arch/arm/{cpu/armv7 => }/imx-common/Makefile | 2 ++
arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c | 0
arch/arm/{cpu/armv7 => }/imx-common/cpu.c | 0
arch/arm/{cpu/armv7 => }/imx-common/i2c.c | 0
arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c | 0
arch/arm/{cpu/armv7 => }/imx-common/speed.c | 0
arch/arm/{cpu/armv7 => }/imx-common/timer.c | 0
8 files changed, 4 insertions(+), 2 deletions(-)
rename arch/arm/{cpu/armv7 => }/imx-common/Makefile (97%)
rename arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/cpu.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/i2c.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/speed.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/timer.c (100%)Makefile +2 -2
@@ -306,10 +306,10 @@ LIBS-y += $(CPUDIR)/omap-common/libomap-common.o endif ifeq ($(SOC),mx5) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),mx6) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),s5pc1xx)
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +2 -0
@@ -27,7 +27,9 @@ include $(TOPDIR)/config.mk LIB = $(obj)libimx-common.o +ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) COBJS-y = iomux-v3.o timer.o cpu.o speed.o +endif COBJS-$(CONFIG_I2C_MXC) += i2c.o COBJS-$(CONFIG_CMD_BMODE) += cmd_bmode.o COBJS := $(sort $(COBJS-y))
arch/arm/imx-common/cmd_bmode.c renamed from arch/arm/cpu/armv7/imx-common/cmd_bmode.c +0 -0
arch/arm/imx-common/cpu.c renamed from arch/arm/cpu/armv7/imx-common/cpu.c +0 -0
arch/arm/imx-common/i2c.c renamed from arch/arm/cpu/armv7/imx-common/i2c.c +0 -0
arch/arm/imx-common/iomux-v3.c renamed from arch/arm/cpu/armv7/imx-common/iomux-v3.c +0 -0
arch/arm/imx-common/speed.c renamed from arch/arm/cpu/armv7/imx-common/speed.c +0 -0
arch/arm/imx-common/timer.c renamed from arch/arm/cpu/armv7/imx-common/timer.c +0 -0
Signature · 1 line
1.7.9.5
PATCH 1/1 MX: set a common place to share code for Freescale i.MX
Dear Stefano Babic,
Quoted 7 lines
Up now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
Signed-off-by Stefano Babic <[email protected]>
[...]
Best regards,
Marek Vasut
PATCH v2 1/1 MX: set a common place to share code for Freescale i.MX
In reply to Stefano BabicUp now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
---
Changes in v2:
- Use the common path for all i.MX SOCs in Makefile
Makefile | 7 ++-----
arch/arm/{cpu/armv7 => }/imx-common/Makefile | 2 ++
arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c | 0
arch/arm/{cpu/armv7 => }/imx-common/cpu.c | 0
arch/arm/{cpu/armv7 => }/imx-common/i2c.c | 0
arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c | 0
arch/arm/{cpu/armv7 => }/imx-common/speed.c | 0
arch/arm/{cpu/armv7 => }/imx-common/timer.c | 0
8 files changed, 4 insertions(+), 5 deletions(-)
rename arch/arm/{cpu/armv7 => }/imx-common/Makefile (97%)
rename arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/cpu.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/i2c.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/speed.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/timer.c (100%)Makefile +2 -5
@@ -305,11 +305,8 @@ ifneq ($(CONFIG_AM33XX)$(CONFIG_OMAP34XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX),) LIBS-y += $(CPUDIR)/omap-common/libomap-common.o endif -ifeq ($(SOC),mx5) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o -endif -ifeq ($(SOC),mx6) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35)) +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),s5pc1xx)
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +2 -0
@@ -27,8 +27,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)libimx-common.o +ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) COBJS-y = iomux-v3.o timer.o cpu.o speed.o COBJS-$(CONFIG_I2C_MXC) += i2c.o +endif COBJS-$(CONFIG_CMD_BMODE) += cmd_bmode.o COBJS := $(sort $(COBJS-y))
arch/arm/imx-common/cmd_bmode.c renamed from arch/arm/cpu/armv7/imx-common/cmd_bmode.c +0 -0
arch/arm/imx-common/cpu.c renamed from arch/arm/cpu/armv7/imx-common/cpu.c +0 -0
arch/arm/imx-common/i2c.c renamed from arch/arm/cpu/armv7/imx-common/i2c.c +0 -0
arch/arm/imx-common/iomux-v3.c renamed from arch/arm/cpu/armv7/imx-common/iomux-v3.c +0 -0
arch/arm/imx-common/speed.c renamed from arch/arm/cpu/armv7/imx-common/speed.c +0 -0
arch/arm/imx-common/timer.c renamed from arch/arm/cpu/armv7/imx-common/timer.c +0 -0
Signature · 1 line
1.7.9.5
PATCH v2 1/1 MX: set a common place to share code for Freescale i.MX
Dear Stefano Babic,
Quoted 5 lines
Up now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
Add in my
... not that there's too much to review :)
Quoted 83 lines
Signed-off-by Stefano Babic <[email protected]>---
Changes in v2:
- Use the common path for all i.MX SOCs inMakefileMakefile | 7 ++----- arch/arm/{cpu/armv7 => }/imx-common/Makefile | 2 ++ arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c | 0 arch/arm/{cpu/armv7 => }/imx-common/cpu.c | 0 arch/arm/{cpu/armv7 => }/imx-common/i2c.c | 0 arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c | 0 arch/arm/{cpu/armv7 => }/imx-common/speed.c | 0 arch/arm/{cpu/armv7 => }/imx-common/timer.c | 0 8 files changed, 4 insertions(+), 5 deletions(-) rename arch/arm/{cpu/armv7 => }/imx-common/Makefile (97%) rename arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c (100%) rename arch/arm/{cpu/armv7 => }/imx-common/cpu.c (100%) rename arch/arm/{cpu/armv7 => }/imx-common/i2c.c (100%) rename arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c (100%) rename arch/arm/{cpu/armv7 => }/imx-common/speed.c (100%) rename arch/arm/{cpu/armv7 => }/imx-common/timer.c (100%)Makefile +0
-0@@ -305,11 +305,8 @@ ifneq ($(CONFIG_AM33XX)$(CONFIG_OMAP34XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX),)LIBS-y += $(CPUDIR)/omap-common/libomap-common.o
endifMakefile +2
-5-ifeq ($(SOC),mx5) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o -endif -ifeq ($(SOC),mx6) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35)) +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),s5pc1xx)(quoted diff) +0
-0b/arch/arm/imx-common/Makefile similarity index 97% rename from
arch/arm/cpu/armv7/imx-common/Makefilerename toarch/arm/imx-common/Makefileindex 16fba8d..453f822 100644arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +2
-0@@ -27,8 +27,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)libimx-common.o +ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) COBJS-y = iomux-v3.o timer.o cpu.o speed.o COBJS-$(CONFIG_I2C_MXC) += i2c.o +endif COBJS-$(CONFIG_CMD_BMODE) += cmd_bmode.o COBJS := $(sort $(COBJS-y))(quoted diff) +0
-0
b/arch/arm/imx-common/cmd_bmode.csimilarity index 100% rename fromarch/arm/cpu/armv7/imx-common/cmd_bmode.crename toarch/arm/imx-common/cmd_bmode.c(quoted diff) +0
-0
b/arch/arm/imx-common/cpu.csimilarity index 100% rename fromarch/arm/cpu/armv7/imx-common/cpu.crename toarch/arm/imx-common/cpu.c(quoted diff) +0
-0
b/arch/arm/imx-common/i2c.csimilarity index 100% rename fromarch/arm/cpu/armv7/imx-common/i2c.crename toarch/arm/imx-common/i2c.c(quoted diff) +0
-0
b/arch/arm/imx-common/iomux-v3.csimilarity index 100% rename fromarch/arm/cpu/armv7/imx-common/iomux-v3.crename toarch/arm/imx-common/iomux-v3.c(quoted diff) +0
-0
b/arch/arm/imx-common/speed.csimilarity index 100% rename fromarch/arm/cpu/armv7/imx-common/speed.crename toarch/arm/imx-common/speed.c(quoted diff) +0
-0
b/arch/arm/imx-common/timer.csimilarity index 100% rename fromarch/arm/cpu/armv7/imx-common/timer.crename toarch/arm/imx-common/timer.c
PATCH v2 1/1 MX: set a common place to share code for Freescale i.MX
In reply to Stefano BabicQuoted 54 lines · Stefano Babic
Up now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
Signed-off-by Stefano Babic <[email protected]>---
Changes in v2:
- Use the common path for all i.MX SOCs inMakefileMakefile | 7 ++----- arch/arm/{cpu/armv7 => }/imx-common/Makefile | 2 ++ arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c | 0 arch/arm/{cpu/armv7 => }/imx-common/cpu.c | 0 arch/arm/{cpu/armv7 => }/imx-common/i2c.c | 0 arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c | 0 arch/arm/{cpu/armv7 => }/imx-common/speed.c | 0 arch/arm/{cpu/armv7 => }/imx-common/timer.c | 0 8 files changed, 4 insertions(+), 5 deletions(-)rename
arch/arm/{cpu/armv7=> }/imx-common/Makefile (97%) renamearch/arm/{cpu/armv7=>}/imx-common/cmd_bmode.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/cpu.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/i2c.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/iomux-v3.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/speed.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/timer.c(100%)Makefile +2
-5@@ -305,11 +305,8 @@ ifneq ($(CONFIG_AM33XX)$(CONFIG_OMAP34XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX),) LIBS-y += $(CPUDIR)/omap-common/libomap-common.o endif -ifeq ($(SOC),mx5) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o -endif -ifeq ($(SOC),mx6) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35)) +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),s5pc1xx)arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +0
-0
arch/arm/imx-common/Makefile include $(TOPDIR)/config.mk · line 32
Quoted 6 lines
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +1
-0@@ -27,8 +27,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)libimx-common.o +ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) COBJS-y = iomux-v3.o timer.o cpu.o speed.o COBJS-$(CONFIG_I2C_MXC) += i2c.o
shouldn't the endif be a line higher???
mx25_3stack.h:#define CONFIG_I2C_MXC 1
Quoted 28 lines
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +1
-0+endif COBJS-$(CONFIG_CMD_BMODE) += cmd_bmode.o COBJS := $(sort $(COBJS-y))arch/arm/imx-common/cmd_bmode.c renamed from arch/arm/cpu/armv7/imx-common/cmd_bmode.c +0
-0arch/arm/imx-common/cpu.c renamed from arch/arm/cpu/armv7/imx-common/cpu.c +0
-0arch/arm/imx-common/i2c.c renamed from arch/arm/cpu/armv7/imx-common/i2c.c +0
-0arch/arm/imx-common/iomux-v3.c renamed from arch/arm/cpu/armv7/imx-common/iomux-v3.c +0
-0arch/arm/imx-common/speed.c renamed from arch/arm/cpu/armv7/imx-common/speed.c +0
-0arch/arm/imx-common/timer.c renamed from arch/arm/cpu/armv7/imx-common/timer.c +0
-0
PATCH v2 1/1 MX: set a common place to share code for Freescale i.MX
Quoted 62 lines · Troy Kisky
Quoted 54 lines · Stefano Babic
Up now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
Signed-off-by Stefano Babic <[email protected]>---
Changes in v2:
- Use the common path for all i.MX SOCs inMakefileMakefile | 7 ++----- arch/arm/{cpu/armv7 => }/imx-common/Makefile | 2 ++ arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c | 0 arch/arm/{cpu/armv7 => }/imx-common/cpu.c | 0 arch/arm/{cpu/armv7 => }/imx-common/i2c.c | 0 arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c | 0 arch/arm/{cpu/armv7 => }/imx-common/speed.c | 0 arch/arm/{cpu/armv7 => }/imx-common/timer.c | 0 8 files changed, 4 insertions(+), 5 deletions(-)rename
arch/arm/{cpu/armv7=> }/imx-common/Makefile (97%) renamearch/arm/{cpu/armv7=>}/imx-common/cmd_bmode.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/cpu.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/i2c.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/iomux-v3.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/speed.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/timer.c(100%)Makefile +2
-4@@ -305,11 +305,8 @@ ifneq ($(CONFIG_AM33XX)$(CONFIG_OMAP34XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX),) LIBS-y += $(CPUDIR)/omap-common/libomap-common.o endif -ifeq ($(SOC),mx5) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o -endif -ifeq ($(SOC),mx6) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35)) +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),s5pc1xx)arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +0
-0arch/arm/imx-common/Makefile include $(TOPDIR)/config.mk · line 30
Quoted 4 lines
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +0
-0@@ -27,8 +27,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)libimx-common.o +ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) COBJS-y = iomux-v3.o timer.o cpu.o speed.o COBJS-$(CONFIG_I2C_MXC) += i2c.oshouldn't the endif be a line higher???
Quoted 2 lines
mx25_3stack.h:#define
CONFIG_I2C_MXC1
No, I guess your right!!!!
Sorry for the noise.
Quoted 34 lines
Quoted 33 lines
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +1
-0+endif COBJS-$(CONFIG_CMD_BMODE) += cmd_bmode.o COBJS := $(sort $(COBJS-y)) diff --git a/arch/arm/cpu/armv7/imx-common/cmd_bmode.c
b/arch/arm/imx-common/cmd_bmode.c
similarity index 100%
rename fromarch/arm/cpu/armv7/imx-common/cmd_bmode.crename toarch/arm/imx-common/cmd_bmode.carch/arm/imx-common/cpu.c renamed from arch/arm/cpu/armv7/imx-common/cpu.c +0
-0arch/arm/imx-common/i2c.c renamed from arch/arm/cpu/armv7/imx-common/i2c.c +0
-0arch/arm/imx-common/iomux-v3.c renamed from arch/arm/cpu/armv7/imx-common/iomux-v3.c +0
-0arch/arm/imx-common/speed.c renamed from arch/arm/cpu/armv7/imx-common/speed.c +0
-0arch/arm/imx-common/timer.c renamed from arch/arm/cpu/armv7/imx-common/timer.c +0
-0
PATCH v2 1/1 MX: set a common place to share code for Freescale i.MX
Quoted 64 lines · Troy Kisky
Quoted 63 lines · Troy Kisky
Quoted 55 lines · Stefano Babic
Up now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
Signed-off-by Stefano Babic <[email protected]>---
Changes in v2:
- Use the common path for all i.MX SOCs inMakefileMakefile | 7 ++----- arch/arm/{cpu/armv7 => }/imx-common/Makefile | 2 ++ arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c | 0 arch/arm/{cpu/armv7 => }/imx-common/cpu.c | 0 arch/arm/{cpu/armv7 => }/imx-common/i2c.c | 0 arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c | 0 arch/arm/{cpu/armv7 => }/imx-common/speed.c | 0 arch/arm/{cpu/armv7 => }/imx-common/timer.c | 0 8 files changed, 4 insertions(+), 5 deletions(-)rename
arch/arm/{cpu/armv7=> }/imx-common/Makefile (97%) renamearch/arm/{cpu/armv7=>}/imx-common/cmd_bmode.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/cpu.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/i2c.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/iomux-v3.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/speed.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/timer.c(100%)Makefile +2
-4@@ -305,11 +305,8 @@ ifneq ($(CONFIG_AM33XX)$(CONFIG_OMAP34XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX),) LIBS-y += $(CPUDIR)/omap-common/libomap-common.o endif -ifeq ($(SOC),mx5) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o -endif -ifeq ($(SOC),mx6) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35)) +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),s5pc1xx)arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +0
-0arch/arm/imx-common/Makefile include $(TOPDIR)/config.mk · line 30
Quoted 4 lines
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +0
-0@@ -27,8 +27,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)libimx-common.o +ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) COBJS-y = iomux-v3.o timer.o cpu.o speed.o COBJS-$(CONFIG_I2C_MXC) += i2c.oshouldn't the endif be a line higher???
Quoted 5 lines
Quoted 2 lines
mx25_3stack.h:#define
CONFIG_I2C_MXC1No, I guess your right!!!!
Sorry for the noise.
No problem. Maybe we should also later rename the files specific for a SOC or a SOC family in imx-common, as i2c.c that it is only for MX5 and mx6.
Regards,
Stefano
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de =====================================================================
PATCH v2 1/1 MX: set a common place to share code for Freescale i.MX
Dear Stefano Babic,
Quoted 74 lines · Troy Kisky
Quoted 73 lines · Troy Kisky
Quoted 71 lines · Stefano Babic
Quoted 60 lines
Up now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
Signed-off-by Stefano Babic <[email protected]>---
Changes in v2:
- Use the common path for all i.MX SOCs inMakefileMakefile | 7 ++----- arch/arm/{cpu/armv7 => }/imx-common/Makefile | 2 ++ arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c | 0 arch/arm/{cpu/armv7 => }/imx-common/cpu.c | 0 arch/arm/{cpu/armv7 => }/imx-common/i2c.c | 0 arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c | 0 arch/arm/{cpu/armv7 => }/imx-common/speed.c | 0 arch/arm/{cpu/armv7 => }/imx-common/timer.c | 0 8 files changed, 4 insertions(+), 5 deletions(-)rename
arch/arm/{cpu/armv7=> }/imx-common/Makefile (97%) renamearch/arm/{cpu/armv7=>}/imx-common/cmd_bmode.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/cpu.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/i2c.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/iomux-v3.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/speed.c(100%) renamearch/arm/{cpu/armv7=>}/imx-common/timer.c(100%)Makefile +2
-4@@ -305,11 +305,8 @@ ifneq ($(CONFIG_AM33XX)$(CONFIG_OMAP34XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX) ,) LIBS-y += $(CPUDIR)/omap-common/libomap-common.o endif -ifeq ($(SOC),mx5) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o -endif -ifeq ($(SOC),mx6) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35)) +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),s5pc1xx)arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +0
-0arch/arm/imx-common/Makefile include $(TOPDIR)/config.mk · line 32
Quoted 6 lines
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +0
-0@@ -27,8 +27,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)libimx-common.o +ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) COBJS-y = iomux-v3.o timer.o cpu.o speed.o COBJS-$(CONFIG_I2C_MXC) += i2c.oshouldn't the endif be a line higher???
mx25_3stack.h:#define
CONFIG_I2C_MXC1
Quoted 7 lines
Quoted 3 lines
No, I guess your right!!!!
Sorry for the noise.
No problem. Maybe we should also later rename the files specific for a SOC or a SOC family in imx-common, as
i2c.cthat it is only for MX5 and mx6.
i2c-mxv7 ? :)
PATCH v2 1/1 MX: set a common place to share code for Freescale i.MX
Quoted 6 lines · Marek Vasut
Quoted 6 lines
Quoted 6 lines
Quoted 3 lines
shouldn't the endif be a line higher???
mx25_3stack.h:#define
CONFIG_I2C_MXC1No, I guess your right!!!!
Quoted 7 lines
Quoted 5 lines
Quoted 1 line
Sorry for the noise.
No problem. Maybe we should also later rename the files specific for a SOC or a SOC family in imx-common, as
i2c.cthat it is only for MX5 and mx6.i2c-mxv7 ? :)
Good idea. I push a V3 for it.
Thanks,
Stefano
Signature · 5 lines
===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de =====================================================================
PATCH v2 1/1 MX: set a common place to share code for Freescale i.MX
Dear Stefano Babic,
Quoted 9 lines · Marek Vasut
Quoted 8 lines
Quoted 8 lines
Quoted 7 lines
Quoted 3 lines
shouldn't the endif be a line higher???
mx25_3stack.h:#define
CONFIG_I2C_MXC1No, I guess your right!!!!
Sorry for the noise.
Quoted 7 lines
Quoted 5 lines
Quoted 3 lines
No problem. Maybe we should also later rename the files specific for a SOC or a SOC family in imx-common, as
i2c.cthat it is only for MX5 and mx6.i2c-mxv7 ? :)
Good idea. I push a V3 for it.
Heh, it was just an early-morning blurt ;-)
PATCH v3 1/1 MX: set a common place to share code for Freescale i.MX
In reply to Stefano BabicUp now only MX5 and MX6 can share code, because they have a common source directory in cpu/armv7. Other not armv7 i.MX can profit of the same shared code. Move these files into a directory accessible for all, similar to plat-mxc in linux.
---
Changes in v2:
- Use the common path for all i.MX SOCs
Changes in v3:
- use suffix for files that are SOC specific (Marek Vasut)
Makefile | 7 ++-----
arch/arm/{cpu/armv7 => }/imx-common/Makefile | 4 +++-
arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c | 0
arch/arm/{cpu/armv7 => }/imx-common/cpu.c | 0
.../imx-common/i2c.c => imx-common/i2c-mxv7.c} | 0
arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c | 0
arch/arm/{cpu/armv7 => }/imx-common/speed.c | 0
arch/arm/{cpu/armv7 => }/imx-common/timer.c | 0
8 files changed, 5 insertions(+), 6 deletions(-)
rename arch/arm/{cpu/armv7 => }/imx-common/Makefile (94%)
rename arch/arm/{cpu/armv7 => }/imx-common/cmd_bmode.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/cpu.c (100%)
rename arch/arm/{cpu/armv7/imx-common/i2c.c => imx-common/i2c-mxv7.c} (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/iomux-v3.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/speed.c (100%)
rename arch/arm/{cpu/armv7 => }/imx-common/timer.c (100%)Makefile +2 -5
@@ -305,11 +305,8 @@ ifneq ($(CONFIG_AM33XX)$(CONFIG_OMAP34XX)$(CONFIG_OMAP44XX)$(CONFIG_OMAP54XX),) LIBS-y += $(CPUDIR)/omap-common/libomap-common.o endif -ifeq ($(SOC),mx5) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o -endif -ifeq ($(SOC),mx6) -LIBS-y += $(CPUDIR)/imx-common/libimx-common.o +ifneq (,$(filter $(SOC), mx25 mx27 mx5 mx6 mx31 mx35)) +LIBS-y += arch/$(ARCH)/imx-common/libimx-common.o endif ifeq ($(SOC),s5pc1xx)
arch/arm/imx-common/Makefile renamed from arch/arm/cpu/armv7/imx-common/Makefile +3 -1
@@ -27,8 +27,10 @@ include $(TOPDIR)/config.mk LIB = $(obj)libimx-common.o +ifeq ($(SOC),$(filter $(SOC),mx5 mx6)) COBJS-y = iomux-v3.o timer.o cpu.o speed.o -COBJS-$(CONFIG_I2C_MXC) += i2c.o +COBJS-$(CONFIG_I2C_MXC) += i2c-mxv7.o +endif COBJS-$(CONFIG_CMD_BMODE) += cmd_bmode.o COBJS := $(sort $(COBJS-y))
arch/arm/imx-common/cmd_bmode.c renamed from arch/arm/cpu/armv7/imx-common/cmd_bmode.c +0 -0
arch/arm/imx-common/cpu.c renamed from arch/arm/cpu/armv7/imx-common/cpu.c +0 -0
arch/arm/imx-common/i2c-mxv7.c renamed from arch/arm/cpu/armv7/imx-common/i2c.c +0 -0
arch/arm/imx-common/iomux-v3.c renamed from arch/arm/cpu/armv7/imx-common/iomux-v3.c +0 -0
arch/arm/imx-common/speed.c renamed from arch/arm/cpu/armv7/imx-common/speed.c +0 -0
arch/arm/imx-common/timer.c renamed from arch/arm/cpu/armv7/imx-common/timer.c +0 -0
Signature · 1 line
1.7.9.5