Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ab275b13 authored by Linus Walleij's avatar Linus Walleij
Browse files

ARM: s5p: cut the custom ARCH_NR_GPIOS definition



The number of GPIOs defined for the different S5P platforms using
the tricky #define macros are actually as follows:

S5P64x0: 180 GPIOs
S5PC100: 115 GPIOs
S5PV210: 252 GPIOs

The include file <asm-generic/gpio.h> will automatically bump us
to 256 GPIOs which is a nice default value that happens to encompass
all the S5P platform requirements under its roof.

Cut ARCH_NR_GPIOS and the custom spacing macro for extra GPIOs
that is not used anywhere in the kernel.

Acked-by: default avatarAlexandre Courbot <acourbot@nvidia.com>
Signed-off-by: default avatarLinus Walleij <linus.walleij@linaro.org>
parent 4c834452
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -125,8 +125,4 @@ enum s5p6450_gpio_number {

#define S3C_GPIO_END		S5P64X0_GPIO_END

/* define the number of gpios we need to the one after the last GPIO range */

#define ARCH_NR_GPIOS		(S5P64X0_GPIO_END + CONFIG_SAMSUNG_GPIO_EXTRA)

#endif /* __ASM_ARCH_GPIO_H */
+0 −3
Original line number Diff line number Diff line
@@ -138,7 +138,4 @@ enum s5p_gpio_number {
/* It used the end of the S5PC100 gpios */
#define S3C_GPIO_END		S5PC100_GPIO_END

/* define the number of gpios we need to the one after the MP04() range */
#define ARCH_NR_GPIOS		(S5PC100_GPIO_END + 1)

#endif /* __ASM_ARCH_GPIO_H */
+0 −4
Original line number Diff line number Diff line
@@ -133,8 +133,4 @@ enum s5p_gpio_number {
#define S5PV210_GPIO_END	(S5PV210_MP05(S5PV210_GPIO_MP05_NR) + 1)
#define S3C_GPIO_END		S5PV210_GPIO_END

/* define the number of gpios we need to the one after the MP05() range */
#define ARCH_NR_GPIOS		(S5PV210_MP05(S5PV210_GPIO_MP05_NR) +	\
				 CONFIG_SAMSUNG_GPIO_EXTRA + 1)

#endif /* __ASM_ARCH_GPIO_H */
+0 −16
Original line number Diff line number Diff line
@@ -108,22 +108,6 @@ config S5P_GPIO_DRVSTR
	  Internal configuration to get and set correct GPIO driver strength
	  helper

config SAMSUNG_GPIO_EXTRA
	int "Number of additional GPIO pins"
	default 128 if SAMSUNG_GPIO_EXTRA128
	default 64 if SAMSUNG_GPIO_EXTRA64
	default 0
	help
	  Use additional GPIO space in addition to the GPIO's the SOC
	  provides. This allows expanding the GPIO space for use with
	  GPIO expanders.

config SAMSUNG_GPIO_EXTRA64
	bool

config SAMSUNG_GPIO_EXTRA128
	bool

config S3C_GPIO_SPACE
	int "Space between gpio banks"
	default 0