android_kernel_samsung_msm8976/arch
Thomas Petazzoni 273bed2e5d ARM: 8799/1: mm: fix pci_ioremap_io() offset check
[ Upstream commit 3a58ac65e2d7969bcdf1b6acb70fa4d12a88e53e ]

IO_SPACE_LIMIT is the ending address of the PCI IO space, i.e
something like 0xfffff (and not 0x100000).

Therefore, when offset = 0xf0000 is passed as argument, this function
fails even though the offset + SZ_64K fits below the
IO_SPACE_LIMIT. This makes the last chunk of 64 KB of the I/O space
not usable as it cannot be mapped.

This patch fixes that by substracing 1 to offset + SZ_64K, so that we
compare the addrss of the last byte of the I/O space against
IO_SPACE_LIMIT instead of the address of the first byte of what is
after the I/O space.

Fixes: c279443709 ("ARM: Add fixed PCI i/o mapping")
Signed-off-by: Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Acked-by: Nicolas Pitre <nico@linaro.org>
Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2019-07-27 21:52:37 +02:00
..
alpha Safer ABI for O_TMPFILE 2018-12-03 11:52:36 +01:00
arc mm: larger stack guard gap, between vmas 2017-07-11 00:00:39 +00:00
arm ARM: 8799/1: mm: fix pci_ioremap_io() offset check 2019-07-27 21:52:37 +02:00
arm64 defconfig: Disable LTE coexistence for wifi only models 2019-07-27 21:51:32 +02:00
avr32
blackfin
c6x
cris
frv mm: larger stack guard gap, between vmas 2017-07-11 00:00:39 +00:00
h8300
hexagon
ia64 Import latest Samsung release 2017-04-18 03:43:52 +02:00
m32r This is the 3.10.98 stable release 2017-04-18 17:17:24 +02:00
m68k Merge remote-tracking branch 'f2fs/linux-3.10.y' into HEAD 2017-04-18 17:02:28 +02:00
metag
microblaze
mips mm: larger stack guard gap, between vmas 2017-07-11 00:00:39 +00:00
mn10300 This is the 3.10.96 stable release 2017-04-18 17:16:02 +02:00
openrisc This is the 3.10.96 stable release 2017-04-18 17:16:02 +02:00
parisc Safer ABI for O_TMPFILE 2018-12-03 11:52:36 +01:00
powerpc mm: larger stack guard gap, between vmas 2017-07-11 00:00:39 +00:00
s390 kernel: make groups_sort calling a responsibility group_info allocators 2019-07-27 21:46:18 +02:00
score
sh mm: larger stack guard gap, between vmas 2017-07-11 00:00:39 +00:00
sparc crypto: hash - annotate algorithms taking optional key 2019-07-27 21:49:17 +02:00
tile mm: larger stack guard gap, between vmas 2017-07-11 00:00:39 +00:00
um This is the 3.10.99 stable release 2017-04-18 17:17:46 +02:00
unicore32
x86 x86/acpi: Prevent out of bound access caused by broken ACPI tables 2019-07-27 21:51:30 +02:00
xtensa mm: larger stack guard gap, between vmas 2017-07-11 00:00:39 +00:00
.gitignore
Kconfig