ARM: spear: remove include/mach/ subdirectory
authorArnd Bergmann <arnd@arndb.de>
Thu, 28 Apr 2022 07:44:23 +0000 (09:44 +0200)
committerArnd Bergmann <arnd@arndb.de>
Fri, 29 Apr 2022 07:53:15 +0000 (09:53 +0200)
Two of the remaining four headers are never used, the other
two are only used inside of the platform code. Move them
next to the files that include them and remove the
Makefile trick that adds the include path.

Acked-by: Viresh Kumar <viresh.kumar@linaro.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
17 files changed:
arch/arm/mach-spear/Makefile
arch/arm/mach-spear/include/mach/irqs.h [deleted file]
arch/arm/mach-spear/include/mach/misc_regs.h [deleted file]
arch/arm/mach-spear/include/mach/spear.h [deleted file]
arch/arm/mach-spear/include/mach/uncompress.h [deleted file]
arch/arm/mach-spear/misc_regs.h [new file with mode: 0644]
arch/arm/mach-spear/pl080.c
arch/arm/mach-spear/platsmp.c
arch/arm/mach-spear/restart.c
arch/arm/mach-spear/spear.h [new file with mode: 0644]
arch/arm/mach-spear/spear1310.c
arch/arm/mach-spear/spear13xx.c
arch/arm/mach-spear/spear300.c
arch/arm/mach-spear/spear310.c
arch/arm/mach-spear/spear320.c
arch/arm/mach-spear/spear3xx.c
arch/arm/mach-spear/spear6xx.c

index 176b14f83089c951c019c27a86c381e489075b32..c6101a843601bf072b248cc786570d22e93f7ec3 100644 (file)
@@ -3,8 +3,6 @@
 # SPEAr Platform specific Makefile
 #
 
-ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/$(src)/include
-
 # Common support
 obj-y  := restart.o time.o
 
diff --git a/arch/arm/mach-spear/include/mach/irqs.h b/arch/arm/mach-spear/include/mach/irqs.h
deleted file mode 100644 (file)
index 7058720..0000000
+++ /dev/null
@@ -1,35 +0,0 @@
-/*
- * IRQ helper macros for spear machine family
- *
- * Copyright (C) 2009-2012 ST Microelectronics
- * Rajeev Kumar <rajeev-dlh.kumar@st.com>
- * Viresh Kumar <vireshk@kernel.org>
- *
- * This file is licensed under the terms of the GNU General Public
- * License version 2. This program is licensed "as is" without any
- * warranty of any kind, whether express or implied.
- */
-
-#ifndef __MACH_IRQS_H
-#define __MACH_IRQS_H
-
-#ifdef CONFIG_ARCH_SPEAR3XX
-#define NR_IRQS                        256
-#endif
-
-#ifdef CONFIG_ARCH_SPEAR6XX
-/* IRQ definitions */
-/* VIC 1 */
-#define IRQ_VIC_END                            64
-
-/* GPIO pins virtual irqs */
-#define VIRTUAL_IRQS                           24
-#define NR_IRQS                                        (IRQ_VIC_END + VIRTUAL_IRQS)
-#endif
-
-#ifdef CONFIG_ARCH_SPEAR13XX
-#define IRQ_GIC_END                    160
-#define NR_IRQS                                IRQ_GIC_END
-#endif
-
-#endif /* __MACH_IRQS_H */
diff --git a/arch/arm/mach-spear/include/mach/misc_regs.h b/arch/arm/mach-spear/include/mach/misc_regs.h
deleted file mode 100644 (file)
index cfaf7c6..0000000
+++ /dev/null
@@ -1,22 +0,0 @@
-/*
- * arch/arm/mach-spear3xx/include/mach/misc_regs.h
- *
- * Miscellaneous registers definitions for SPEAr3xx machine family
- *
- * Copyright (C) 2009 ST Microelectronics
- * Viresh Kumar <vireshk@kernel.org>
- *
- * This file is licensed under the terms of the GNU General Public
- * License version 2. This program is licensed "as is" without any
- * warranty of any kind, whether express or implied.
- */
-
-#ifndef __MACH_MISC_REGS_H
-#define __MACH_MISC_REGS_H
-
-#include <mach/spear.h>
-
-#define MISC_BASE              (VA_SPEAR_ICM3_MISC_REG_BASE)
-#define DMA_CHN_CFG            (MISC_BASE + 0x0A0)
-
-#endif /* __MACH_MISC_REGS_H */
diff --git a/arch/arm/mach-spear/include/mach/spear.h b/arch/arm/mach-spear/include/mach/spear.h
deleted file mode 100644 (file)
index 5ed841c..0000000
+++ /dev/null
@@ -1,91 +0,0 @@
-/*
- * SPEAr3xx/6xx Machine family specific definition
- *
- * Copyright (C) 2009,2012 ST Microelectronics
- * Rajeev Kumar<rajeev-dlh.kumar@st.com>
- * Viresh Kumar <vireshk@kernel.org>
- *
- * This file is licensed under the terms of the GNU General Public
- * License version 2. This program is licensed "as is" without any
- * warranty of any kind, whether express or implied.
- */
-
-#ifndef __MACH_SPEAR_H
-#define __MACH_SPEAR_H
-
-#include <asm/memory.h>
-
-#if defined(CONFIG_ARCH_SPEAR3XX) || defined (CONFIG_ARCH_SPEAR6XX)
-
-/* ICM1 - Low speed connection */
-#define SPEAR_ICM1_2_BASE              UL(0xD0000000)
-#define VA_SPEAR_ICM1_2_BASE           IOMEM(0xFD000000)
-#define SPEAR_ICM1_UART_BASE           UL(0xD0000000)
-#define VA_SPEAR_ICM1_UART_BASE                (VA_SPEAR_ICM1_2_BASE - SPEAR_ICM1_2_BASE + SPEAR_ICM1_UART_BASE)
-#define SPEAR3XX_ICM1_SSP_BASE         UL(0xD0100000)
-
-/* ML-1, 2 - Multi Layer CPU Subsystem */
-#define SPEAR_ICM3_ML1_2_BASE          UL(0xF0000000)
-#define VA_SPEAR6XX_ML_CPU_BASE                IOMEM(0xF0000000)
-
-/* ICM3 - Basic Subsystem */
-#define SPEAR_ICM3_SMI_CTRL_BASE       UL(0xFC000000)
-#define VA_SPEAR_ICM3_SMI_CTRL_BASE    IOMEM(0xFC000000)
-#define SPEAR_ICM3_DMA_BASE            UL(0xFC400000)
-#define SPEAR_ICM3_SYS_CTRL_BASE       UL(0xFCA00000)
-#define VA_SPEAR_ICM3_SYS_CTRL_BASE    (VA_SPEAR_ICM3_SMI_CTRL_BASE - SPEAR_ICM3_SMI_CTRL_BASE + SPEAR_ICM3_SYS_CTRL_BASE)
-#define SPEAR_ICM3_MISC_REG_BASE       UL(0xFCA80000)
-#define VA_SPEAR_ICM3_MISC_REG_BASE    (VA_SPEAR_ICM3_SMI_CTRL_BASE - SPEAR_ICM3_SMI_CTRL_BASE + SPEAR_ICM3_MISC_REG_BASE)
-
-/* Debug uart for linux, will be used for debug and uncompress messages */
-#define SPEAR_DBG_UART_BASE            SPEAR_ICM1_UART_BASE
-
-/* Sysctl base for spear platform */
-#define SPEAR_SYS_CTRL_BASE            SPEAR_ICM3_SYS_CTRL_BASE
-#define VA_SPEAR_SYS_CTRL_BASE         VA_SPEAR_ICM3_SYS_CTRL_BASE
-#endif /* SPEAR3xx || SPEAR6XX */
-
-/* SPEAr320 Macros */
-#define SPEAR320_SOC_CONFIG_BASE       UL(0xB3000000)
-#define VA_SPEAR320_SOC_CONFIG_BASE    IOMEM(0xFE000000)
-
-#ifdef CONFIG_ARCH_SPEAR13XX
-
-#define PERIP_GRP2_BASE                                UL(0xB3000000)
-#define VA_PERIP_GRP2_BASE                     IOMEM(0xF9000000)
-#define MCIF_SDHCI_BASE                                UL(0xB3000000)
-#define SYSRAM0_BASE                           UL(0xB3800000)
-#define VA_SYSRAM0_BASE                                IOMEM(0xF9800000)
-#define SYS_LOCATION                           (VA_SYSRAM0_BASE + 0x600)
-
-#define PERIP_GRP1_BASE                                UL(0xE0000000)
-#define VA_PERIP_GRP1_BASE                     IOMEM(0xFD000000)
-#define UART_BASE                              UL(0xE0000000)
-#define VA_UART_BASE                           IOMEM(0xFD000000)
-#define SSP_BASE                               UL(0xE0100000)
-#define MISC_BASE                              UL(0xE0700000)
-#define VA_MISC_BASE                           IOMEM(0xFD700000)
-
-#define A9SM_AND_MPMC_BASE                     UL(0xEC000000)
-#define VA_A9SM_AND_MPMC_BASE                  IOMEM(0xFC000000)
-
-#define SPEAR1310_RAS_BASE                     UL(0xD8400000)
-#define VA_SPEAR1310_RAS_BASE                  IOMEM(UL(0xFA400000))
-
-/* A9SM peripheral offsets */
-#define A9SM_PERIP_BASE                                UL(0xEC800000)
-#define VA_A9SM_PERIP_BASE                     IOMEM(0xFC800000)
-#define VA_SCU_BASE                            (VA_A9SM_PERIP_BASE + 0x00)
-
-#define L2CC_BASE                              UL(0xED000000)
-#define VA_L2CC_BASE                           IOMEM(UL(0xFB000000))
-
-/* others */
-#define MCIF_CF_BASE                           UL(0xB2800000)
-
-/* Debug uart for linux, will be used for debug and uncompress messages */
-#define SPEAR_DBG_UART_BASE                    UART_BASE
-
-#endif /* SPEAR13XX */
-
-#endif /* __MACH_SPEAR_H */
diff --git a/arch/arm/mach-spear/include/mach/uncompress.h b/arch/arm/mach-spear/include/mach/uncompress.h
deleted file mode 100644 (file)
index 8439b9c..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-/*
- * arch/arm/plat-spear/include/plat/uncompress.h
- *
- * Serial port stubs for kernel decompress status messages
- *
- * Copyright (C) 2009 ST Microelectronics
- * Viresh Kumar <vireshk@kernel.org>
- *
- * This file is licensed under the terms of the GNU General Public
- * License version 2. This program is licensed "as is" without any
- * warranty of any kind, whether express or implied.
- */
-
-#include <linux/io.h>
-#include <linux/amba/serial.h>
-#include <mach/spear.h>
-
-#ifndef __PLAT_UNCOMPRESS_H
-#define __PLAT_UNCOMPRESS_H
-/*
- * This does not append a newline
- */
-static inline void putc(int c)
-{
-       void __iomem *base = (void __iomem *)SPEAR_DBG_UART_BASE;
-
-       while (readl_relaxed(base + UART01x_FR) & UART01x_FR_TXFF)
-               barrier();
-
-       writel_relaxed(c, base + UART01x_DR);
-}
-
-static inline void flush(void)
-{
-}
-
-/*
- * nothing to do
- */
-#define arch_decomp_setup()
-
-#endif /* __PLAT_UNCOMPRESS_H */
diff --git a/arch/arm/mach-spear/misc_regs.h b/arch/arm/mach-spear/misc_regs.h
new file mode 100644 (file)
index 0000000..53cd743
--- /dev/null
@@ -0,0 +1,20 @@
+/*
+ * Miscellaneous registers definitions for SPEAr3xx machine family
+ *
+ * Copyright (C) 2009 ST Microelectronics
+ * Viresh Kumar <vireshk@kernel.org>
+ *
+ * This file is licensed under the terms of the GNU General Public
+ * License version 2. This program is licensed "as is" without any
+ * warranty of any kind, whether express or implied.
+ */
+
+#ifndef __MACH_MISC_REGS_H
+#define __MACH_MISC_REGS_H
+
+#include "spear.h"
+
+#define MISC_BASE              (VA_SPEAR_ICM3_MISC_REG_BASE)
+#define DMA_CHN_CFG            (MISC_BASE + 0x0A0)
+
+#endif /* __MACH_MISC_REGS_H */
index b4529f3e0ee976b784e59fdd5ff2d45f64283cbf..38b479f413dc4d454c2e5da08f371ddd0dde4f81 100644 (file)
@@ -17,8 +17,8 @@
 #include <linux/err.h>
 #include <linux/io.h>
 #include <linux/spinlock_types.h>
-#include <mach/spear.h>
-#include <mach/misc_regs.h>
+#include "spear.h"
+#include "misc_regs.h"
 
 static spinlock_t lock = __SPIN_LOCK_UNLOCKED(x);
 
index e33a85c28c9590907ce149792c93c0406eb39dce..97fbda998df9302c3a1b4f1cc2b6b58f1c99ddeb 100644 (file)
@@ -14,7 +14,7 @@
 #include <linux/smp.h>
 #include <asm/cacheflush.h>
 #include <asm/smp_scu.h>
-#include <mach/spear.h>
+#include "spear.h"
 #include "generic.h"
 
 /* XXX spear_pen_release is cargo culted code - DO NOT COPY XXX */
index b4342155a7833eb350cf668a1ce645f20a7b091e..43417d0db6d96c2d2d4c685417562bf4fed71ed9 100644 (file)
@@ -14,7 +14,7 @@
 #include <linux/amba/sp810.h>
 #include <linux/reboot.h>
 #include <asm/system_misc.h>
-#include <mach/spear.h>
+#include "spear.h"
 #include "generic.h"
 
 #define SPEAR13XX_SYS_SW_RES                   (VA_MISC_BASE + 0x204)
diff --git a/arch/arm/mach-spear/spear.h b/arch/arm/mach-spear/spear.h
new file mode 100644 (file)
index 0000000..5ed841c
--- /dev/null
@@ -0,0 +1,91 @@
+/*
+ * SPEAr3xx/6xx Machine family specific definition
+ *
+ * Copyright (C) 2009,2012 ST Microelectronics
+ * Rajeev Kumar<rajeev-dlh.kumar@st.com>
+ * Viresh Kumar <vireshk@kernel.org>
+ *
+ * This file is licensed under the terms of the GNU General Public
+ * License version 2. This program is licensed "as is" without any
+ * warranty of any kind, whether express or implied.
+ */
+
+#ifndef __MACH_SPEAR_H
+#define __MACH_SPEAR_H
+
+#include <asm/memory.h>
+
+#if defined(CONFIG_ARCH_SPEAR3XX) || defined (CONFIG_ARCH_SPEAR6XX)
+
+/* ICM1 - Low speed connection */
+#define SPEAR_ICM1_2_BASE              UL(0xD0000000)
+#define VA_SPEAR_ICM1_2_BASE           IOMEM(0xFD000000)
+#define SPEAR_ICM1_UART_BASE           UL(0xD0000000)
+#define VA_SPEAR_ICM1_UART_BASE                (VA_SPEAR_ICM1_2_BASE - SPEAR_ICM1_2_BASE + SPEAR_ICM1_UART_BASE)
+#define SPEAR3XX_ICM1_SSP_BASE         UL(0xD0100000)
+
+/* ML-1, 2 - Multi Layer CPU Subsystem */
+#define SPEAR_ICM3_ML1_2_BASE          UL(0xF0000000)
+#define VA_SPEAR6XX_ML_CPU_BASE                IOMEM(0xF0000000)
+
+/* ICM3 - Basic Subsystem */
+#define SPEAR_ICM3_SMI_CTRL_BASE       UL(0xFC000000)
+#define VA_SPEAR_ICM3_SMI_CTRL_BASE    IOMEM(0xFC000000)
+#define SPEAR_ICM3_DMA_BASE            UL(0xFC400000)
+#define SPEAR_ICM3_SYS_CTRL_BASE       UL(0xFCA00000)
+#define VA_SPEAR_ICM3_SYS_CTRL_BASE    (VA_SPEAR_ICM3_SMI_CTRL_BASE - SPEAR_ICM3_SMI_CTRL_BASE + SPEAR_ICM3_SYS_CTRL_BASE)
+#define SPEAR_ICM3_MISC_REG_BASE       UL(0xFCA80000)
+#define VA_SPEAR_ICM3_MISC_REG_BASE    (VA_SPEAR_ICM3_SMI_CTRL_BASE - SPEAR_ICM3_SMI_CTRL_BASE + SPEAR_ICM3_MISC_REG_BASE)
+
+/* Debug uart for linux, will be used for debug and uncompress messages */
+#define SPEAR_DBG_UART_BASE            SPEAR_ICM1_UART_BASE
+
+/* Sysctl base for spear platform */
+#define SPEAR_SYS_CTRL_BASE            SPEAR_ICM3_SYS_CTRL_BASE
+#define VA_SPEAR_SYS_CTRL_BASE         VA_SPEAR_ICM3_SYS_CTRL_BASE
+#endif /* SPEAR3xx || SPEAR6XX */
+
+/* SPEAr320 Macros */
+#define SPEAR320_SOC_CONFIG_BASE       UL(0xB3000000)
+#define VA_SPEAR320_SOC_CONFIG_BASE    IOMEM(0xFE000000)
+
+#ifdef CONFIG_ARCH_SPEAR13XX
+
+#define PERIP_GRP2_BASE                                UL(0xB3000000)
+#define VA_PERIP_GRP2_BASE                     IOMEM(0xF9000000)
+#define MCIF_SDHCI_BASE                                UL(0xB3000000)
+#define SYSRAM0_BASE                           UL(0xB3800000)
+#define VA_SYSRAM0_BASE                                IOMEM(0xF9800000)
+#define SYS_LOCATION                           (VA_SYSRAM0_BASE + 0x600)
+
+#define PERIP_GRP1_BASE                                UL(0xE0000000)
+#define VA_PERIP_GRP1_BASE                     IOMEM(0xFD000000)
+#define UART_BASE                              UL(0xE0000000)
+#define VA_UART_BASE                           IOMEM(0xFD000000)
+#define SSP_BASE                               UL(0xE0100000)
+#define MISC_BASE                              UL(0xE0700000)
+#define VA_MISC_BASE                           IOMEM(0xFD700000)
+
+#define A9SM_AND_MPMC_BASE                     UL(0xEC000000)
+#define VA_A9SM_AND_MPMC_BASE                  IOMEM(0xFC000000)
+
+#define SPEAR1310_RAS_BASE                     UL(0xD8400000)
+#define VA_SPEAR1310_RAS_BASE                  IOMEM(UL(0xFA400000))
+
+/* A9SM peripheral offsets */
+#define A9SM_PERIP_BASE                                UL(0xEC800000)
+#define VA_A9SM_PERIP_BASE                     IOMEM(0xFC800000)
+#define VA_SCU_BASE                            (VA_A9SM_PERIP_BASE + 0x00)
+
+#define L2CC_BASE                              UL(0xED000000)
+#define VA_L2CC_BASE                           IOMEM(UL(0xFB000000))
+
+/* others */
+#define MCIF_CF_BASE                           UL(0xB2800000)
+
+/* Debug uart for linux, will be used for debug and uncompress messages */
+#define SPEAR_DBG_UART_BASE                    UART_BASE
+
+#endif /* SPEAR13XX */
+
+#endif /* __MACH_SPEAR_H */
index a7d4f136836fa8ffff60b8cb58e028e6283cc8ca..549ab2be1b744f00799679055891818d5e417cc2 100644 (file)
@@ -18,7 +18,7 @@
 #include <asm/mach/arch.h>
 #include <asm/mach/map.h>
 #include "generic.h"
-#include <mach/spear.h>
+#include "spear.h"
 
 /* Base addresses */
 #define SPEAR1310_RAS_GRP1_BASE                        UL(0xD8000000)
index b38391e9d8bfea3ec4ff52b170b4c6caf0c06676..9d4bdce2e865cd169af7896f7832219b9ea48bf0 100644 (file)
@@ -21,7 +21,7 @@
 #include <linux/of.h>
 #include <asm/hardware/cache-l2x0.h>
 #include <asm/mach/map.h>
-#include <mach/spear.h>
+#include "spear.h"
 #include "generic.h"
 
 void __init spear13xx_l2x0_init(void)
index 325b89579be105b4abe626f5b9086c727fd3d950..1f2a6bbcf096f2bbe7e0a52669f7c621f503eb76 100644 (file)
@@ -17,7 +17,7 @@
 #include <linux/of_platform.h>
 #include <asm/mach/arch.h>
 #include "generic.h"
-#include <mach/spear.h>
+#include "spear.h"
 
 /* DMAC platform data's slave info */
 struct pl08x_channel_data spear300_dma_info[] = {
index 59e173dc85cf317e5fd39ccde6f79826b4e96515..f0fc140a59cfee625008cc8f0d973d4c986e1aa3 100644 (file)
@@ -18,7 +18,7 @@
 #include <linux/of_platform.h>
 #include <asm/mach/arch.h>
 #include "generic.h"
-#include <mach/spear.h>
+#include "spear.h"
 
 #define SPEAR310_UART1_BASE            UL(0xB2000000)
 #define SPEAR310_UART2_BASE            UL(0xB2080000)
index 926d5a243238af92ea5705bc79390db25ee8cb5f..cb464ae7c08a17efbe0ffa1c08873e8d44e323ba 100644 (file)
@@ -20,7 +20,7 @@
 #include <asm/mach/arch.h>
 #include <asm/mach/map.h>
 #include "generic.h"
-#include <mach/spear.h>
+#include "spear.h"
 
 #define SPEAR320_UART1_BASE            UL(0xA3000000)
 #define SPEAR320_UART2_BASE            UL(0xA4000000)
index f83321d5e35383365940d35660277a3ef66de81a..fab3d6df69ffb2e6278b6aafab054be201486941 100644 (file)
@@ -20,8 +20,8 @@
 #include <asm/mach/map.h>
 #include "pl080.h"
 #include "generic.h"
-#include <mach/spear.h>
-#include <mach/misc_regs.h>
+#include "spear.h"
+#include "misc_regs.h"
 
 /* ssp device registration */
 struct pl022_ssp_controller pl022_plat_data = {
index c5fc110134ba66950664f7e17d0940a947047adc..d061080b191f79a309a2ba092fa981b7856ba621 100644 (file)
@@ -25,8 +25,8 @@
 #include <asm/mach/map.h>
 #include "pl080.h"
 #include "generic.h"
-#include <mach/spear.h>
-#include <mach/misc_regs.h>
+#include "spear.h"
+#include "misc_regs.h"
 
 /* dmac device registration */
 static struct pl08x_channel_data spear600_dma_info[] = {