android_kernel_xiaomi_sm8350/arch
Bryan Wu 397861cd80 Blackfin arch: fix bug - gpio_bank() macros messed up bank number caculating with positioning a gpio
The whole story:

Before BF51x merged, all the MAX_BLACKFIN_GPIOS are integral multiple of GPIO_BANKSIZE (= 16).
But BF51x provides MAX_BLACKFIN_GPIOS = 40 which includes 3 banks and the 3rd bank has only 8
GPIO pins.

Therefore, gpio_bank() macros is correct when you try to find a GPIO in which bank (GPIO_35 is
in bank 2). But on BF51x gpio_bank(MAX_BLACKFIN_GPIOS) only gives out 2 banks instead of 3
banks for some static array initialization.

This patch add a new macros gpio_bank_n() and GPIO_BANK_NUM to do bank number caculating and
remain the gpio_bank() macros for positioning a gpio in which bank.

Signed-off-by: Bryan Wu <cooloney@kernel.org>
2008-11-18 17:48:22 +08:00
..
alpha alpha: introduce asm/swab.h 2009-01-06 18:10:27 -08:00
arm arm: introduce asm/swab.h 2009-01-06 18:10:28 -08:00
avr32 avr32: introduce asm/swab.h 2009-01-06 18:10:26 -08:00
blackfin Blackfin arch: fix bug - gpio_bank() macros messed up bank number caculating with positioning a gpio 2008-11-18 17:48:22 +08:00
cris Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging-2.6 2009-01-06 17:04:29 -08:00
frv take init_fs to saner place 2008-12-31 18:07:42 -05:00
h8300 h8300: introduce asm/swab.h 2009-01-06 18:10:28 -08:00
ia64 ia64: introduce asm/swab.h 2009-01-06 18:10:28 -08:00
m32r Merge branch 'cpus4096-for-linus-3' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip 2009-01-03 12:04:39 -08:00
m68k m68k: fix recursive dependency in Kconfig 2009-01-02 20:43:20 +01:00
m68knommu m68knommu: introduce asm/swab.h 2009-01-06 18:10:28 -08:00
mips mips: introduce asm/swab.h 2009-01-06 18:10:27 -08:00
mn10300 take init_fs to saner place 2008-12-31 18:07:42 -05:00
parisc atomic_t: unify all arch definitions 2009-01-06 15:59:10 -08:00
powerpc powerpc: introduce asm/swab.h 2009-01-06 18:10:27 -08:00
s390 s390: introduce asm/swab.h 2009-01-06 18:10:27 -08:00
sh sh: introduce asm/swab.h 2009-01-06 18:10:27 -08:00
sparc sparc: introduce asm/swab.h 2009-01-06 18:10:27 -08:00
um mm: invoke oom-killer from page fault 2009-01-06 15:58:58 -08:00
x86 x86: introduce asm/swab.h 2009-01-06 18:10:27 -08:00
xtensa take init_fs to saner place 2008-12-31 18:07:42 -05:00
.gitignore
Kconfig