From: Russell King - ARM Linux <linux@arm.linux.org.uk>
To: Arnd Bergmann <arnd@arndb.de>
Cc: Linus Walleij <linus.walleij@linaro.org>,
linux-arm-kernel@lists.infradead.org,
Bjorn Helgaas <bhelgaas@google.com>,
Alexandre Courbot <gnurou@gmail.com>,
linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arch@vger.kernel.org
Subject: Re: [PATCH 4/4] ARM: remove asm/gpio.h
Date: Mon, 15 Feb 2016 16:03:06 +0000 [thread overview]
Message-ID: <20160215160305.GG10826@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <1455551208-2825510-5-git-send-email-arnd@arndb.de>
On Mon, Feb 15, 2016 at 04:46:31PM +0100, Arnd Bergmann wrote:
> -#if CONFIG_ARCH_NR_GPIO > 0
> -#define ARCH_NR_GPIOS CONFIG_ARCH_NR_GPIO
> -#endif
...
> diff --git a/include/asm-generic/gpio.h b/include/asm-generic/gpio.h
> index 40ec1433f05d..2d04b321db13 100644
> --- a/include/asm-generic/gpio.h
> +++ b/include/asm-generic/gpio.h
> @@ -26,8 +26,12 @@
> */
>
> #ifndef ARCH_NR_GPIOS
> +#ifdef CONFIG_ARCH_NR_GPIO
> +#define ARCH_NR_GPIOS CONFIG_ARCH_NR_GPIO
> +#else
> #define ARCH_NR_GPIOS 512
> #endif
> +#endif
This really isn't the same thing, especially when you look at:
config ARCH_NR_GPIO
int
default 1024 if ARCH_BRCMSTB || ARCH_SHMOBILE || ARCH_TEGRA || \
ARCH_ZYNQ
default 512 if ARCH_EXYNOS || ARCH_KEYSTONE || SOC_OMAP5 || \
SOC_DRA7XX || ARCH_S3C24XX || ARCH_S3C64XX || ARCH_S5PV210
default 416 if ARCH_SUNXI
default 392 if ARCH_U8500
default 352 if ARCH_VT8500
default 288 if ARCH_ROCKCHIP
default 264 if MACH_H4700
default 0
This has the effect of causing anything not mentioned above to end up
with ARCH_NR_GPIOS set to zero.
You really should _not_ be making these kinds of functional changes
when moving code around. Separate the two changes: either first move
the code, and have a separate patch to make the functional changes, or
make the functional changes first, and then move the code around.
I'd have thought you would've known this by now...
--
RMK's Patch system: http://www.arm.linux.org.uk/developer/patches/
FTTC broadband for 0.8mile line: currently at 9.6Mbps down 400kbps up
according to speedtest.net.
next prev parent reply other threads:[~2016-02-15 16:03 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-02-02 19:53 [PATCH 0/2] GPIO: Clean up asm/gpio.h Bjorn Helgaas
2016-02-02 19:53 ` [PATCH 1/2] gpio: Include linux/gpio.h instead of asm/gpio.h Bjorn Helgaas
2016-02-03 0:02 ` Alexandre Courbot
2016-02-15 13:35 ` Linus Walleij
2016-02-02 19:53 ` [PATCH 2/2] gpio: Remove unused asm/gpio.h files Bjorn Helgaas
2016-02-03 0:03 ` Alexandre Courbot
2016-02-03 8:19 ` [PATCH 0/2] GPIO: Clean up asm/gpio.h Thomas Gleixner
2016-02-05 13:43 ` Linus Walleij
2016-02-15 15:46 ` [PATCH 0/4] clean up irq_to_gpio and asm/gpio.h Arnd Bergmann
2016-02-15 15:46 ` [PATCH 1/4] gpio: remove broken irq_to_gpio() interface Arnd Bergmann
2016-02-15 16:01 ` Lars-Peter Clausen
2016-02-15 20:16 ` Arnd Bergmann
2016-02-16 15:42 ` Linus Walleij
2016-02-16 15:45 ` Arnd Bergmann
2016-02-16 15:53 ` Linus Walleij
2016-02-15 15:46 ` [PATCH 2/4] gpio: ks8695: remove irq_to_gpio function Arnd Bergmann
2016-02-16 15:43 ` Linus Walleij
2016-02-15 15:46 ` [PATCH 3/4] gpio: ep93xx: remove private " Arnd Bergmann
2016-02-16 15:51 ` Linus Walleij
2016-02-16 16:12 ` Arnd Bergmann
2016-02-15 15:46 ` [PATCH 4/4] ARM: remove asm/gpio.h Arnd Bergmann
2016-02-15 16:03 ` Russell King - ARM Linux [this message]
2016-02-16 15:37 ` [PATCH v2 0/5] gpio: clean up irq_to_gpio and ARCH_NR_GPIOS Arnd Bergmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160215160305.GG10826@n2100.arm.linux.org.uk \
--to=linux@arm.linux.org.uk \
--cc=arnd@arndb.de \
--cc=bhelgaas@google.com \
--cc=gnurou@gmail.com \
--cc=linus.walleij@linaro.org \
--cc=linux-arch@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-gpio@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).