]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
pinctrl: sunxi: remove GPIO_EXTRA_HEADER
authorAndre Przywara <andre.przywara@arm.com>
Tue, 6 Sep 2022 09:36:38 +0000 (10:36 +0100)
committerAndre Przywara <andre.przywara@arm.com>
Sun, 22 Oct 2023 22:40:57 +0000 (23:40 +0100)
U-Boot's generic GPIO_EXTRA_HEADER is a convenience symbol to allow code
to more easily include platform specific GPIO headers. This should not
be needed in a DM world anymore, since the generic GPIO framework
handles that nicely.
For Allwinner boards we still need to deal with non-DM GPIO in the SPL,
but this should become the exception, not the rule.

Make this more obvious by removing the definition of GPIO_EXTRA_HEADER,
and just force every legacy user of platform specific GPIO to include
the new sunxi_gpio.h header explicitly. Everyone doing so should feel
ashamed and should find a way to avoid it from now on.

Signed-off-by: Andre Przywara <andre.przywara@arm.com>
Tested-by: Samuel Holland <samuel@sholland.org>
17 files changed:
arch/arm/Kconfig
arch/arm/mach-sunxi/board.c
arch/arm/mach-sunxi/dram_suniv.c
arch/arm/mach-sunxi/spl_spi_sunxi.c
board/sunxi/board.c
board/sunxi/chip.c
drivers/gpio/axp_gpio.c
drivers/gpio/sunxi_gpio.c
drivers/i2c/sun6i_p2wi.c
drivers/i2c/sun8i_rsb.c
drivers/mmc/sunxi_mmc.c
drivers/pinctrl/sunxi/pinctrl-sunxi.c
drivers/video/hitachi_tx18d42vm_lcd.c
drivers/video/ssd2828.c
drivers/video/sunxi/sunxi_display.c
drivers/video/sunxi/sunxi_lcd.c
include/sunxi_gpio.h [moved from arch/arm/include/asm/arch-sunxi/gpio.h with 100% similarity]

index dcccbfea42abcd8ecb2cc1883dfcf55999953b64..d812685c9842161878b4810600954fb45fbabaec 100644 (file)
@@ -1135,7 +1135,6 @@ config ARCH_SUNXI
        select DM_MMC if MMC
        select DM_SCSI if SCSI
        select DM_SERIAL
-       select GPIO_EXTRA_HEADER
        select OF_BOARD_SETUP
        select OF_CONTROL
        select OF_SEPARATE
index 78597ad932c486ebc124356383ee34439f8d9a4e..4a1a0eacdba484f36fb6e57c81d8811b6e7dc46b 100644 (file)
@@ -17,6 +17,7 @@
 #include <i2c.h>
 #include <serial.h>
 #include <spl.h>
+#include <sunxi_gpio.h>
 #include <asm/cache.h>
 #include <asm/gpio.h>
 #include <asm/io.h>
index 3aa3ce76272ce977ed2b1b177ba5f54337e9d654..9e583e18553bc1e78c90107b88138e22f5cf08a6 100644 (file)
 #include <asm/io.h>
 #include <asm/arch/clock.h>
 #include <asm/arch/dram.h>
-#include <asm/arch/gpio.h>
 #include <linux/bitops.h>
 #include <linux/delay.h>
 #include <hang.h>
+#include <sunxi_gpio.h>
 
 #define SDR_T_CAS                      (0x2)
 #define SDR_T_RAS                      (0x8)
index 81159cfee61258b7d012da4da62e067d7e20a9c0..c2410dd7bb161483b15f91eddd751bc3f11b7583 100644 (file)
@@ -13,6 +13,7 @@
 #include <linux/bitops.h>
 #include <linux/delay.h>
 #include <linux/libfdt.h>
+#include <sunxi_gpio.h>
 
 #ifdef CONFIG_SPL_OS_BOOT
 #error CONFIG_SPL_OS_BOOT is not supported yet
index 5cfb33468e5d441e6bca54876c0223fd2209eb72..7a1c708b9f2ea5a78ebdeeaec96e8e332a16c5f7 100644 (file)
@@ -38,6 +38,7 @@
 #include <asm/armv7.h>
 #endif
 #include <asm/gpio.h>
+#include <sunxi_gpio.h>
 #include <asm/io.h>
 #include <u-boot/crc.h>
 #include <env_internal.h>
index cde04bebe96357f86ecdca35703d2a0c5691b357..eeee6319e7991748e283c44cc5bd15a691124d69 100644 (file)
@@ -12,7 +12,7 @@
 #include <w1-eeprom.h>
 #include <dm/device-internal.h>
 
-#include <asm/arch/gpio.h>
+#include <sunxi_gpio.h>
 
 #include <extension_board.h>
 
index 49672193ffcdd0b2eee73c9a490418ddb7d4c9f9..af6631697f58bf13ca6068ac3255d2d5e7351634 100644 (file)
@@ -14,6 +14,7 @@
 #include <dm/lists.h>
 #include <dm/root.h>
 #include <errno.h>
+#include <sunxi_gpio.h>
 
 static int axp_gpio_set_value(struct udevice *dev, unsigned pin, int val);
 
index d7f6a266e53c11c2e90ed6d774be2e98dcba4446..e335496581ff918080c367f9d9a226dbfe8a40a3 100644 (file)
@@ -17,6 +17,7 @@
 #include <asm/io.h>
 #include <asm/gpio.h>
 #include <dt-bindings/gpio/gpio.h>
+#include <sunxi_gpio.h>
 
 /*
  * =======================================================================
index d221323295d7a6e215ddd026b753800730ebd079..b8e07a533ca92d953f29953f6cb5dda260076184 100644 (file)
 #include <errno.h>
 #include <i2c.h>
 #include <reset.h>
+#include <sunxi_gpio.h>
 #include <time.h>
 #include <asm/io.h>
 #include <asm/arch/cpu.h>
-#include <asm/arch/gpio.h>
 #include <asm/arch/p2wi.h>
 #include <asm/arch/prcm.h>
 #include <asm/arch/sys_proto.h>
index 47fa05b6d1cc594904f46b394966693f567efde9..f36f2c7afacfa4aa59c2894dbc3d6b9c018c4c24 100644 (file)
 #include <dm.h>
 #include <errno.h>
 #include <i2c.h>
+#include <sunxi_gpio.h>
 #include <reset.h>
 #include <time.h>
 #include <asm/arch/cpu.h>
-#include <asm/arch/gpio.h>
 #include <asm/arch/prcm.h>
 #include <asm/arch/rsb.h>
 
index 23bc7da917a96f2ce6fec9c64563734abe137bfb..03e33753fcf915eafff4fd8248925d5b157beaab 100644 (file)
@@ -27,6 +27,7 @@
 #include <asm/arch/cpu.h>
 #include <asm/arch/mmc.h>
 #include <linux/delay.h>
+#include <sunxi_gpio.h>
 
 #ifndef CCM_MMC_CTRL_MODE_SEL_NEW
 #define CCM_MMC_CTRL_MODE_SEL_NEW      0
index 946447e91366455342e2ec24f33bc4f4ec81faa2..fc80fe50b1425f3586de8e140d42cff17594b9f9 100644 (file)
@@ -7,6 +7,7 @@
 #include <dm/pinctrl.h>
 #include <errno.h>
 #include <malloc.h>
+#include <sunxi_gpio.h>
 
 #include <asm/gpio.h>
 
index 87c4d27438ad1fee94508e795285a178a7854061..95984fe3d3d1bab04d26a6165ef0415ed4bfc150 100644 (file)
@@ -10,6 +10,7 @@
 #include <linux/delay.h>
 
 #include <asm/gpio.h>
+#include <sunxi_gpio.h>
 #include <errno.h>
 
 /*
index 4cdcbe7755ae86811b46ebd18acec1e663548c26..948f5e74d0fee1e1715fb454eaea6778460161b9 100644 (file)
@@ -12,7 +12,6 @@
 #include <common.h>
 #include <malloc.h>
 #include <mipi_display.h>
-#include <asm/arch/gpio.h>
 #include <asm/gpio.h>
 #include <linux/delay.h>
 
index 9110a4848211772cde55361f13ed16237657a520..8da44a1bb6d8a0970f360e6d079174c67a23e617 100644 (file)
@@ -31,6 +31,7 @@
 #include <malloc.h>
 #include <video.h>
 #include <dm/uclass-internal.h>
+#include <sunxi_gpio.h>
 #include "../videomodes.h"
 #include "../anx9804.h"
 #include "../hitachi_tx18d42vm_lcd.h"
index 8b9c3b2bfa95a5bfba37074e57145c7c4597c1b5..7a01cc343cac3734a62aa5ca5f2d3a3e49865709 100644 (file)
@@ -17,6 +17,7 @@
 #include <asm/arch/lcdc.h>
 #include <asm/global_data.h>
 #include <asm/gpio.h>
+#include <sunxi_gpio.h>
 
 struct sunxi_lcd_priv {
        struct display_timing timing;