[U-Boot] [SPEAr Fixes PATCH 03/11] spear/include: Clean up the spear include files
Vipin Kumar
vipin.kumar at st.com
Fri Nov 2 18:39:30 CET 2012
This patch targets a few cleanup actions in include files
- Split hardware.h into soc and arch base addresses
Splits the files hierarchically into architecture and soc specific
- Drop the spr_ prefix from the arch header names
- Remove extra header files
- Use only MISC_ as a prefix for misc register address bits
- Add protection against multiple inclusions
Signed-off-by: Vipin Kumar <vipin.kumar at st.com>
---
arch/arm/cpu/arm926ejs/spear/cpu.c | 2 +-
arch/arm/cpu/arm926ejs/spear/reset.c | 2 +-
arch/arm/cpu/arm926ejs/spear/spear600.c | 4 +-
arch/arm/cpu/arm926ejs/spear/spl.c | 6 +-
arch/arm/cpu/arm926ejs/spear/spl_boot.c | 5 +-
arch/arm/cpu/arm926ejs/spear/timer.c | 4 +-
arch/arm/include/asm/arch-spear/clk.h | 5 ++
.../include/asm/arch-spear/{spr_emi.h => emi.h} | 8 +--
.../asm/arch-spear/{spr_defs.h => generic.h} | 15 +----
.../include/asm/arch-spear/{spr_gpt.h => gpt.h} | 4 +-
arch/arm/include/asm/arch-spear/hardware.h | 78 ++++------------------
.../include/asm/arch-spear/{spr_misc.h => misc.h} | 4 +-
.../asm/arch-spear/{spr_ssp.h => spear300.h} | 30 +++------
arch/arm/include/asm/arch-spear/spear310.h | 40 +++++++++++
arch/arm/include/asm/arch-spear/spear320.h | 38 +++++++++++
arch/arm/include/asm/arch-spear/spear3xx.h | 40 +++++++++++
arch/arm/include/asm/arch-spear/spear600.h | 45 +++++++++++++
.../asm/arch-spear/{spr_syscntl.h => syscntl.h} | 0
board/spear/common/spr_misc.c | 3 +-
board/spear/spear300/spear300.c | 4 +-
board/spear/spear310/spear310.c | 4 +-
board/spear/spear320/spear320.c | 4 +-
board/spear/spear600/spear600.c | 4 +-
23 files changed, 219 insertions(+), 130 deletions(-)
rename arch/arm/include/asm/arch-spear/{spr_emi.h => emi.h} (94%)
rename arch/arm/include/asm/arch-spear/{spr_defs.h => generic.h} (88%)
rename arch/arm/include/asm/arch-spear/{spr_gpt.h => gpt.h} (97%)
rename arch/arm/include/asm/arch-spear/{spr_misc.h => misc.h} (99%)
rename arch/arm/include/asm/arch-spear/{spr_ssp.h => spear300.h} (64%)
create mode 100644 arch/arm/include/asm/arch-spear/spear310.h
create mode 100644 arch/arm/include/asm/arch-spear/spear320.h
create mode 100644 arch/arm/include/asm/arch-spear/spear3xx.h
create mode 100644 arch/arm/include/asm/arch-spear/spear600.h
rename arch/arm/include/asm/arch-spear/{spr_syscntl.h => syscntl.h} (100%)
diff --git a/arch/arm/cpu/arm926ejs/spear/cpu.c b/arch/arm/cpu/arm926ejs/spear/cpu.c
index 7f29514..1301608 100644
--- a/arch/arm/cpu/arm926ejs/spear/cpu.c
+++ b/arch/arm/cpu/arm926ejs/spear/cpu.c
@@ -24,7 +24,7 @@
#include <common.h>
#include <asm/io.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_misc.h>
+#include <asm/arch/misc.h>
int arch_cpu_init(void)
{
diff --git a/arch/arm/cpu/arm926ejs/spear/reset.c b/arch/arm/cpu/arm926ejs/spear/reset.c
index 73ad86d..cbefc50 100644
--- a/arch/arm/cpu/arm926ejs/spear/reset.c
+++ b/arch/arm/cpu/arm926ejs/spear/reset.c
@@ -24,7 +24,7 @@
#include <common.h>
#include <asm/io.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_syscntl.h>
+#include <asm/arch/syscntl.h>
void reset_cpu(ulong ignored)
{
diff --git a/arch/arm/cpu/arm926ejs/spear/spear600.c b/arch/arm/cpu/arm926ejs/spear/spear600.c
index ff52131..f4ec10a 100644
--- a/arch/arm/cpu/arm926ejs/spear/spear600.c
+++ b/arch/arm/cpu/arm926ejs/spear/spear600.c
@@ -25,8 +25,8 @@
#include <common.h>
#include <asm/hardware.h>
#include <asm/io.h>
-#include <asm/arch/spr_misc.h>
-#include <asm/arch/spr_defs.h>
+#include <asm/arch/misc.h>
+#include <asm/arch/generic.h>
#define FALSE 0
#define TRUE (!FALSE)
diff --git a/arch/arm/cpu/arm926ejs/spear/spl.c b/arch/arm/cpu/arm926ejs/spear/spl.c
index 77fe3a9..c0e01ea 100644
--- a/arch/arm/cpu/arm926ejs/spear/spl.c
+++ b/arch/arm/cpu/arm926ejs/spear/spl.c
@@ -27,9 +27,9 @@
#include <version.h>
#include <asm/io.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_defs.h>
-#include <asm/arch/spr_misc.h>
-#include <asm/arch/spr_syscntl.h>
+#include <asm/arch/generic.h>
+#include <asm/arch/misc.h>
+#include <asm/arch/syscntl.h>
inline void hang(void)
{
diff --git a/arch/arm/cpu/arm926ejs/spear/spl_boot.c b/arch/arm/cpu/arm926ejs/spear/spl_boot.c
index f2f9a49..c67774d 100644
--- a/arch/arm/cpu/arm926ejs/spear/spl_boot.c
+++ b/arch/arm/cpu/arm926ejs/spear/spl_boot.c
@@ -26,9 +26,10 @@
#include <common.h>
#include <image.h>
#include <linux/compiler.h>
-#include <asm/io.h>
-#include <asm/arch/spr_defs.h>
#include <linux/mtd/st_smi.h>
+#include <asm/io.h>
+#include <asm/arch/hardware.h>
+#include <asm/arch/generic.h>
static const char kernel_name[] = "Linux";
static const char loader_name[] = "U-Boot";
diff --git a/arch/arm/cpu/arm926ejs/spear/timer.c b/arch/arm/cpu/arm926ejs/spear/timer.c
index 25a4f62..af4660a 100644
--- a/arch/arm/cpu/arm926ejs/spear/timer.c
+++ b/arch/arm/cpu/arm926ejs/spear/timer.c
@@ -24,8 +24,8 @@
#include <common.h>
#include <asm/io.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_gpt.h>
-#include <asm/arch/spr_misc.h>
+#include <asm/arch/gpt.h>
+#include <asm/arch/misc.h>
#define GPT_RESOLUTION (CONFIG_SPEAR_HZ_CLOCK / CONFIG_SPEAR_HZ)
#define READ_TIMER() (readl(&gpt_regs_p->count) & GPT_FREE_RUNNING)
diff --git a/arch/arm/include/asm/arch-spear/clk.h b/arch/arm/include/asm/arch-spear/clk.h
index a45ec18..cdfbbec 100644
--- a/arch/arm/include/asm/arch-spear/clk.h
+++ b/arch/arm/include/asm/arch-spear/clk.h
@@ -21,7 +21,12 @@
* MA 02111-1307 USA
*/
+#ifndef ASM_ARCH_SPEAR_CLK_H
+#define ASM_ARCH_SPEAR_CLK_H
+
static inline unsigned long get_macb_pclk_rate(unsigned int dev_id)
{
return 83000000;
}
+
+#endif
diff --git a/arch/arm/include/asm/arch-spear/spr_emi.h b/arch/arm/include/asm/arch-spear/emi.h
similarity index 94%
rename from arch/arm/include/asm/arch-spear/spr_emi.h
rename to arch/arm/include/asm/arch-spear/emi.h
index c1f1c2a..bef15e9 100644
--- a/arch/arm/include/asm/arch-spear/spr_emi.h
+++ b/arch/arm/include/asm/arch-spear/emi.h
@@ -21,10 +21,8 @@
* MA 02111-1307 USA
*/
-#ifndef __SPEAR_EMI_H__
-#define __SPEAR_EMI_H__
-
-#ifdef CONFIG_SPEAR_EMI
+#ifndef ASM_ARCH_SPEAR_EMI_H
+#define ASM_ARCH_SPEAR_EMI_H
struct emi_bank_regs {
u32 tap;
@@ -50,5 +48,3 @@ struct emi_regs {
#define EMI_CNTL_ENBBYTERW (EMI_CNTL_ENBBYTER | EMI_CNTL_ENBBYTEW)
#endif
-
-#endif
diff --git a/arch/arm/include/asm/arch-spear/spr_defs.h b/arch/arm/include/asm/arch-spear/generic.h
similarity index 88%
rename from arch/arm/include/asm/arch-spear/spr_defs.h
rename to arch/arm/include/asm/arch-spear/generic.h
index 71d64a1..062571c 100644
--- a/arch/arm/include/asm/arch-spear/spr_defs.h
+++ b/arch/arm/include/asm/arch-spear/generic.h
@@ -21,15 +21,13 @@
* MA 02111-1307 USA
*/
-#ifndef __SPR_DEFS_H__
-#define __SPR_DEFS_H__
+#ifndef ASM_ARCH_SPEAR_GENERIC_H
+#define ASM_ARCH_SPEAR_GENERIC_H
-extern int spear_board_init(ulong);
+/* Routines exported from baord */
extern void setfreq(unsigned int, unsigned int);
extern unsigned int setfreq_sz;
-void plat_ddr_init(void);
-void soc_init(void);
void spear_late_init(void);
void plat_late_init(void);
@@ -45,13 +43,6 @@ int mmc_boot_selected(void);
extern u32 mpmc_conf_vals[];
-struct chip_data {
- int cpufreq;
- int dramfreq;
- int dramtype;
- uchar version[32];
-};
-
/* HW mac id in i2c memory definitions */
#define MAGIC_OFF 0x0
#define MAGIC_LEN 0x2
diff --git a/arch/arm/include/asm/arch-spear/spr_gpt.h b/arch/arm/include/asm/arch-spear/gpt.h
similarity index 97%
rename from arch/arm/include/asm/arch-spear/spr_gpt.h
rename to arch/arm/include/asm/arch-spear/gpt.h
index d95ba52..b4c618d 100644
--- a/arch/arm/include/asm/arch-spear/spr_gpt.h
+++ b/arch/arm/include/asm/arch-spear/gpt.h
@@ -21,8 +21,8 @@
* MA 02111-1307 USA
*/
-#ifndef _SPR_GPT_H
-#define _SPR_GPT_H
+#ifndef ASM_ARCH_SPEAR_GPT_H
+#define ASM_ARCH_SPEAR_GPT_H
struct gpt_regs {
u8 reserved[0x80];
diff --git a/arch/arm/include/asm/arch-spear/hardware.h b/arch/arm/include/asm/arch-spear/hardware.h
index 8150911..0b018bd 100644
--- a/arch/arm/include/asm/arch-spear/hardware.h
+++ b/arch/arm/include/asm/arch-spear/hardware.h
@@ -21,71 +21,17 @@
* MA 02111-1307 USA
*/
-#ifndef _ASM_ARCH_HARDWARE_H
-#define _ASM_ARCH_HARDWARE_H
-
-#define CONFIG_SYS_USBD_BASE 0xE1100000
-#define CONFIG_SYS_PLUG_BASE 0xE1200000
-#define CONFIG_SYS_FIFO_BASE 0xE1000800
-#define CONFIG_SYS_SMI_BASE 0xFC000000
-#define CONFIG_SPEAR_SYSCNTLBASE 0xFCA00000
-#define CONFIG_SPEAR_TIMERBASE 0xFC800000
-#define CONFIG_SPEAR_MISCBASE 0xFCA80000
-#define CONFIG_SPEAR_ETHBASE 0xE0800000
-#define CONFIG_SPEAR_MPMCBASE 0xFC600000
-#define CONFIG_SSP1_BASE 0xD0100000
-#define CONFIG_SSP2_BASE 0xD0180000
-#define CONFIG_SSP3_BASE 0xD8180000
-#define CONFIG_GPIO_BASE 0xD8100000
-
-#define CONFIG_SYS_NAND_CLE (1 << 16)
-#define CONFIG_SYS_NAND_ALE (1 << 17)
-
-#if defined(CONFIG_SPEAR600)
-#define CONFIG_SYS_I2C_BASE 0xD0200000
-#define CONFIG_SYS_FSMC_BASE 0xD1800000
-#define CONFIG_FSMC_NAND_BASE 0xD2000000
-
-#define CONFIG_SPEAR_BOOTSTRAPCFG 0xFCA80000
-#define CONFIG_SPEAR_BOOTSTRAPSHFT 16
-#define CONFIG_SPEAR_BOOTSTRAPMASK 0xB
-#define CONFIG_SPEAR_ONLYSNORBOOT 0xA
-#define CONFIG_SPEAR_NORNANDBOOT 0xB
-#define CONFIG_SPEAR_NORNAND8BOOT 0x8
-#define CONFIG_SPEAR_NORNAND16BOOT 0x9
-#define CONFIG_SPEAR_USBBOOT 0x8
-
-#define CONFIG_SPEAR_MPMCREGS 100
-
-#elif defined(CONFIG_SPEAR300)
-#define CONFIG_SYS_I2C_BASE 0xD0180000
-#define CONFIG_SYS_FSMC_BASE 0x94000000
-
-#elif defined(CONFIG_SPEAR310)
-#define CONFIG_SYS_I2C_BASE 0xD0180000
-#define CONFIG_SYS_FSMC_BASE 0x44000000
-
-#undef CONFIG_SYS_NAND_CLE
-#undef CONFIG_SYS_NAND_ALE
-#define CONFIG_SYS_NAND_CLE (1 << 17)
-#define CONFIG_SYS_NAND_ALE (1 << 16)
-
-#define CONFIG_SPEAR_EMIBASE 0x4F000000
-#define CONFIG_SPEAR_RASBASE 0xB4000000
-
-#define CONFIG_SYS_MACB0_BASE 0xB0000000
-#define CONFIG_SYS_MACB1_BASE 0xB0800000
-#define CONFIG_SYS_MACB2_BASE 0xB1000000
-#define CONFIG_SYS_MACB3_BASE 0xB1800000
-
-#elif defined(CONFIG_SPEAR320)
-#define CONFIG_SYS_I2C_BASE 0xD0180000
-#define CONFIG_SYS_FSMC_BASE 0x4C000000
-
-#define CONFIG_SPEAR_EMIBASE 0x40000000
-#define CONFIG_SPEAR_RASBASE 0xB3000000
-
-#define CONFIG_SYS_MACB0_BASE 0xAA000000
-
+#ifndef _ASM_ARCH_SPEAR_HARDWARE_H
+#define _ASM_ARCH_SPEAR_HARDWARE_H
+
+#if defined(CONFIG_SOC_SPEAR600)
+#include <asm/arch/spear600.h>
+#elif defined(CONFIG_SOC_SPEAR300)
+#include <asm/arch/spear300.h>
+#elif defined(CONFIG_SOC_SPEAR310)
+#include <asm/arch/spear310.h>
+#elif defined(CONFIG_SOC_SPEAR320)
+#include <asm/arch/spear320.h>
#endif
+
#endif /* _ASM_ARCH_HARDWARE_H */
diff --git a/arch/arm/include/asm/arch-spear/spr_misc.h b/arch/arm/include/asm/arch-spear/misc.h
similarity index 99%
rename from arch/arm/include/asm/arch-spear/spr_misc.h
rename to arch/arm/include/asm/arch-spear/misc.h
index b86296d..89f7964 100644
--- a/arch/arm/include/asm/arch-spear/spr_misc.h
+++ b/arch/arm/include/asm/arch-spear/misc.h
@@ -21,8 +21,8 @@
* MA 02111-1307 USA
*/
-#ifndef _SPR_MISC_H
-#define _SPR_MISC_H
+#ifndef ASM_ARCH_SPEAR_MISC_H
+#define ASM_ARCH_SPEAR_MISC_H
struct misc_regs {
u32 auto_cfg_reg; /* 0x0 */
diff --git a/arch/arm/include/asm/arch-spear/spr_ssp.h b/arch/arm/include/asm/arch-spear/spear300.h
similarity index 64%
rename from arch/arm/include/asm/arch-spear/spr_ssp.h
rename to arch/arm/include/asm/arch-spear/spear300.h
index 4f144ee..24faaea 100644
--- a/arch/arm/include/asm/arch-spear/spr_ssp.h
+++ b/arch/arm/include/asm/arch-spear/spear300.h
@@ -1,5 +1,6 @@
/*
- * Copyright (C) 2012 Stefan Roese <sr at denx.de>
+ * (C) Copyright 2012
+ * Vipin Kumar, STMicroelectronics, <vipin.kumar at st.com>
*
* See file CREDITS for list of people who contributed to this
* project.
@@ -11,7 +12,7 @@
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
@@ -20,26 +21,13 @@
* MA 02111-1307 USA
*/
-#ifndef _SPR_SSP_H
-#define _SPR_SSP_H
+#ifndef _ASM_ARCH_SPEAR300_H
+#define _ASM_ARCH_SPEAR300_H
-struct ssp_regs {
- u32 sspcr0;
- u32 sspcr1;
- u32 sspdr;
- u32 sspsr;
- u32 sspcpsr;
- u32 sspimsc;
- u32 sspicr;
- u32 sspdmacr;
-};
+#include <asm/arch/spear3xx.h>
-#define SSPCR0_FRF_MOT_SPI 0x0000
-#define SSPCR0_DSS_16BITS 0x000f
-
-#define SSPCR1_SSE 0x0002
-
-#define SSPSR_TNF 0x2
-#define SSPSR_TFE 0x1
+#define CONFIG_SYS_FSMC_BASE 0x94000000
+#define CONFIG_SYS_NAND_CLE (1 << 16)
+#define CONFIG_SYS_NAND_ALE (1 << 17)
#endif
diff --git a/arch/arm/include/asm/arch-spear/spear310.h b/arch/arm/include/asm/arch-spear/spear310.h
new file mode 100644
index 0000000..0f6223e
--- /dev/null
+++ b/arch/arm/include/asm/arch-spear/spear310.h
@@ -0,0 +1,40 @@
+/*
+ * (C) Copyright 2012
+ * Vipin Kumar, STMicroelectronics, <vipin.kumar at st.com>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+#ifndef _ASM_ARCH_SPEAR310_H
+#define _ASM_ARCH_SPEAR310_H
+
+#include <asm/arch/spear3xx.h>
+
+#define CONFIG_SYS_FSMC_BASE 0x44000000
+#define CONFIG_SYS_NAND_CLE (1 << 17)
+#define CONFIG_SYS_NAND_ALE (1 << 16)
+
+#define CONFIG_SPEAR_EMIBASE 0x4F000000
+#define CONFIG_SYS_MACB0_BASE 0xB0000000
+#define CONFIG_SYS_MACB1_BASE 0xB0800000
+#define CONFIG_SYS_MACB2_BASE 0xB1000000
+#define CONFIG_SYS_MACB3_BASE 0xB1800000
+#define CONFIG_SPEAR_RASBASE 0xB4000000
+
+#endif
diff --git a/arch/arm/include/asm/arch-spear/spear320.h b/arch/arm/include/asm/arch-spear/spear320.h
new file mode 100644
index 0000000..110afc3
--- /dev/null
+++ b/arch/arm/include/asm/arch-spear/spear320.h
@@ -0,0 +1,38 @@
+/*
+ * (C) Copyright 2012
+ * Vipin Kumar, STMicroelectronics, <vipin.kumar at st.com>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+#ifndef _ASM_ARCH_SPEAR320_H
+#define _ASM_ARCH_SPEAR320_H
+
+#include <asm/arch/spear3xx.h>
+
+#define CONFIG_SPEAR_EMIBASE 0x40000000
+#define CONFIG_SYS_FSMC_BASE 0x4C000000
+#define CONFIG_SYS_NAND_CLE (1 << 16)
+#define CONFIG_SYS_NAND_ALE (1 << 17)
+
+#define CONFIG_SYS_MACB0_BASE 0xAA000000
+#define CONFIG_SYS_MACB1_BASE 0xAB000000
+#define CONFIG_SPEAR_RASBASE 0xB3000000
+
+#endif
diff --git a/arch/arm/include/asm/arch-spear/spear3xx.h b/arch/arm/include/asm/arch-spear/spear3xx.h
new file mode 100644
index 0000000..e0a72f0
--- /dev/null
+++ b/arch/arm/include/asm/arch-spear/spear3xx.h
@@ -0,0 +1,40 @@
+/*
+ * (C) Copyright 2012
+ * Vipin Kumar, STMicroelectronics, <vipin.kumar at st.com>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+#ifndef _ASM_ARCH_SPEAR3XX_H
+#define _ASM_ARCH_SPEAR3XX_H
+
+#define CONFIG_SYS_I2C_BASE 0xD0180000
+#define CONFIG_GPIO_BASE 0xD8100000
+#define CONFIG_SPEAR_ETHBASE 0xE0800000
+#define CONFIG_SYS_FIFO_BASE 0xE1000800
+#define CONFIG_SYS_USBD_BASE 0xE1100000
+#define CONFIG_SYS_PLUG_BASE 0xE1200000
+#define CONFIG_SYS_UHC0_EHCI_BASE 0xE1800000
+#define CONFIG_SYS_SMI_BASE 0xFC000000
+#define CONFIG_SPEAR_MPMCBASE 0xFC600000
+#define CONFIG_SPEAR_TIMERBASE 0xFC800000
+#define CONFIG_SPEAR_SYSCNTLBASE 0xFCA00000
+#define CONFIG_SPEAR_MISCBASE 0xFCA80000
+
+#endif
diff --git a/arch/arm/include/asm/arch-spear/spear600.h b/arch/arm/include/asm/arch-spear/spear600.h
new file mode 100644
index 0000000..c8b0047
--- /dev/null
+++ b/arch/arm/include/asm/arch-spear/spear600.h
@@ -0,0 +1,45 @@
+/*
+ * (C) Copyright 2012
+ * Vipin Kumar, STMicroelectronics, <vipin.kumar at st.com>
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+#ifndef _ASM_ARCH_SPEAR600_H
+#define _ASM_ARCH_SPEAR600_H
+
+#define CONFIG_SYS_I2C_BASE 0xD0200000
+#define CONFIG_GPIO_BASE 0xD8100000
+#define CONFIG_SPEAR_ETHBASE 0xE0800000
+#define CONFIG_SYS_FIFO_BASE 0xE1000800
+#define CONFIG_SYS_USBD_BASE 0xE1100000
+#define CONFIG_SYS_PLUG_BASE 0xE1200000
+#define CONFIG_SYS_UHC0_EHCI_BASE 0xE1800000
+#define CONFIG_SYS_SMI_BASE 0xFC000000
+#define CONFIG_SPEAR_MPMCBASE 0xFC600000
+#define CONFIG_SPEAR_TIMERBASE 0xFC800000
+#define CONFIG_SPEAR_SYSCNTLBASE 0xFCA00000
+#define CONFIG_SPEAR_MISCBASE 0xFCA80000
+
+#define CONFIG_SYS_FSMC_BASE 0xD1800000
+#define CONFIG_FSMC_NAND_BASE 0xD2000000
+#define CONFIG_SYS_NAND_CLE (1 << 16)
+#define CONFIG_SYS_NAND_ALE (1 << 17)
+
+#endif
diff --git a/arch/arm/include/asm/arch-spear/spr_syscntl.h b/arch/arm/include/asm/arch-spear/syscntl.h
similarity index 100%
rename from arch/arm/include/asm/arch-spear/spr_syscntl.h
rename to arch/arm/include/asm/arch-spear/syscntl.h
diff --git a/board/spear/common/spr_misc.c b/board/spear/common/spr_misc.c
index 99a6595..df05ff2 100644
--- a/board/spear/common/spr_misc.c
+++ b/board/spear/common/spr_misc.c
@@ -28,8 +28,7 @@
#include <linux/mtd/st_smi.h>
#include <asm/io.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_emi.h>
-#include <asm/arch/spr_defs.h>
+#include <asm/arch/generic.h>
#define CPU 0
#define DDR 1
diff --git a/board/spear/spear300/spear300.c b/board/spear/spear300/spear300.c
index f809c2d..27a1697 100644
--- a/board/spear/spear300/spear300.c
+++ b/board/spear/spear300/spear300.c
@@ -28,8 +28,8 @@
#include <asm/io.h>
#include <linux/mtd/fsmc_nand.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_defs.h>
-#include <asm/arch/spr_misc.h>
+#include <asm/arch/generic.h>
+#include <asm/arch/misc.h>
static struct nand_chip nand_chip[CONFIG_SYS_MAX_NAND_DEVICE];
diff --git a/board/spear/spear310/spear310.c b/board/spear/spear310/spear310.c
index 8609a59..a1c45ae 100644
--- a/board/spear/spear310/spear310.c
+++ b/board/spear/spear310/spear310.c
@@ -29,8 +29,8 @@
#include <asm/io.h>
#include <linux/mtd/fsmc_nand.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_defs.h>
-#include <asm/arch/spr_misc.h>
+#include <asm/arch/generic.h>
+#include <asm/arch/misc.h>
static struct nand_chip nand_chip[CONFIG_SYS_MAX_NAND_DEVICE];
diff --git a/board/spear/spear320/spear320.c b/board/spear/spear320/spear320.c
index 54a2e10..82674f3 100644
--- a/board/spear/spear320/spear320.c
+++ b/board/spear/spear320/spear320.c
@@ -29,8 +29,8 @@
#include <asm/io.h>
#include <linux/mtd/fsmc_nand.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_defs.h>
-#include <asm/arch/spr_misc.h>
+#include <asm/arch/generic.h>
+#include <asm/arch/misc.h>
#define PLGPIO_SEL_36 0xb3000028
#define PLGPIO_IO_36 0xb3000038
diff --git a/board/spear/spear600/spear600.c b/board/spear/spear600/spear600.c
index 814f9cc..b4f013f 100644
--- a/board/spear/spear600/spear600.c
+++ b/board/spear/spear600/spear600.c
@@ -28,8 +28,8 @@
#include <asm/io.h>
#include <linux/mtd/fsmc_nand.h>
#include <asm/arch/hardware.h>
-#include <asm/arch/spr_defs.h>
-#include <asm/arch/spr_misc.h>
+#include <asm/arch/generic.h>
+#include <asm/arch/misc.h>
static struct nand_chip nand_chip[CONFIG_SYS_MAX_NAND_DEVICE];
--
1.7.11.4
More information about the U-Boot
mailing list