Skip to contentSkip to conversation

ARM: omap/davinci/spear fixes for multiplatform

PATCH In review Arnd Bergmann 4 participants 13 messages Apr 28, 2022 – May 2, 2022

Subsystems (6)
lore
Share & tools
lore
#0 lore raw

cover ARM: omap/davinci/spear fixes for multiplatform

From: Arnd Bergmann <[email protected]>

I got a few emails about (harmless) warnings and one build failure or my pending omap1 multiplatform changes. I fixed them up here, and added three more patches to move the platform headers from the now obsolete include/mach/ subdir into the corresponding platforms where this was not already done.

I already have these in the arm/multiplatform branch of the soc tree, and if everyone is happy with the changes, I'll just merge this into the for-next branch.

Arnd

Arnd Bergmann (6):
ARM: omap2: remove include/mach/ subdirectory
ARM: davinci: remove include/mach/ subdirectory
ARM: spear: remove include/mach/ subdirectory
ARM: omap: fix address space warnings from sparse
ARM: omap2: fix missing declaration warnings
ARM: omap1: add back omap_set_dma_priority() stub

 arch/arm/mach-davinci/Makefile                |   4 +-
 arch/arm/mach-davinci/board-da830-evm.c       |   7 +-
 arch/arm/mach-davinci/board-da850-evm.c       |   7 +-
 arch/arm/mach-davinci/board-dm355-evm.c       |   5 +-
 arch/arm/mach-davinci/board-dm355-leopard.c   |   5 +-
 arch/arm/mach-davinci/board-dm365-evm.c       |   6 +-
 arch/arm/mach-davinci/board-dm644x-evm.c      |   7 +-
 arch/arm/mach-davinci/board-dm646x-evm.c      |   5 +-
 arch/arm/mach-davinci/board-mityomapl138.c    |   8 +-
 arch/arm/mach-davinci/board-neuros-osd2.c     |   7 +-
 arch/arm/mach-davinci/board-omapl138-hawk.c   |   6 +-
 arch/arm/mach-davinci/board-sffsdr.c          |   6 +-
 arch/arm/mach-davinci/common.c                |   4 +-
 .../mach-davinci/{include/mach => }/common.h  |   0
 .../mach-davinci/{include/mach => }/cputype.h |   2 +-
 arch/arm/mach-davinci/da830.c                 |  11 +-
 arch/arm/mach-davinci/da850.c                 |  12 +-
 arch/arm/mach-davinci/da8xx-dt.c              |   4 +-
 .../mach-davinci/{include/mach => }/da8xx.h   |   5 +-
 arch/arm/mach-davinci/davinci.h               |   3 +-
 arch/arm/mach-davinci/devices-da8xx.c         |   7 +-
 arch/arm/mach-davinci/devices.c               |   7 +-
 arch/arm/mach-davinci/dm355.c                 |  12 +-
 arch/arm/mach-davinci/dm365.c                 |  12 +-
 arch/arm/mach-davinci/dm644x.c                |  12 +-
 arch/arm/mach-davinci/dm646x.c                |  12 +-
 .../{include/mach => }/hardware.h             |   0
 arch/arm/mach-davinci/include/mach/mux.h      | 990 ------------------
 .../mach-davinci/include/mach/uncompress.h    |  97 --
 arch/arm/mach-davinci/mux.c                   |   4 +-
 arch/arm/mach-davinci/mux.h                   | 969 ++++++++++++++++-
 arch/arm/mach-davinci/pdata-quirks.c          |   4 +-
 arch/arm/mach-davinci/pm.c                    |   9 +-
 arch/arm/mach-davinci/{include/mach => }/pm.h |   0
 arch/arm/mach-davinci/serial.c                |   4 +-
 .../mach-davinci/{include/mach => }/serial.h  |   2 +-
 arch/arm/mach-davinci/sram.c                  |   2 +-
 arch/arm/mach-davinci/usb-da8xx.c             |   7 +-
 arch/arm/mach-davinci/usb.c                   |   5 +-
 arch/arm/mach-omap1/board-ams-delta.c         |   2 +-
 arch/arm/mach-omap1/fb.c                      |   2 +-
 arch/arm/mach-omap1/i2c.c                     |   1 +
 arch/arm/mach-omap1/omap-dma.c                |  18 +-
 arch/arm/mach-omap1/sram-init.c               |   2 +-
 arch/arm/mach-omap1/timer32k.c                |   2 +-
 arch/arm/mach-omap2/Makefile                  |   3 -
 arch/arm/mach-omap2/common.h                  |  13 +-
 arch/arm/mach-omap2/dma.c                     |   1 +
 arch/arm/mach-omap2/include/mach/hardware.h   |   3 -
 arch/arm/mach-omap2/include/mach/irqs.h       |   3 -
 arch/arm/mach-omap2/include/mach/serial.h     |  66 --
 arch/arm/mach-omap2/omap-iommu.c              |   1 +
 arch/arm/mach-omap2/pdata-quirks.c            |  11 -
 arch/arm/mach-omap2/serial.h                  |  67 +-
 arch/arm/mach-spear/Makefile                  |   2 -
 arch/arm/mach-spear/include/mach/irqs.h       |  35 -
 arch/arm/mach-spear/include/mach/uncompress.h |  42 -
 .../mach-spear/{include/mach => }/misc_regs.h |   4 +-
 arch/arm/mach-spear/pl080.c                   |   4 +-
 arch/arm/mach-spear/platsmp.c                 |   2 +-
 arch/arm/mach-spear/restart.c                 |   2 +-
 .../arm/mach-spear/{include/mach => }/spear.h |   0
 arch/arm/mach-spear/spear1310.c               |   2 +-
 arch/arm/mach-spear/spear13xx.c               |   2 +-
 arch/arm/mach-spear/spear300.c                |   2 +-
 arch/arm/mach-spear/spear310.c                |   2 +-
 arch/arm/mach-spear/spear320.c                |   2 +-
 arch/arm/mach-spear/spear3xx.c                |   4 +-
 arch/arm/mach-spear/spear6xx.c                |   4 +-
 include/linux/omap-dma.h                      |   7 +
 70 files changed, 1172 insertions(+), 1408 deletions(-)
 rename arch/arm/mach-davinci/{include/mach => }/common.h (100%)
 rename arch/arm/mach-davinci/{include/mach => }/cputype.h (98%)
 rename arch/arm/mach-davinci/{include/mach => }/da8xx.h (99%)
 rename arch/arm/mach-davinci/{include/mach => }/hardware.h (100%)
 delete mode 100644 arch/arm/mach-davinci/include/mach/mux.h
 delete mode 100644 arch/arm/mach-davinci/include/mach/uncompress.h
 rename arch/arm/mach-davinci/{include/mach => }/pm.h (100%)
 rename arch/arm/mach-davinci/{include/mach => }/serial.h (97%)
 delete mode 100644 arch/arm/mach-omap2/include/mach/hardware.h
 delete mode 100644 arch/arm/mach-omap2/include/mach/irqs.h
 delete mode 100644 arch/arm/mach-omap2/include/mach/serial.h
 delete mode 100644 arch/arm/mach-spear/include/mach/irqs.h
 delete mode 100644 arch/arm/mach-spear/include/mach/uncompress.h
 rename arch/arm/mach-spear/{include/mach => }/misc_regs.h (87%)
 rename arch/arm/mach-spear/{include/mach => }/spear.h (100%)
Signature · 1 line
2.29.2
#1 lore raw

PATCH 1/6 ARM: omap2: remove include/mach/ subdirectory

From: Arnd Bergmann <[email protected]>

mach/serial.h is only included from arch/arm/mach-omap2/serial.h, and the other two files are unused and empty.

Remove the directory by relocating the contents of mach/serial.h and dropping all other references.

---
 arch/arm/mach-omap2/Makefile                |  3 -
 arch/arm/mach-omap2/include/mach/hardware.h |  3 -
 arch/arm/mach-omap2/include/mach/irqs.h     |  3 -
 arch/arm/mach-omap2/include/mach/serial.h   | 66 --------------------
 arch/arm/mach-omap2/serial.h                | 67 ++++++++++++++++++++-
 5 files changed, 66 insertions(+), 76 deletions(-)
 delete mode 100644 arch/arm/mach-omap2/include/mach/hardware.h
 delete mode 100644 arch/arm/mach-omap2/include/mach/irqs.h
 delete mode 100644 arch/arm/mach-omap2/include/mach/serial.h
arch/arm/mach-omap2/Makefile +0 -3
index 8306ad686bc8..2feb9f6630af 100644
@@ -3,9 +3,6 @@
 # Makefile for the linux kernel.
 #
 
-ccflags-y := -I$(srctree)/$(src)/include \
-	-I$(srctree)/arch/arm/plat-omap/include
-
 # Common support
 obj-y := id.o io.o control.o devices.o fb.o pm.o \
 	 common.o dma.o omap-headsmp.o sram.o
arch/arm/mach-omap2/include/mach/hardware.h deleted +0 -3
deleted file mode 100644
index 54492dbf6973..000000000000
@@ -1,3 +0,0 @@
-/*
- * arch/arm/mach-omap2/include/mach/hardware.h
- */
arch/arm/mach-omap2/include/mach/irqs.h deleted +0 -3
deleted file mode 100644
index ba5282cafa42..000000000000
@@ -1,3 +0,0 @@
-/*
- * arch/arm/mach-omap2/include/mach/irqs.h
- */
arch/arm/mach-omap2/include/mach/serial.h deleted +0 -66

66 lines not on this page · raw message

arch/arm/mach-omap2/serial.h +66 -1

67 lines not on this page · raw message

Signature · 1 line
2.29.2
maintainer Reviewed-by Tested-by on v1 1/6
#2 lore raw

Re: [PATCH 1/6] ARM: omap2: remove include/mach/ subdirectory

Quoted 7 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

mach/serial.h is only included from arch/arm/mach-omap2/serial.h, and the other two files are unused and empty.

Remove the directory by relocating the contents of mach/serial.h and dropping all other references.

#3 lore raw

PATCH 2/6 ARM: davinci: remove include/mach/ subdirectory

In reply to Arnd Bergmann

From: Arnd Bergmann <[email protected]>

The files in include/mach are only used from mach/davinci, so they are no longer needed in the traditional location.

Move them to arch/arm/mach-davinci/ and drop the logic for the special include path.

The mach/uncompress.h file is not used at all and can just be removed.

---
 arch/arm/mach-davinci/Makefile                |   4 +-
 arch/arm/mach-davinci/board-da830-evm.c       |   7 +-
 arch/arm/mach-davinci/board-da850-evm.c       |   7 +-
 arch/arm/mach-davinci/board-dm355-evm.c       |   5 +-
 arch/arm/mach-davinci/board-dm355-leopard.c   |   5 +-
 arch/arm/mach-davinci/board-dm365-evm.c       |   6 +-
 arch/arm/mach-davinci/board-dm644x-evm.c      |   7 +-
 arch/arm/mach-davinci/board-dm646x-evm.c      |   5 +-
 arch/arm/mach-davinci/board-mityomapl138.c    |   8 +-
 arch/arm/mach-davinci/board-neuros-osd2.c     |   7 +-
 arch/arm/mach-davinci/board-omapl138-hawk.c   |   6 +-
 arch/arm/mach-davinci/board-sffsdr.c          |   6 +-
 arch/arm/mach-davinci/common.c                |   4 +-
 .../mach-davinci/{include/mach => }/common.h  |   0
 .../mach-davinci/{include/mach => }/cputype.h |   2 +-
 arch/arm/mach-davinci/da830.c                 |  11 +-
 arch/arm/mach-davinci/da850.c                 |  12 +-
 arch/arm/mach-davinci/da8xx-dt.c              |   4 +-
 .../mach-davinci/{include/mach => }/da8xx.h   |   5 +-
 arch/arm/mach-davinci/davinci.h               |   3 +-
 arch/arm/mach-davinci/devices-da8xx.c         |   7 +-
 arch/arm/mach-davinci/devices.c               |   7 +-
 arch/arm/mach-davinci/dm355.c                 |  12 +-
 arch/arm/mach-davinci/dm365.c                 |  12 +-
 arch/arm/mach-davinci/dm644x.c                |  12 +-
 arch/arm/mach-davinci/dm646x.c                |  12 +-
 .../{include/mach => }/hardware.h             |   0
 arch/arm/mach-davinci/include/mach/mux.h      | 990 ------------------
 .../mach-davinci/include/mach/uncompress.h    |  97 --
 arch/arm/mach-davinci/mux.c                   |   4 +-
 arch/arm/mach-davinci/mux.h                   | 969 ++++++++++++++++-
 arch/arm/mach-davinci/pdata-quirks.c          |   4 +-
 arch/arm/mach-davinci/pm.c                    |   9 +-
 arch/arm/mach-davinci/{include/mach => }/pm.h |   0
 arch/arm/mach-davinci/serial.c                |   4 +-
 .../mach-davinci/{include/mach => }/serial.h  |   2 +-
 arch/arm/mach-davinci/sram.c                  |   2 +-
 arch/arm/mach-davinci/usb-da8xx.c             |   7 +-
 arch/arm/mach-davinci/usb.c                   |   5 +-
 39 files changed, 1064 insertions(+), 1205 deletions(-)
 rename arch/arm/mach-davinci/{include/mach => }/common.h (100%)
 rename arch/arm/mach-davinci/{include/mach => }/cputype.h (98%)
 rename arch/arm/mach-davinci/{include/mach => }/da8xx.h (99%)
 rename arch/arm/mach-davinci/{include/mach => }/hardware.h (100%)
 delete mode 100644 arch/arm/mach-davinci/include/mach/mux.h
 delete mode 100644 arch/arm/mach-davinci/include/mach/uncompress.h
 rename arch/arm/mach-davinci/{include/mach => }/pm.h (100%)
 rename arch/arm/mach-davinci/{include/mach => }/serial.h (97%)
arch/arm/mach-davinci/Makefile +1 -3
index 58838a9de651..b04c084b707e 100644
@@ -3,9 +3,7 @@
 # Makefile for the linux kernel.
 #
 #
-
-ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/$(src)/include
-
+#
 # Common objects
 obj-y 					:= serial.o usb.o common.o sram.o
 
arch/arm/mach-davinci/board-da830-evm.c +3 -4
index 823c9cc98f18..86a037d629bb 100644
@@ -36,10 +36,9 @@
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include <mach/common.h>
-#include <mach/mux.h>
-#include <mach/da8xx.h>
-
+#include "common.h"
+#include "mux.h"
+#include "da8xx.h"
 #include "irqs.h"
 
 #define DA830_EVM_PHY_ID		""
arch/arm/mach-davinci/board-da850-evm.c +3 -4
index 428012687a80..f4df5eceb9be 100644
@@ -43,10 +43,9 @@
 #include <linux/spi/spi.h>
 #include <linux/spi/flash.h>
 
-#include <mach/common.h>
-#include <mach/da8xx.h>
-#include <mach/mux.h>
-
+#include "common.h"
+#include "da8xx.h"
+#include "mux.h"
 #include "irqs.h"
 #include "sram.h"
 
arch/arm/mach-davinci/board-dm355-evm.c +2 -3
index 3c5a9e3c128a..f7c56f662d4c 100644
@@ -33,9 +33,8 @@
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include <mach/serial.h>
-#include <mach/common.h>
-
+#include "serial.h"
+#include "common.h"
 #include "davinci.h"
 
 /* NOTE:  this is geared for the standard config, with a socketed
arch/arm/mach-davinci/board-dm355-leopard.c +2 -3
index e475b2113e70..0f2b61266197 100644
@@ -27,9 +27,8 @@
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include <mach/common.h>
-#include <mach/serial.h>
-
+#include "common.h"
+#include "serial.h"
 #include "davinci.h"
 
 /* NOTE:  this is geared for the standard config, with a socketed
arch/arm/mach-davinci/board-dm365-evm.c +3 -3
index b3bef74c982a..9adcb5879d14 100644
@@ -36,10 +36,7 @@
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include <mach/mux.h>
-#include <mach/common.h>
 #include <linux/platform_data/i2c-davinci.h>
-#include <mach/serial.h>
 #include <linux/platform_data/mmc-davinci.h>
 #include <linux/platform_data/mtd-davinci.h>
 #include <linux/platform_data/keyscan-davinci.h>
@@ -47,6 +44,9 @@
 #include <media/i2c/ths7303.h>
 #include <media/i2c/tvp514x.h>
 
+#include "mux.h"
+#include "common.h"
+#include "serial.h"
 #include "davinci.h"
 
 static inline int have_imager(void)
arch/arm/mach-davinci/board-dm644x-evm.c +3 -4
index cce3a621eb20..070fb06cd1ff 100644
@@ -37,10 +37,6 @@
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include <mach/common.h>
-#include <mach/mux.h>
-#include <mach/serial.h>
-
 #include <linux/platform_data/i2c-davinci.h>
 #include <linux/platform_data/mtd-davinci.h>
 #include <linux/platform_data/mmc-davinci.h>
@@ -49,6 +45,9 @@
 #include <linux/platform_data/ti-aemif.h>
 
 #include "davinci.h"
+#include "common.h"
+#include "mux.h"
+#include "serial.h"
 #include "irqs.h"
 
 #define DM644X_EVM_PHY_ID		"davinci_mdio-0:01"
arch/arm/mach-davinci/board-dm646x-evm.c +2 -3
index ee91d81ebbfd..f258180f36ae 100644
@@ -43,9 +43,8 @@
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include <mach/common.h>
-#include <mach/serial.h>
-
+#include "common.h"
+#include "serial.h"
 #include "davinci.h"
 #include "irqs.h"
 
arch/arm/mach-davinci/board-mityomapl138.c +5 -3
index 2127969beb96..3f084bdb9bc5 100644
@@ -28,12 +28,14 @@
 #include <asm/io.h>
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
-#include <mach/common.h>
-#include <mach/da8xx.h>
+
+#include "common.h"
+#include "da8xx.h"
+#include "mux.h"
+
 #include <linux/platform_data/mtd-davinci.h>
 #include <linux/platform_data/mtd-davinci-aemif.h>
 #include <linux/platform_data/ti-aemif.h>
-#include <mach/mux.h>
 #include <linux/platform_data/spi-davinci.h>
 
 #define MITYOMAPL138_PHY_ID		""
arch/arm/mach-davinci/board-neuros-osd2.c +3 -4
index b4843f68bb57..94be492b8a9e 100644
@@ -36,10 +36,9 @@
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include <mach/common.h>
-#include <mach/serial.h>
-#include <mach/mux.h>
-
+#include "common.h"
+#include "serial.h"
+#include "mux.h"
 #include "davinci.h"
 
 #define NEUROS_OSD2_PHY_ID		"davinci_mdio-0:01"
arch/arm/mach-davinci/board-omapl138-hawk.c +3 -3
index 88df8011a4e6..20f71856bf7e 100644
@@ -27,9 +27,9 @@
 #include <asm/mach-types.h>
 #include <asm/mach/arch.h>
 
-#include <mach/common.h>
-#include <mach/da8xx.h>
-#include <mach/mux.h>
+#include "common.h"
+#include "da8xx.h"
+#include "mux.h"
 
 #define HAWKBOARD_PHY_ID		"davinci_mdio-0:07"
 
arch/arm/mach-davinci/board-sffsdr.c +3 -3
index 6930b2f485d1..e87fd8f82d89 100644
@@ -22,12 +22,12 @@
 #include <asm/mach/arch.h>
 #include <asm/mach/flash.h>
 
-#include <mach/common.h>
 #include <linux/platform_data/i2c-davinci.h>
-#include <mach/serial.h>
-#include <mach/mux.h>
 #include <linux/platform_data/usb-davinci.h>
 
+#include "common.h"
+#include "serial.h"
+#include "mux.h"
 #include "davinci.h"
 
 #define SFFSDR_PHY_ID		"davinci_mdio-0:01"
arch/arm/mach-davinci/common.c +2 -2
index ae61d19f9b3a..0a6f826ff136 100644
@@ -17,8 +17,8 @@
 #include <asm/tlb.h>
 #include <asm/mach/map.h>
 
-#include <mach/common.h>
-#include <mach/cputype.h>
+#include "common.h"
+#include "cputype.h"
 
 struct davinci_soc_info davinci_soc_info;
 EXPORT_SYMBOL(davinci_soc_info);
arch/arm/mach-davinci/common.h renamed from arch/arm/mach-davinci/include/mach/common.h +0 -0
similarity index 100%
rename from arch/arm/mach-davinci/include/mach/common.h
rename to arch/arm/mach-davinci/common.h
arch/arm/mach-davinci/cputype.h renamed from arch/arm/mach-davinci/include/mach/cputype.h +1 -1
similarity index 98%
rename from arch/arm/mach-davinci/include/mach/cputype.h
rename to arch/arm/mach-davinci/cputype.h
index 1fc84e21664d..1fe9f84d5ee6 100644
@@ -16,7 +16,7 @@
 #ifndef _ASM_ARCH_CPU_H
 #define _ASM_ARCH_CPU_H
 
-#include <mach/common.h>
+#include "common.h"
 
 struct davinci_id {
 	u8	variant;	/* JTAG ID bits 31:28 */
arch/arm/mach-davinci/da830.c +5 -6
index 018ab4b549f1..1b86657c6e9d 100644
@@ -16,14 +16,13 @@
 #include <linux/irqchip/irq-davinci-cp-intc.h>
 #include <linux/platform_data/gpio-davinci.h>
 
-#include <asm/mach/map.h>
-
-#include <mach/common.h>
-#include <mach/cputype.h>
-#include <mach/da8xx.h>
-
 #include <clocksource/timer-davinci.h>
 
+#include <asm/mach/map.h>
+
+#include "common.h"
+#include "cputype.h"
+#include "da8xx.h"
 #include "irqs.h"
 #include "mux.h"
 
arch/arm/mach-davinci/da850.c +5 -7
index 68156e7239a6..cd514c136de0 100644
@@ -28,16 +28,14 @@
 #include <linux/platform_device.h>
 #include <linux/regmap.h>
 #include <linux/regulator/consumer.h>
+#include <clocksource/timer-davinci.h>
 
 #include <asm/mach/map.h>
 
-#include <mach/common.h>
-#include <mach/cputype.h>
-#include <mach/da8xx.h>
-#include <mach/pm.h>
-
-#include <clocksource/timer-davinci.h>
-
+#include "common.h"
+#include "cputype.h"
+#include "da8xx.h"
+#include "pm.h"
 #include "irqs.h"
 #include "mux.h"
 
arch/arm/mach-davinci/da8xx-dt.c +2 -2
index 0cd2f30aeb9c..45763a9b37ee 100644
@@ -7,8 +7,8 @@
 
 #include <asm/mach/arch.h>
 
-#include <mach/common.h>
-#include <mach/da8xx.h>
+#include "common.h"
+#include "da8xx.h"
 
 #ifdef CONFIG_ARCH_DAVINCI_DA850
 
arch/arm/mach-davinci/da8xx.h renamed from arch/arm/mach-davinci/include/mach/da8xx.h +3 -2
similarity index 99%
rename from arch/arm/mach-davinci/include/mach/da8xx.h
rename to arch/arm/mach-davinci/da8xx.h
index 1618b30661a9..699df08714ba 100644
@@ -21,8 +21,9 @@
 #include <linux/regmap.h>
 #include <linux/videodev2.h>
 
-#include <mach/serial.h>
-#include <mach/pm.h>
+#include "serial.h"
+#include "pm.h"
+
 #include <linux/platform_data/edma.h>
 #include <linux/platform_data/i2c-davinci.h>
 #include <linux/platform_data/mmc-davinci.h>
arch/arm/mach-davinci/davinci.h +2 -1
index 208d7a4d3597..e895eaf9c7cc 100644
@@ -25,7 +25,8 @@
 #include <linux/platform_data/davinci_asp.h>
 #include <linux/platform_data/edma.h>
 #include <linux/platform_data/keyscan-davinci.h>
-#include <mach/hardware.h>
+
+#include "hardware.h"
 
 #include <media/davinci/vpfe_capture.h>
 #include <media/davinci/vpif_types.h>
arch/arm/mach-davinci/devices-da8xx.c +3 -4
index bb368938fc49..ef9593558e5f 100644
@@ -18,10 +18,9 @@
 #include <linux/reboot.h>
 #include <linux/serial_8250.h>
 
-#include <mach/common.h>
-#include <mach/cputype.h>
-#include <mach/da8xx.h>
-
+#include "common.h"
+#include "cputype.h"
+#include "da8xx.h"
 #include "asp.h"
 #include "cpuidle.h"
 #include "irqs.h"
arch/arm/mach-davinci/devices.c +3 -4
index 849e811fade7..199c26d9a2b6 100644
@@ -14,10 +14,9 @@
 #include <linux/io.h>
 #include <linux/reboot.h>
 
-#include <mach/hardware.h>
-#include <mach/cputype.h>
-#include <mach/mux.h>
-
+#include "hardware.h"
+#include "cputype.h"
+#include "mux.h"
 #include "davinci.h"
 #include "irqs.h"
 
arch/arm/mach-davinci/dm355.c +5 -7
index 5de72d2fa8f0..1d7443c59b14 100644
@@ -24,15 +24,13 @@
 #include <linux/serial_8250.h>
 #include <linux/spi/spi.h>
 
-#include <asm/mach/map.h>
-
-#include <mach/common.h>
-#include <mach/cputype.h>
-#include <mach/mux.h>
-#include <mach/serial.h>
-
 #include <clocksource/timer-davinci.h>
 
+#include <asm/mach/map.h>
+
+#include "common.h"
+#include "cputype.h"
+#include "serial.h"
 #include "asp.h"
 #include "davinci.h"
 #include "irqs.h"
arch/arm/mach-davinci/dm365.c +5 -7
index c1e0d46996e4..73ccc916f60a 100644
@@ -29,15 +29,13 @@
 #include <linux/serial_8250.h>
 #include <linux/spi/spi.h>
 
-#include <asm/mach/map.h>
-
-#include <mach/common.h>
-#include <mach/cputype.h>
-#include <mach/mux.h>
-#include <mach/serial.h>
-
 #include <clocksource/timer-davinci.h>
 
+#include <asm/mach/map.h>
+
+#include "common.h"
+#include "cputype.h"
+#include "serial.h"
 #include "asp.h"
 #include "davinci.h"
 #include "irqs.h"
arch/arm/mach-davinci/dm644x.c +5 -7
index 24988939ae46..1ce48d0fb16d 100644
@@ -21,15 +21,13 @@
 #include <linux/platform_device.h>
 #include <linux/serial_8250.h>
 
-#include <asm/mach/map.h>
-
-#include <mach/common.h>
-#include <mach/cputype.h>
-#include <mach/mux.h>
-#include <mach/serial.h>
-
 #include <clocksource/timer-davinci.h>
 
+#include <asm/mach/map.h>
+
+#include "common.h"
+#include "cputype.h"
+#include "serial.h"
 #include "asp.h"
 #include "davinci.h"
 #include "irqs.h"
arch/arm/mach-davinci/dm646x.c +5 -7
index 4ffd028ed997..971b2d4e2595 100644
@@ -22,15 +22,13 @@
 #include <linux/platform_device.h>
 #include <linux/serial_8250.h>
 
-#include <asm/mach/map.h>
-
-#include <mach/common.h>
-#include <mach/cputype.h>
-#include <mach/mux.h>
-#include <mach/serial.h>
-
 #include <clocksource/timer-davinci.h>
 
+#include <asm/mach/map.h>
+
+#include "common.h"
+#include "cputype.h"
+#include "serial.h"
 #include "asp.h"
 #include "davinci.h"
 #include "irqs.h"
arch/arm/mach-davinci/hardware.h renamed from arch/arm/mach-davinci/include/mach/hardware.h +0 -0
similarity index 100%
rename from arch/arm/mach-davinci/include/mach/hardware.h
rename to arch/arm/mach-davinci/hardware.h
arch/arm/mach-davinci/include/mach/mux.h deleted +0 -990

990 lines not on this page · raw message

arch/arm/mach-davinci/include/mach/uncompress.h deleted +0 -97

97 lines not on this page · raw message

arch/arm/mach-davinci/mux.c +2 -2
index 6a2ff0a654a5..bab1eea7fca6 100644
@@ -22,8 +22,8 @@
 #include <linux/module.h>
 #include <linux/spinlock.h>
 
-#include <mach/mux.h>
-#include <mach/common.h>
+#include "mux.h"
+#include "common.h"
 
 static void __iomem *pinmux_base;
 
arch/arm/mach-davinci/mux.h +968 -1

975 lines not on this page · raw message

arch/arm/mach-davinci/pdata-quirks.c +2 -2
index 67f1c8537354..b8b5f1a5e092 100644
@@ -10,8 +10,8 @@
 #include <media/i2c/tvp514x.h>
 #include <media/i2c/adv7343.h>
 
-#include <mach/common.h>
-#include <mach/da8xx.h>
+#include "common.h"
+#include "da8xx.h"
 
 struct pdata_init {
 	const char *compatible;
arch/arm/mach-davinci/pm.c +4 -5
index 323ee4e657c4..8aa39db095d7 100644
@@ -16,11 +16,10 @@
 #include <asm/delay.h>
 #include <asm/io.h>
 
-#include <mach/common.h>
-#include <mach/da8xx.h>
-#include <mach/mux.h>
-#include <mach/pm.h>
-
+#include "common.h"
+#include "da8xx.h"
+#include "mux.h"
+#include "pm.h"
 #include "clock.h"
 #include "psc.h"
 #include "sram.h"
arch/arm/mach-davinci/pm.h renamed from arch/arm/mach-davinci/include/mach/pm.h +0 -0
similarity index 100%
rename from arch/arm/mach-davinci/include/mach/pm.h
rename to arch/arm/mach-davinci/pm.h
arch/arm/mach-davinci/serial.c +2 -2
index 127b62ce7b1e..7f7814807bb5 100644
@@ -14,8 +14,8 @@
 #include <linux/clk.h>
 #include <linux/io.h>
 
-#include <mach/serial.h>
-#include <mach/cputype.h>
+#include "serial.h"
+#include "cputype.h"
 
 static inline void serial_write_reg(struct plat_serial8250_port *p, int offset,
 				    int value)
arch/arm/mach-davinci/serial.h renamed from arch/arm/mach-davinci/include/mach/serial.h +1 -1
similarity index 97%
rename from arch/arm/mach-davinci/include/mach/serial.h
rename to arch/arm/mach-davinci/serial.h
index d4b4aa87964f..14473cb19852 100644
@@ -13,7 +13,7 @@
 
 #include <asm/memory.h>
 
-#include <mach/hardware.h>
+#include "hardware.h"
 
 #define DAVINCI_UART0_BASE	(IO_PHYS + 0x20000)
 #define DAVINCI_UART1_BASE	(IO_PHYS + 0x20400)
arch/arm/mach-davinci/sram.c +1 -1
index bbae190fd82c..d04f39fc84b6 100644
@@ -9,7 +9,7 @@
 #include <linux/io.h>
 #include <linux/genalloc.h>
 
-#include <mach/common.h>
+#include "common.h"
 #include "sram.h"
 
 static struct gen_pool *sram_pool;
arch/arm/mach-davinci/usb-da8xx.c +3 -4
index 25f21ee86f1a..9c8fc5031907 100644
@@ -15,10 +15,9 @@
 #include <linux/platform_device.h>
 #include <linux/usb/musb.h>
 
-#include <mach/common.h>
-#include <mach/cputype.h>
-#include <mach/da8xx.h>
-
+#include "common.h"
+#include "cputype.h"
+#include "da8xx.h"
 #include "irqs.h"
 
 #define DA8XX_USB0_BASE		0x01e00000
arch/arm/mach-davinci/usb.c +2 -3
index dd8db61cdd1c..a9e5c6e91e5d 100644
@@ -8,9 +8,8 @@
 #include <linux/platform_data/usb-davinci.h>
 #include <linux/usb/musb.h>
 
-#include <mach/common.h>
-#include <mach/cputype.h>
-
+#include "common.h"
+#include "cputype.h"
 #include "irqs.h"
 
 #define DAVINCI_USB_OTG_BASE	0x01c64000
Signature · 1 line
2.29.2
Reviewed-by on v1 2/6
#4 lore raw

Re: [PATCH 2/6] ARM: davinci: remove include/mach/ subdirectory

Quoted 6 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

The files in include/mach are only used from mach/davinci, so they are no longer needed in the traditional location.

Quoted 7 lines

Move them to arch/arm/mach-davinci/ and drop the logic for the special include path.

The mach/uncompress.h file is not used at all and can just be removed.

Nice! Thanks for doing this.

#5 lore raw

PATCH 3/6 ARM: spear: remove include/mach/ subdirectory

In reply to Arnd Bergmann

From: Arnd Bergmann <[email protected]>

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.

---
 arch/arm/mach-spear/Makefile                  |  2 -
 arch/arm/mach-spear/include/mach/irqs.h       | 35 ----------------
 arch/arm/mach-spear/include/mach/uncompress.h | 42 -------------------
 .../mach-spear/{include/mach => }/misc_regs.h |  4 +-
 arch/arm/mach-spear/pl080.c                   |  4 +-
 arch/arm/mach-spear/platsmp.c                 |  2 +-
 arch/arm/mach-spear/restart.c                 |  2 +-
 .../arm/mach-spear/{include/mach => }/spear.h |  0
 arch/arm/mach-spear/spear1310.c               |  2 +-
 arch/arm/mach-spear/spear13xx.c               |  2 +-
 arch/arm/mach-spear/spear300.c                |  2 +-
 arch/arm/mach-spear/spear310.c                |  2 +-
 arch/arm/mach-spear/spear320.c                |  2 +-
 arch/arm/mach-spear/spear3xx.c                |  4 +-
 arch/arm/mach-spear/spear6xx.c                |  4 +-
 15 files changed, 14 insertions(+), 95 deletions(-)
 delete mode 100644 arch/arm/mach-spear/include/mach/irqs.h
 delete mode 100644 arch/arm/mach-spear/include/mach/uncompress.h
 rename arch/arm/mach-spear/{include/mach => }/misc_regs.h (87%)
 rename arch/arm/mach-spear/{include/mach => }/spear.h (100%)
arch/arm/mach-spear/Makefile +0 -2
index 176b14f83089..c6101a843601 100644
@@ -3,8 +3,6 @@
 # SPEAr Platform specific Makefile
 #
 
-ccflags-$(CONFIG_ARCH_MULTIPLATFORM) := -I$(srctree)/$(src)/include
-
 # Common support
 obj-y	:= restart.o time.o
 
arch/arm/mach-spear/include/mach/irqs.h deleted +0 -35
deleted file mode 100644
index 7058720c5278..000000000000
@@ -1,35 +0,0 @@
-/*
- * IRQ helper macros for spear machine family
- *
- * Copyright (C) 2009-2012 ST Microelectronics
- * Rajeev Kumar <[email protected]>
- * Viresh Kumar <[email protected]>
- *
- * 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 */
arch/arm/mach-spear/include/mach/uncompress.h deleted +0 -42

42 lines not on this page · raw message

arch/arm/mach-spear/misc_regs.h renamed from arch/arm/mach-spear/include/mach/misc_regs.h +1 -3
similarity index 87%
rename from arch/arm/mach-spear/include/mach/misc_regs.h
rename to arch/arm/mach-spear/misc_regs.h
index cfaf7c665b58..53cd74301f58 100644
@@ -1,6 +1,4 @@
 /*
- * arch/arm/mach-spear3xx/include/mach/misc_regs.h
- *
  * Miscellaneous registers definitions for SPEAr3xx machine family
  *
  * Copyright (C) 2009 ST Microelectronics
@@ -14,7 +12,7 @@
 #ifndef __MACH_MISC_REGS_H
 #define __MACH_MISC_REGS_H
 
-#include <mach/spear.h>
+#include "spear.h"
 
 #define MISC_BASE		(VA_SPEAR_ICM3_MISC_REG_BASE)
 #define DMA_CHN_CFG		(MISC_BASE + 0x0A0)
arch/arm/mach-spear/pl080.c +2 -2
index b4529f3e0ee9..38b479f413dc 100644
@@ -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);
 
arch/arm/mach-spear/platsmp.c +1 -1
index e33a85c28c95..97fbda998df9 100644
@@ -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 */
arch/arm/mach-spear/restart.c +1 -1
index b4342155a783..43417d0db6d9 100644
@@ -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)
arch/arm/mach-spear/spear.h renamed from arch/arm/mach-spear/include/mach/spear.h +0 -0
similarity index 100%
rename from arch/arm/mach-spear/include/mach/spear.h
rename to arch/arm/mach-spear/spear.h
arch/arm/mach-spear/spear1310.c +1 -1
index a7d4f136836f..549ab2be1b74 100644
@@ -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)
arch/arm/mach-spear/spear13xx.c +1 -1
index b38391e9d8bf..9d4bdce2e865 100644
@@ -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)
arch/arm/mach-spear/spear300.c +1 -1
index 325b89579be1..1f2a6bbcf096 100644
@@ -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[] = {
arch/arm/mach-spear/spear310.c +1 -1
index 59e173dc85cf..f0fc140a59cf 100644
@@ -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)
arch/arm/mach-spear/spear320.c +1 -1
index 926d5a243238..cb464ae7c08a 100644
@@ -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)
arch/arm/mach-spear/spear3xx.c +2 -2
index f83321d5e353..fab3d6df69ff 100644
@@ -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 = {
arch/arm/mach-spear/spear6xx.c +2 -2
index c5fc110134ba..d061080b191f 100644
@@ -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[] = {
Signature · 1 line
2.29.2
Acked-by on v1 3/6
#6 lore raw

Re: [PATCH 3/6] ARM: spear: remove include/mach/ subdirectory

Quoted 21 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

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.

---
 arch/arm/mach-spear/Makefile                  |  2 -
 arch/arm/mach-spear/include/mach/irqs.h       | 35 ----------------
 arch/arm/mach-spear/include/mach/uncompress.h | 42 -------------------
 .../mach-spear/{include/mach => }/misc_regs.h |  4 +-
 arch/arm/mach-spear/pl080.c                   |  4 +-
 arch/arm/mach-spear/platsmp.c                 |  2 +-
 arch/arm/mach-spear/restart.c                 |  2 +-
 .../arm/mach-spear/{include/mach => }/spear.h |  0
 arch/arm/mach-spear/spear1310.c               |  2 +-
 arch/arm/mach-spear/spear13xx.c               |  2 +-
 arch/arm/mach-spear/spear300.c                |  2 +-
 arch/arm/mach-spear/spear310.c                |  2 +-
Quoted 8 lines
 arch/arm/mach-spear/spear320.c                |  2 +-
 arch/arm/mach-spear/spear3xx.c                |  4 +-
 arch/arm/mach-spear/spear6xx.c                |  4 +-
 15 files changed, 14 insertions(+), 95 deletions(-)
 delete mode 100644 arch/arm/mach-spear/include/mach/irqs.h
 delete mode 100644 arch/arm/mach-spear/include/mach/uncompress.h
 rename arch/arm/mach-spear/{include/mach => }/misc_regs.h (87%)
 rename arch/arm/mach-spear/{include/mach => }/spear.h (100%)
Signature · 1 line
viresh
#7 lore raw

PATCH 4/6 ARM: omap: fix address space warnings from sparse

In reply to Arnd Bergmann

From: Arnd Bergmann <[email protected]>

Moving sram code from plat-omap got the attention of the kernel test robot.

I found a few more places with related warnings because the sram references are a mix of kernel pointers and __iomem pointers:

mach-omap1/sram-init.c:56:17: warning: cast removes address space '__iomem' of expression mach-omap1/board-ams-delta.c:667:9: warning: incorrect type in argument 1 (different base types) mach-omap2/sram.c:78:17: warning: cast removes address space '__iomem' of expression mach-omap2/omap4-common.c:142:27: warning: incorrect type in assignment (different address spaces)
mach-omap2/omap4-common.c:142:27: expected void [noderef] __iomem *static [toplevel] sram_sync
mach-omap2/omap4-common.c:142:27: got void *
mach-omap2/pm34xx.c:113:45: warning: incorrect type in argument 1 (different address spaces)
mach-omap2/pm34xx.c:113:45: expected void [noderef] __iomem *save_regs
mach-omap2/pm34xx.c:113:45: got void *extern [addressable] [toplevel] omap3_secure_ram_storage

There is no good solution here, as sram is a bit special in this regard. Change the annotations to at least shut up the warnings.

---
 arch/arm/mach-omap1/board-ams-delta.c | 2 +-
 arch/arm/mach-omap1/sram-init.c       | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
arch/arm/mach-omap1/board-ams-delta.c +1 -1
index cd97df48686e..651c28d81132 100644
@@ -664,7 +664,7 @@ static void __init ams_delta_latch2_init(void)
 {
 	u16 latch2 = 1 << LATCH2_PIN_MODEM_NRESET | 1 << LATCH2_PIN_MODEM_CODEC;
 
-	__raw_writew(latch2, LATCH2_VIRT);
+	__raw_writew(latch2, IOMEM(LATCH2_VIRT));
 }
 
 static void __init ams_delta_init(void)
arch/arm/mach-omap1/sram-init.c +1 -1
index 0e3ec32a008e..27c42e2a21cc 100644
@@ -53,7 +53,7 @@ static void *omap_sram_push_address(unsigned long size)
 	new_ceil = ROUND_DOWN(new_ceil, FNCPY_ALIGN);
 	omap_sram_ceil = IOMEM(new_ceil);
 
-	return (void *)omap_sram_ceil;
+	return (void __force *)omap_sram_ceil;
 }
 
 void *omap_sram_push(void *funcp, unsigned long size)
Signature · 1 line
2.29.2
maintainer
#8 lore raw

Re: [PATCH 4/6] ARM: omap: fix address space warnings from sparse

Quoted 7 lines · Arnd Bergmann

mach-omap2/sram.c:78:17: warning: cast removes address space '__iomem' of expression mach-omap2/omap4-common.c:142:27: warning: incorrect type in assignment (different address spaces)
mach-omap2/omap4-common.c:142:27: expected void [noderef] __iomem *static [toplevel] sram_sync
mach-omap2/omap4-common.c:142:27: got void *
mach-omap2/pm34xx.c:113:45: warning: incorrect type in argument 1 (different address spaces)
mach-omap2/pm34xx.c:113:45: expected void [noderef] __iomem *save_regs
mach-omap2/pm34xx.c:113:45: got void *extern [addressable] [toplevel] omap3_secure_ram_storage

These omap2 specific warnings seem to have been split out into a separate patch, or maybe a patch hunk is missing here?

Quoted 3 lines
 arch/arm/mach-omap1/board-ams-delta.c | 2 +-
 arch/arm/mach-omap1/sram-init.c       | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

As this touches only omap1 files. If this patch will be omap1 specific, maybe update the subject line too?

Regards,

Tony

#9 lore raw

PATCH 5/6 ARM: omap2: fix missing declaration warnings

In reply to Arnd Bergmann

From: Arnd Bergmann <[email protected]>

Moving the plat-omap files triggered a sparse warning for omap1 and omap2 that is now in a different file from before. Found some more sparse warnings here that I address by making sure the declaration is visible to both the caller and the callee, or they are static

mach-omap1/fb.c:33:17: warning: symbol 'omap_fb_resources' was not declared. Should it be static? mach-omap1/timer32k.c:215:12: warning: symbol 'omap_init_clocksource_32k' was not declared. Should it be static? mach-omap1/i2c.c:36:12: warning: symbol 'omap_i2c_add_bus' was not declared. Should it be static? mach-omap1/i2c.c:115:12: warning: symbol 'omap_register_i2c_bus_cmdline' was not declared. Should it be static? mach-omap1/i2c.c:140:12: warning: symbol 'omap_register_i2c_bus' was not declared. Should it be static? mach-omap2/dma.c:180:34: warning: symbol 'dma_plat_info' was not declared. Should it be static? mach-omap2/omap4-common.c:116:6: warning: symbol 'omap_interconnect_sync' was not declared. Should it be static? mach-omap2/omap-iommu.c:113:5: warning: symbol 'omap_iommu_set_pwrdm_constraint' was not declared. Should it be static?

---
 arch/arm/mach-omap1/fb.c           |  2 +-
 arch/arm/mach-omap1/i2c.c          |  1 +
 arch/arm/mach-omap1/timer32k.c     |  2 +-
 arch/arm/mach-omap2/common.h       | 13 ++++++++++++-
 arch/arm/mach-omap2/dma.c          |  1 +
 arch/arm/mach-omap2/omap-iommu.c   |  1 +
 arch/arm/mach-omap2/pdata-quirks.c | 11 -----------
 7 files changed, 17 insertions(+), 14 deletions(-)
arch/arm/mach-omap1/fb.c +1 -1
index a4538c231f66..b6e952b03838 100644
@@ -30,7 +30,7 @@ static struct omapfb_platform_data omapfb_config;
 
 static u64 omap_fb_dma_mask = ~(u32)0;
 
-struct resource omap_fb_resources[] = {
+static struct resource omap_fb_resources[] = {
 	{
 		.name  = "irq",
 		.start = INT_LCD_CTRL,
arch/arm/mach-omap1/i2c.c +1 -0
index f574eb0bcc0b..22f945360599 100644
@@ -10,6 +10,7 @@
 
 #include "mux.h"
 #include "soc.h"
+#include "i2c.h"
 
 #define OMAP_I2C_SIZE		0x3f
 #define OMAP1_I2C_BASE		0xfffb3800
arch/arm/mach-omap1/timer32k.c +1 -1
index 560cd16568a7..410d17d1d443 100644
@@ -212,7 +212,7 @@ static void omap_read_persistent_clock64(struct timespec64 *ts)
  * Returns 0 upon success or negative error code upon failure.
  *
  */
-int __init omap_init_clocksource_32k(void __iomem *vbase)
+static int __init omap_init_clocksource_32k(void __iomem *vbase)
 {
 	int ret;
 
arch/arm/mach-omap2/common.h +12 -1
index 32f58f58515e..bd5981945239 100644
@@ -266,7 +266,7 @@ extern void omap4_sar_ram_init(void);
 extern void __iomem *omap4_get_sar_ram_base(void);
 extern void omap4_mpuss_early_init(void);
 extern void omap_do_wfi(void);
-
+extern void omap_interconnect_sync(void);
 
 #ifdef CONFIG_SMP
 /* Needed for secondary core boot */
@@ -360,5 +360,16 @@ extern int omap_dss_reset(struct omap_hwmod *);
 /* SoC specific clock initializer */
 int omap_clk_init(void);
 
+#if IS_ENABLED(CONFIG_OMAP_IOMMU)
+int omap_iommu_set_pwrdm_constraint(struct platform_device *pdev, bool request,
+				    u8 *pwrst);
+#else
+static inline int omap_iommu_set_pwrdm_constraint(struct platform_device *pdev,
+						  bool request, u8 *pwrst)
+{
+	return 0;
+}
+#endif
+
 #endif /* __ASSEMBLER__ */
 #endif /* __ARCH_ARM_MACH_OMAP2PLUS_COMMON_H */
arch/arm/mach-omap2/dma.c +1 -0
index dfc9b21ff19b..830cd4e7eb44 100644
@@ -30,6 +30,7 @@
 #include <linux/omap-dma.h>
 
 #include "soc.h"
+#include "common.h"
 
 static const struct omap_dma_reg reg_map[] = {
 	[REVISION]	= { 0x0000, 0x00, OMAP_DMA_REG_32BIT },
arch/arm/mach-omap2/omap-iommu.c +1 -0
index 93c20bbd7b7e..9c8a85198e16 100644
@@ -13,6 +13,7 @@
 
 #include "clockdomain.h"
 #include "powerdomain.h"
+#include "common.h"
 
 struct pwrdm_link {
 	struct device *dev;
arch/arm/mach-omap2/pdata-quirks.c +0 -11
index e7fd29a502a0..13f1b89f74b8 100644
@@ -43,17 +43,6 @@ struct pdata_init {
 static struct of_dev_auxdata omap_auxdata_lookup[];
 static struct twl4030_gpio_platform_data twl_gpio_auxdata;
 
-#if IS_ENABLED(CONFIG_OMAP_IOMMU)
-int omap_iommu_set_pwrdm_constraint(struct platform_device *pdev, bool request,
-				    u8 *pwrst);
-#else
-static inline int omap_iommu_set_pwrdm_constraint(struct platform_device *pdev,
-						  bool request, u8 *pwrst)
-{
-	return 0;
-}
-#endif
-
 #ifdef CONFIG_MACH_NOKIA_N8X0
 static void __init omap2420_n8x0_legacy_init(void)
 {
Signature · 1 line
2.29.2
maintainer Reviewed-by Tested-by on v1 5/6
#10 lore raw

Re: [PATCH 5/6] ARM: omap2: fix missing declaration warnings

Quoted 6 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

Moving the plat-omap files triggered a sparse warning for omap1 and omap2 that is now in a different file from before. Found some more sparse warnings here that I address by making sure the declaration is visible to both the caller and the callee, or they are static

#11 lore raw

PATCH 6/6 ARM: omap1: add back omap_set_dma_priority() stub

In reply to Arnd Bergmann

From: Arnd Bergmann <[email protected]>

One of my multiplatform patches went a little too far and removed a declaration that is needed for compile-testing the omapfb driver on non-OMAP1 platforms:

arm-linux-gnueabi-ld: drivers/video/fbdev/omap/omapfb_main.o: in function `omapfb_do_probe':
omapfb_main.c:(.text+0x41ec): undefined reference to `omap_set_dma_priority'

Add back the inline stub, and in turn hide the definition when omapfb is disabled, like we do for the usb specific bits.

Fixes 52ef8efcb75e ("dma: omap: hide legacy interface")
---
 arch/arm/mach-omap1/omap-dma.c | 18 ++----------------
 include/linux/omap-dma.h       |  7 +++++++
 2 files changed, 9 insertions(+), 16 deletions(-)
arch/arm/mach-omap1/omap-dma.c +2 -16
index e504f65cdc1b..f7e62de427f3 100644
@@ -99,7 +99,7 @@ static inline void set_gdma_dev(int req, int dev)
 	omap_writel(l, reg);
 }
 
-#ifdef CONFIG_ARCH_OMAP1
+#if IS_ENABLED(CONFIG_FB_OMAP)
 void omap_set_dma_priority(int lch, int dst_port, int priority)
 {
 	unsigned long reg;
@@ -129,22 +129,8 @@ void omap_set_dma_priority(int lch, int dst_port, int priority)
 		omap_writel(l, reg);
 	}
 }
-#endif
-
-#ifdef CONFIG_ARCH_OMAP2PLUS
-void omap_set_dma_priority(int lch, int dst_port, int priority)
-{
-	u32 ccr;
-
-	ccr = p->dma_read(CCR, lch);
-	if (priority)
-		ccr |= (1 << 6);
-	else
-		ccr &= ~(1 << 6);
-	p->dma_write(ccr, CCR, lch);
-}
-#endif
 EXPORT_SYMBOL(omap_set_dma_priority);
+#endif
 
 #if IS_ENABLED(CONFIG_USB_OMAP)
 #ifdef CONFIG_ARCH_OMAP15XX
include/linux/omap-dma.h +7 -0
index 254b4e10511b..6f6c31e3fb93 100644
@@ -294,7 +294,14 @@ struct omap_system_dma_plat_info {
 
 extern struct omap_system_dma_plat_info *omap_get_plat_info(void);
 
+#if defined(CONFIG_ARCH_OMAP1)
 extern void omap_set_dma_priority(int lch, int dst_port, int priority);
+#else
+static inline void omap_set_dma_priority(int lch, int dst_port, int priority)
+{
+}
+#endif
+
 extern int omap_request_dma(int dev_id, const char *dev_name,
 			void (*callback)(int lch, u16 ch_status, void *data),
 			void *data, int *dma_ch);
Signature · 1 line
2.29.2
maintainer Reviewed-by on v1 6/6
#12 lore raw

Re: [PATCH 6/6] ARM: omap1: add back omap_set_dma_priority() stub

Quoted 11 lines · Arnd Bergmann

From: Arnd Bergmann <[email protected]>

One of my multiplatform patches went a little too far and removed a declaration that is needed for compile-testing the omapfb driver on non-OMAP1 platforms:

arm-linux-gnueabi-ld: drivers/video/fbdev/omap/omapfb_main.o: in function `omapfb_do_probe':
omapfb_main.c:(.text+0x41ec): undefined reference to `omap_set_dma_priority'

Add back the inline stub, and in turn hide the definition when omapfb is disabled, like we do for the usb specific bits.