Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1485306
| From | Yinghai Lu <yinghai@kernel.org> |
|---|---|
| Newsgroups | linux.kernel |
| Subject | [PATCH v14 08/17] sparc/PCI: Add IORESOURCE_MEM_64 for 64-bit resource in OF parsing |
| Date | 2016-09-16 22:10 +0200 |
| Message-ID | <si7Cq-13S-29@gated-at.bofh.it> (permalink) |
| References | <si7Cp-13S-5@gated-at.bofh.it> |
| Organization | linux.* mail to news gateway |
For device resource with PREF bit setting under bridge 64-bit pref resource, we need to make sure only set PREF for 64bit resource. so this patch set IORESOUCE_MEM_64 for 64bit resource during OF device resource flags parsing. Link: https://bugzilla.kernel.org/show_bug.cgi?id=96261 Link: https://bugzilla.kernel.org/show_bug.cgi?id=96241 Signed-off-by: Yinghai Lu <yinghai@kernel.org> Cc: "David S. Miller" <davem@davemloft.net> Cc: sparclinux@vger.kernel.org Tested-by: Khalid Aziz <khalid.aziz@oracle.com> --- arch/sparc/kernel/of_device_32.c | 5 +++-- arch/sparc/kernel/of_device_64.c | 5 +++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/arch/sparc/kernel/of_device_32.c b/arch/sparc/kernel/of_device_32.c index 185aa96..3e9f273 100644 --- a/arch/sparc/kernel/of_device_32.c +++ b/arch/sparc/kernel/of_device_32.c @@ -83,11 +83,12 @@ static unsigned long of_bus_pci_get_flags(const u32 *addr, unsigned long flags) case 0x01: flags |= IORESOURCE_IO; break; - case 0x02: /* 32 bits */ - case 0x03: /* 64 bits */ flags |= IORESOURCE_MEM; break; + case 0x03: /* 64 bits */ + flags |= IORESOURCE_MEM | IORESOURCE_MEM_64; + break; } if (w & 0x40000000) flags |= IORESOURCE_PREFETCH; diff --git a/arch/sparc/kernel/of_device_64.c b/arch/sparc/kernel/of_device_64.c index 7bbdc26..defee61 100644 --- a/arch/sparc/kernel/of_device_64.c +++ b/arch/sparc/kernel/of_device_64.c @@ -146,11 +146,12 @@ static unsigned long of_bus_pci_get_flags(const u32 *addr, unsigned long flags) case 0x01: flags |= IORESOURCE_IO; break; - case 0x02: /* 32 bits */ - case 0x03: /* 64 bits */ flags |= IORESOURCE_MEM; break; + case 0x03: /* 64 bits */ + flags |= IORESOURCE_MEM | IORESOURCE_MEM_64; + break; } if (w & 0x40000000) flags |= IORESOURCE_PREFETCH; -- 2.8.3
Back to linux.kernel | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
[PATCH v14 00/17] PCI: Fixup for 64bit resource with sparc Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 10/17] powerpc/PCI: Keep resource idx order with bridge register number Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 08/17] sparc/PCI: Add IORESOURCE_MEM_64 for 64-bit resource in OF parsing Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 02/17] PCI: Let pci_mmap_page_range() take resource address Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 13/17] PCI: Check pref compatible bit for mem64 resource of PCIe device Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 03/17] PCI: Remove __pci_mmap_make_offset() Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 01/17] PCI: Fix proc mmap on sparc Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 06/17] PCI: Add pci_find_bus_resource() Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 12/17] OF/PCI: Add IORESOURCE_MEM_64 for 64-bit resource Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 05/17] sparc/PCI: Use correct offset for bus address to resource Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 16/17] PCI: Only treat non-pref mmio64 as pref if host bridge has mmio64 Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 17/17] PCI: Restore pref MMIO allocation logic for host bridge without mmio64 Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:10 +0200 [PATCH v14 15/17] PCI: Add has_mem64 for struct host_bridge Yinghai Lu <yinghai@kernel.org> - 2016-09-16 22:20 +0200 [PATCH v14 07/17] sparc/PCI: Reserve legacy mmio after PCI mmio Yinghai Lu <yinghai@kernel.org> - 2016-09-16 23:10 +0200
csiph-web