ipq806x: refresh 5.10 patches
[openwrt/staging/dedeckeh.git] / target / linux / ipq806x / patches-5.10 / 103-arm-Enlarge-IO_SPACE_LIMIT-needed-for-some-SoC.patch
1 From 9a894b0e5d3e6ed3c435b89fe96794ec9ddf5925 Mon Sep 17 00:00:00 2001
2 From: Ansuel Smith <ansuelsmth@gmail.com>
3 Date: Sun, 28 Feb 2021 15:22:24 +0100
4 Subject: [PATCH] arm: Enlarge IO_SPACE_LIMIT needed for some SoC
5
6 Ipq8064 SoC requires larger IO_SPACE_LIMIT or second and third pci port
7 fails to register the IO addresses and connected device doesn't work.
8
9 Cc: <stable@vger.kernel.org> # 4.9+
10 Signed-off-by: Ansuel Smith <ansuelsmth@gmail.com>
11 ---
12 arch/arm/include/asm/io.h | 2 +-
13 1 file changed, 1 insertion(+), 1 deletion(-)
14
15 --- a/arch/arm/include/asm/io.h
16 +++ b/arch/arm/include/asm/io.h
17 @@ -197,7 +197,7 @@ void __iomem *pci_remap_cfgspace(resourc
18 #ifdef CONFIG_NEED_MACH_IO_H
19 #include <mach/io.h>
20 #elif defined(CONFIG_PCI)
21 -#define IO_SPACE_LIMIT ((resource_size_t)0xfffff)
22 +#define IO_SPACE_LIMIT ((resource_size_t)0xffffff)
23 #define __io(a) __typesafe_io(PCI_IO_VIRT_BASE + ((a) & IO_SPACE_LIMIT))
24 #else
25 #define __io(a) __typesafe_io((a) & IO_SPACE_LIMIT)