ARM: EXYNOS: Update CONFIG_ARCH_NR_GPIO for Exynos
Subsystems (2)
PATCH v4 1/1 ARM: EXYNOS: Update CONFIG_ARCH_NR_GPIO for Exynos
With the recent cleanup in Exynos platform code notably commits 17859bec ("ARM: EXYNOS: Do not select legacy Kconfig symbols any more") and b9222210 ("ARM: EXYNOS: Remove mach/gpio.h"), the definition of ARCH_NR_GPIOS got removed. This started causing problems on SoCs like Exynos4412 which have more than the default number of GPIOs. Thus define this number in KConfig file which takes care of current SoC requirements and provides scope for GPIO expanders. Without this patch we get the following errors during boot:
gpiochip_add: gpios 251..258 (gpv0) failed to register samsung-pinctrl 106e0000.pinctrl: failed to register gpio_chip gpv0, error code: -22
samsung-pinctrl: probe of 106e0000.pinctrl failed with error -22
---
Changes since v3:
Rearranged different default values in single line.
--- arch/arm/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
arch/arm/Kconfig +1 -2
@@ -1590,8 +1590,7 @@ config ARM_PSCI config ARCH_NR_GPIO int default 1024 if ARCH_SHMOBILE || ARCH_TEGRA - default 512 if SOC_OMAP5 - default 512 if ARCH_KEYSTONE + default 512 if ARCH_EXYNOS || ARCH_KEYSTONE || SOC_OMAP5 default 392 if ARCH_U8500 default 352 if ARCH_VT8500 default 288 if ARCH_SUNXI
Signature · 1 line
1.7.9.5
PATCH v4 1/1 ARM: EXYNOS: Update CONFIG_ARCH_NR_GPIO for Exynos
Hi Sachin,
Quoted 28 lines · Sachin Kamat
With the recent cleanup in Exynos platform code notably commits
17859bec("ARM: EXYNOS: Do not select legacyKconfigsymbols any more") andb9222210("ARM: EXYNOS: Removemach/gpio.h"), the definition ofARCH_NR_GPIOSgot removed. This started causing problems on SoCs like Exynos4412 which have more than the default number of GPIOs. Thus define this number in KConfig file which takes care of current SoC requirements and provides scope for GPIO expanders. Without this patch we get the following errors during boot:
gpiochip_add: gpios 251..258 (gpv0) failed to register samsung-pinctrl 106e0000.pinctrl: failed to registergpio_chipgpv0, error code: -22
samsung-pinctrl: probe of 106e0000.pinctrl failed with error -22Signed-off-by Sachin Kamat <[email protected]>Cc Tomasz Figa <[email protected]>---
Changes since v3:
Rearranged different default values in single line.--- arch/arm/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)arch/arm/Kconfig +0
-0
arch/arm/Kconfig config ARM_PSCI · line 1593
Quoted 6 lines
arch/arm/Kconfig +1
-2@@ -1590,8 +1590,7 @@ config ARM_PSCI config ARCH_NR_GPIO int default 1024 if ARCH_SHMOBILE || ARCH_TEGRA - default 512 if SOC_OMAP5 - default 512 if ARCH_KEYSTONE + default 512 if ARCH_EXYNOS || ARCH_KEYSTONE || SOC_OMAP5
Sorry, 512 seems a bit too generous to me. Also I would rather leave each SOC/ARCH on a separate line.
Almost half of those 512 entries would have been unused in most cases. How about, e.g. 352 ? If anyone finds this value too low they could always submit a patch like this one. IMHO with 352 or 392 there would be sufficient margin.
--
Regards,
Sylwester
PATCH v4 1/1 ARM: EXYNOS: Update CONFIG_ARCH_NR_GPIO for Exynos
Hi Sylwester,
Quoted 26 lines · Sylwester Nawrocki
Hi Sachin,
Quoted 23 lines · Sachin Kamat
With the recent cleanup in Exynos platform code notably commits
17859bec("ARM: EXYNOS: Do not select legacyKconfigsymbols any more") andb9222210("ARM: EXYNOS: Removemach/gpio.h"), the definition ofARCH_NR_GPIOSgot removed. This started causing problems on SoCs like Exynos4412 which have more than the default number of GPIOs. Thus define this number in KConfig file which takes care of current SoC requirements and provides scope for GPIO expanders. Without this patch we get the following errors during boot:
gpiochip_add: gpios 251..258 (gpv0) failed to register samsung-pinctrl 106e0000.pinctrl: failed to registergpio_chipgpv0, error code: -22
samsung-pinctrl: probe of 106e0000.pinctrl failed with error -22Signed-off-by Sachin Kamat <[email protected]>Cc Tomasz Figa <[email protected]>---
Changes since v3:
Rearranged different default values in single line.--- arch/arm/Kconfig | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
Quoted 14 lines
arch/arm/Kconfig config ARM_PSCI · line 1593
Quoted 11 lines
arch/arm/Kconfig +1
-2@@ -1590,8 +1590,7 @@ config ARM_PSCI config ARCH_NR_GPIO int default 1024 if ARCH_SHMOBILE || ARCH_TEGRA - default 512 if SOC_OMAP5 - default 512 if ARCH_KEYSTONE + default 512 if ARCH_EXYNOS || ARCH_KEYSTONE || SOC_OMAP5Sorry, 512 seems a bit too generous to me. Also I would rather leave each SOC/ARCH on a separate line.
Even I had left it that way earlier. However Kukjin suggested the above (single line).
I feel it is more of individual preference.
Quoted 5 lines
Almost half of those 512 entries would have been unused in most cases. How about, e.g. 352 ? If anyone finds this value too low they could always submit a patch like this one. IMHO with 352 or 392 there would be sufficient margin.
I agree. Again, I do not have any reservations here. I just went with maintainer's choice which was a superset of your and Tomasz's suggestions :)
Signature · 2 lines
With warm regards, Sachin
PATCH v4 1/1 ARM: EXYNOS: Update CONFIG_ARCH_NR_GPIO for Exynos
Quoted 3 lines · Sachin Kamat
Hi Sylwester,
Hi all,
[...]
Quoted 11 lines
Quoted 10 lines
arch/arm/Kconfig config ARM_PSCI · line 1593
Quoted 7 lines
arch/arm/Kconfig +1
-2@@ -1590,8 +1590,7 @@ config ARM_PSCI config ARCH_NR_GPIO int default 1024 if ARCH_SHMOBILE || ARCH_TEGRA - default 512 if SOC_OMAP5 - default 512 if ARCH_KEYSTONE + default 512 if ARCH_EXYNOS || ARCH_KEYSTONE || SOC_OMAP5Sorry, 512 seems a bit too generous to me. Also I would rather leave each SOC/ARCH on a separate line.
Quoted 4 lines
Even I had left it that way earlier. However Kukjin suggested the above (single line).
I feel it is more of individual preference.
I know it is quite big but I think if we want to use the large number, I'd preferred to use enough the large number so that we don't need to update it soon. If so, multiple line is useless...
Note, according to git log, for omap5, 256 is the accurately right number.
Quoted 6 lines
Quoted 5 lines
Almost half of those 512 entries would have been unused in most cases. How about, e.g. 352 ? If anyone finds this value too low they could always submit a patch like this one. IMHO with 352 or 392 there would be sufficient margin.
Hmm...
Quoted 4 lines
I agree. Again, I do not have any reservations here. I just went with maintainer's choice which was a superset of your and Tomasz's suggestions :)
- Kukjin
PATCH v4 1/1 ARM: EXYNOS: Update CONFIG_ARCH_NR_GPIO for Exynos
In reply to Sachin KamatQuoted 31 lines · Kukjin Kim
Quoted 3 lines · Sachin Kamat
Hi Sylwester,
Hi all,
[...]
Quoted 11 lines
Quoted 10 lines
arch/arm/Kconfig config ARM_PSCI · line 1593
Quoted 7 lines
arch/arm/Kconfig +1
-2@@ -1590,8 +1590,7 @@ config ARM_PSCI config ARCH_NR_GPIO int default 1024 if ARCH_SHMOBILE || ARCH_TEGRA - default 512 if SOC_OMAP5 - default 512 if ARCH_KEYSTONE + default 512 if ARCH_EXYNOS || ARCH_KEYSTONE || SOC_OMAP5Sorry, 512 seems a bit too generous to me. Also I would rather leave each SOC/ARCH on a separate line.
Quoted 4 lines
Even I had left it that way earlier. However Kukjin suggested the above (single line).
I feel it is more of individual preference.I know it is quite big but I think if we want to use the large number, I'd preferred to use enough the large number so that we don't need to update it soon. If so, multiple line is useless...
Note, according to git log, for omap5, 256 is the accurately right number.
Quoted 1 line
Quoted 1 line
Quoted 11 lines
Quoted 5 lines
Quoted 4 lines
Almost half of those 512 entries would have been unused in most cases. How about, e.g. 352 ? If anyone finds this value too low they could always submit a patch like this one. IMHO with 352 or 392 there would be sufficient margin.
Hmm...
Quoted 4 lines
I agree. Again, I do not have any reservations here. I just went with maintainer's choice which was a superset of your and Tomasz's suggestions :)
If you have another opinion on this, please let me know before sending fixes for 3.11 probably tomorrow morning in my time.
Thanks,
Kukjin
PATCH v4 1/1 ARM: EXYNOS: Update CONFIG_ARCH_NR_GPIO for Exynos
Quoted 2 lines · Kukjin Kim
Quoted 1 line · Kukjin Kim
Sachin Kamat wrote:
[...]
Quoted 15 lines
Quoted 15 lines
Quoted 15 lines
Quoted 10 lines
arch/arm/Kconfig config ARM_PSCI · line 1593
Quoted 7 lines
arch/arm/Kconfig +1
-2@@ -1590,8 +1590,7 @@ config ARM_PSCI config ARCH_NR_GPIO int default 1024 if ARCH_SHMOBILE || ARCH_TEGRA - default 512 if SOC_OMAP5 - default 512 if ARCH_KEYSTONE + default 512 if ARCH_EXYNOS || ARCH_KEYSTONE || SOC_OMAP5Sorry, 512 seems a bit too generous to me. Also I would rather leave each SOC/ARCH on a separate line.
Even I had left it that way earlier. However Kukjin suggested the above (single line).
I feel it is more of individual preference.
Quoted 5 lines
Quoted 5 lines
I know it is quite big but I think if we want to use the large number, I'd preferred to use enough the large number so that we don't need to update it soon. If so, multiple line is useless...
Note, according to git log, for omap5, 256 is the accurately right number.
If it's done similarly for other SoCs then I'm fine with change as above. 256 entries is only about 3 kB anyway, it shouldn't be a big deal for systems using those SoCs.
Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
Quoted 4 lines
Almost half of those 512 entries would have been unused in most cases. How about, e.g. 352 ? If anyone finds this value too low they could always submit a patch like this one. IMHO with 352 or 392 there would be sufficient margin.
Quoted 8 lines
Quoted 5 lines
Hmm...
Quoted 3 lines
I agree. Again, I do not have any reservations here. I just went with maintainer's choice which was a superset of your and Tomasz's suggestions :)
If you have another opinion on this, please let me know before sending fixes for 3.11 probably tomorrow morning in my time.
I'm OK with that change. Sorry for the trouble.
--
Thanks,
Sylwester