Re: [PATCH] s390/pci: move ioremap/ioremap_prot/ioremap_wc/ioremap_wt/iounmap to arch/s390/mm/ioremap.c

2021-04-07 Thread Bixuan Cui
On 2021/4/6 19:14, Niklas Schnelle wrote: > and move the have_mio variable out of the PCI only code or use a raw > "#ifdef CONFIG_PCI". Obviously we don't have any actual users of > ioremap() that don't depend on CONFIG_PCI but it would make it so that > iore

Re: [RFC v1 23/26] x86/tdx: Make pages shared in ioremap()

2021-04-06 Thread Dave Hansen
gt; - * In a SEV guest, NONE and RESERVED should not be mapped encrypted because >>> - * there the whole memory is already encrypted. >>> + * In a SEV or TDX guest, NONE and RESERVED should not be mapped encrypted >>> (or >>> + * private in TDX case) because there

Re: [RFC v1 23/26] x86/tdx: Make pages shared in ioremap()

2021-04-06 Thread Kirill A. Shutemov
On Thu, Apr 01, 2021 at 01:26:23PM -0700, Dave Hansen wrote: > On 2/5/21 3:38 PM, Kuppuswamy Sathyanarayanan wrote: > > From: "Kirill A. Shutemov" > > > > All ioremap()ed paged that are not backed by normal memory (NONE or > > RESERVED) have to be

Re: [PATCH] s390/pci: move ioremap/ioremap_prot/ioremap_wc/ioremap_wt/iounmap to arch/s390/mm/ioremap.c

2021-04-06 Thread Niklas Schnelle
On Thu, 2021-04-01 at 20:46 +0800, Bixuan Cui wrote: > The ioremap/iounmap is implemented in arch/s390/pci/pci.c. > While CONFIG_PCI is disabled,the compilation error is reported: > s390x-linux-gnu-ld: drivers/pcmcia/cistpl.o: in function `set_cis_map': > cistpl.c:(.text+

[PATCH v4 09/18] docs: driver-api: device-io: Document ioremap() variants & access funcs

2021-04-02 Thread Hector Martin
This documents the newly introduced ioremap_np() along with all the other common ioremap() variants, and some higher-level abstractions available. Reviewed-by: Linus Walleij Signed-off-by: Hector Martin --- Documentation/driver-api/device-io.rst | 218 + 1 file changed

[PATCH v4 07/18] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-04-02 Thread Hector Martin
ARM64 currently defaults to posted MMIO (nGnRE), but some devices require the use of non-posted MMIO (nGnRnE). Introduce a new ioremap() variant to handle this case. ioremap_np() returns NULL on arches that do not implement this variant. sparc64 is the only architecture that needs to be touched

Re: [RFC v1 23/26] x86/tdx: Make pages shared in ioremap()

2021-04-01 Thread Dave Hansen
On 2/5/21 3:38 PM, Kuppuswamy Sathyanarayanan wrote: > From: "Kirill A. Shutemov" > > All ioremap()ed paged that are not backed by normal memory (NONE or > RESERVED) have to be mapped as shared. s/paged/pages/ > +/* Make the page accesable by VMM */ > +#define pgpr

[PATCH] s390/pci: move ioremap/ioremap_prot/ioremap_wc/ioremap_wt/iounmap to arch/s390/mm/ioremap.c

2021-04-01 Thread Bixuan Cui
The ioremap/iounmap is implemented in arch/s390/pci/pci.c. While CONFIG_PCI is disabled,the compilation error is reported: s390x-linux-gnu-ld: drivers/pcmcia/cistpl.o: in function `set_cis_map': cistpl.c:(.text+0x32a): undefined reference to `ioremap' s390x-linux-gnu-ld

Re: [RFT PATCH v3 08/27] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-03-25 Thread Will Deacon
it > > > > + * requests stronger semantics than regular ioremap(). Portable drivers > > > > + * should instead use one of the higher-level abstractions, like > > > > + * devm_ioremap_resource(), to choose the correct variant for any given > > >

Re: [RFT PATCH v3 08/27] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-03-25 Thread Hector Martin
On 25/03/2021 04.09, Arnd Bergmann wrote: On Wed, Mar 24, 2021 at 7:12 PM Will Deacon wrote: +/* + * ioremap_np needs an explicit architecture implementation, as it + * requests stronger semantics than regular ioremap(). Portable drivers + * should instead use one of the higher-level

Re: [RFT PATCH v3 08/27] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-03-24 Thread Arnd Bergmann
On Wed, Mar 24, 2021 at 7:12 PM Will Deacon wrote: > > > +/* > > + * ioremap_np needs an explicit architecture implementation, as it > > + * requests stronger semantics than regular ioremap(). Portable drivers > > + * should instead use one of the high

Re: [RFT PATCH v3 08/27] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-03-24 Thread Will Deacon
On Fri, Mar 05, 2021 at 06:38:43AM +0900, Hector Martin wrote: > ARM64 currently defaults to posted MMIO (nGnRnE), but some devices > require the use of non-posted MMIO (nGnRE). Introduce a new ioremap() > variant to handle this case. ioremap_np() is aliased to ioremap() by > defau

ERROR: modpost: "ioremap" undefined!

2021-03-23 Thread kernel test robot
ARCH=s390 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): >> ERROR: modpost: "ioremap" [drivers/pcmcia/pcmcia.ko] undefined! >> ERROR: modpost: "iounma

[PATCH v13 05/14] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-03-16 Thread Nicholas Piggin
This will be used as a generic kernel virtual mapping function, so re-name it in preparation. Reviewed-by: Miaohe Lin Reviewed-by: Christoph Hellwig Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 64 +++- 1 file changed, 33 insertions(+), 31 d

Re: [RFT PATCH v3 10/27] docs: driver-api: device-io: Document ioremap() variants & access funcs

2021-03-09 Thread Hector Martin
ioremap() variants, and some higher-level abstractions available. Signed-off-by: Hector Martin I like this, I just want one change: Put the common ioremap() on top in all paragraphs, so the norm comes before the exceptions. I.e. it is weird to mention ioremap_np() before mentioning ioremap(). +1

Re: [RFT PATCH v3 08/27] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-03-08 Thread Marc Zyngier
On Thu, 04 Mar 2021 21:38:43 +, Hector Martin wrote: > > ARM64 currently defaults to posted MMIO (nGnRnE), but some devices > require the use of non-posted MMIO (nGnRE). Introduce a new ioremap() > variant to handle this case. ioremap_np() is aliased to ioremap() by > default

Re: [RFT PATCH v3 10/27] docs: driver-api: device-io: Document ioremap() variants & access funcs

2021-03-05 Thread Arnd Bergmann
On Fri, Mar 5, 2021 at 4:09 PM Andy Shevchenko wrote: > On Fri, Mar 5, 2021 at 12:25 PM Linus Walleij > wrote: > > On Thu, Mar 4, 2021 at 10:40 PM Hector Martin wrote: > > > > > This documents the newly introduced ioremap_np() along with all the > > > other

Re: [RFT PATCH v3 08/27] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-03-05 Thread Hector Martin
On 05/03/2021 23.45, Andy Shevchenko wrote: On Thu, Mar 4, 2021 at 11:40 PM Hector Martin wrote: ARM64 currently defaults to posted MMIO (nGnRnE), but some devices require the use of non-posted MMIO (nGnRE). Introduce a new ioremap() variant to handle this case. ioremap_np() is aliased to

Re: [RFT PATCH v3 10/27] docs: driver-api: device-io: Document ioremap() variants & access funcs

2021-03-05 Thread Andy Shevchenko
On Fri, Mar 5, 2021 at 12:25 PM Linus Walleij wrote: > On Thu, Mar 4, 2021 at 10:40 PM Hector Martin wrote: > > > This documents the newly introduced ioremap_np() along with all the > > other common ioremap() variants, and some higher-level abstractions > > availabl

Re: [RFT PATCH v3 08/27] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-03-05 Thread Andy Shevchenko
On Thu, Mar 4, 2021 at 11:40 PM Hector Martin wrote: > > ARM64 currently defaults to posted MMIO (nGnRnE), but some devices > require the use of non-posted MMIO (nGnRE). Introduce a new ioremap() > variant to handle this case. ioremap_np() is aliased to ioremap() by > default on

Re: [RFT PATCH v3 10/27] docs: driver-api: device-io: Document ioremap() variants & access funcs

2021-03-05 Thread Linus Walleij
On Thu, Mar 4, 2021 at 10:40 PM Hector Martin wrote: > This documents the newly introduced ioremap_np() along with all the > other common ioremap() variants, and some higher-level abstractions > available. > > Signed-off-by: Hector Martin I like this, I just want one change:

[RFT PATCH v3 08/27] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-03-04 Thread Hector Martin
ARM64 currently defaults to posted MMIO (nGnRnE), but some devices require the use of non-posted MMIO (nGnRE). Introduce a new ioremap() variant to handle this case. ioremap_np() is aliased to ioremap() by default on arches that do not implement this variant. sparc64 is the only architecture that

[RFT PATCH v3 10/27] docs: driver-api: device-io: Document ioremap() variants & access funcs

2021-03-04 Thread Hector Martin
This documents the newly introduced ioremap_np() along with all the other common ioremap() variants, and some higher-level abstractions available. Signed-off-by: Hector Martin --- Documentation/driver-api/device-io.rst | 218 + 1 file changed, 218 insertions(+) diff

[PATCH] mm/ioremap: remove volatile keyword in iounmap function

2021-02-21 Thread Zhiyuan Dai
Like volatile, the kernel primitives which make concurrent access to data safe (spinlocks, mutexes, memory barriers, etc.) are designed to prevent unwanted optimization. If they are being used properly, there will be no need to use volatile as well. If volatile is still necessary, there is almost

Re: [PATCH v2 10/25] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-02-18 Thread Hector Martin
On 16/02/2021 19.53, Christoph Hellwig wrote: Your new iomremap variant needs proper documentation explaining the semantics in detail. What's the right place for this? I haven't found any generic ioremap documentation page in the tree yet. I suppose I could write an ARM64-specifi

Re: [PATCH v2 10/25] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-02-16 Thread Christoph Hellwig
Your new iomremap variant needs proper documentation explaining the semantics in detail.

[PATCH v2 10/25] asm-generic/io.h: Add a non-posted variant of ioremap()

2021-02-15 Thread Hector Martin
ARM64 currently defaults to posted MMIO (nGnRnE), but some devices require the use of non-posted MMIO (nGnRE). Introduce a new ioremap() variant to handle this case. ioremap_np() is aliased to ioremap() by default on arches that do not implement this variant. This adds the

Re: [PATCH 13/18] arm64: ioremap: use nGnRnE mappings on platforms that require it

2021-02-10 Thread Mark Kettenis
: > > 1. Something similar to the current hacky patch (which isn't really > intended as a real solution...); change ioremap to default to nGnRnE > using some kind of platform-level flag in the DT, then figure out how to > get the PCI drivers to bypass that. This requires chang

Re: [PATCH 13/18] arm64: ioremap: use nGnRnE mappings on platforms that require it

2021-02-10 Thread Hector Martin
Solutions discussed in this thread and elsewhere include: 1. Something similar to the current hacky patch (which isn't really intended as a real solution...); change ioremap to default to nGnRnE using some kind of platform-level flag in the DT, then figure out how to get the PCI drivers

Re: [PATCH 13/18] arm64: ioremap: use nGnRnE mappings on platforms that require it

2021-02-09 Thread Hector Martin
On 09/02/2021 18.15, Arnd Bergmann wrote: Right, these are the same ranges that I found in the adt and that Mark listed in his code snippet, so it seems we all see the same partitioning of the address space. I also see them reflected in the /defaults/pmap-io-ranges property in ADT, which seems to

Re: [PATCH 13/18] arm64: ioremap: use nGnRnE mappings on platforms that require it

2021-02-09 Thread Mark Kettenis
> From: Arnd Bergmann > Date: Tue, 9 Feb 2021 10:15:31 +0100 > > On Tue, Feb 9, 2021 at 1:25 AM Hector Martin wrote: > > On 09/02/2021 08.20, Mark Kettenis wrote: > > I probed writing to i<<28 for i = [0..255], using nGnRE. This reveals > > that nGnRE writes are allowed (i.e. either succeed or e

Re: [PATCH 13/18] arm64: ioremap: use nGnRnE mappings on platforms that require it

2021-02-08 Thread Hector Martin
On 09/02/2021 08.20, Mark Kettenis wrote: It is only PCI mmio space that needs to be nGnRE. The PCI host controller register space itself needs nGnRnE just like all other integrated peripherals (or at least it works that way). This is correct. Actually, as I just discovered, nGnRE writes to MM

Re: [PATCH 13/18] arm64: ioremap: use nGnRnE mappings on platforms that require it

2021-02-08 Thread Mark Kettenis
> From: Arnd Bergmann > Date: Mon, 8 Feb 2021 23:57:20 +0100 > > On Thu, Feb 4, 2021 at 9:39 PM Hector Martin wrote: > > > (3) Do it at a lower level, in ioremap() itself. This requires that > > ioremap() somehow discriminates based on address range to pick what

[RFC v1 23/26] x86/tdx: Make pages shared in ioremap()

2021-02-05 Thread Kuppuswamy Sathyanarayanan
From: "Kirill A. Shutemov" All ioremap()ed paged that are not backed by normal memory (NONE or RESERVED) have to be mapped as shared. Reuse the infrastructure we have for AMD SEV. Signed-off-by: Kirill A. Shutemov Reviewed-by: Andi Kleen Signed-off-by: Kuppuswamy Sathyanarayanan

ERROR: modpost: "ioremap" undefined!

2021-02-04 Thread kernel test robot
ARCH=s390 If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All errors (new ones prefixed by >>, old ones prefixed by <<): >> ERROR: modpost: "ioremap" [drivers/pcmcia/pcmcia.ko] undefined! >> ERROR: modpost: "iounma

[PATCH 13/18] arm64: ioremap: use nGnRnE mappings on platforms that require it

2021-02-04 Thread Hector Martin
e any fabric configuration or other bit we can flip to make the problem go away. As an additional confounding factor, reportedly PCIe MMIO BAR mappings conversely *do* need to use nGnRE to work properly. So we can't even get away with a single ioremap setting, but need to discriminate based o

[PATCH v12 05/14] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-02-02 Thread Nicholas Piggin
This will be used as a generic kernel virtual mapping function, so re-name it in preparation. Reviewed-by: Miaohe Lin Reviewed-by: Christoph Hellwig Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 64 +++- 1 file changed, 33 insertions(+), 31 d

Re: [PATCH] bus: mvebu-mbus: make iounmap() symmetric with ioremap()

2021-01-29 Thread Gregory CLEMENT
Hi, > On Fri, 29 Jan 2021 17:01:35 +0100 > Gregory CLEMENT wrote: > >> Could you sent me the patch I don't have it in my emails boxes. > > https://lore.kernel.org/lkml/20201112032149.21906-1-chris.pack...@alliedtelesis.co.nz/raw Applied on mvebu/arm Thanks, Gregory > > Thomas > -- > Thomas

Re: [PATCH] bus: mvebu-mbus: make iounmap() symmetric with ioremap()

2021-01-29 Thread Thomas Petazzoni
On Fri, 29 Jan 2021 17:01:35 +0100 Gregory CLEMENT wrote: > Could you sent me the patch I don't have it in my emails boxes. https://lore.kernel.org/lkml/20201112032149.21906-1-chris.pack...@alliedtelesis.co.nz/raw Thomas -- Thomas Petazzoni, CTO, Bootlin Embedded Linux and Kernel engineering h

Re: [PATCH v11 04/13] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-01-27 Thread Miaohe Lin
Hi: On 2021/1/26 12:45, Nicholas Piggin wrote: > This will be used as a generic kernel virtual mapping function, so > re-name it in preparation. > Looks good to me. Thanks. Reviewed-by: Miaohe Lin > Signed-off-by: Nicholas Piggin > --- > mm/ioremap.c | 64 +++-

[PATCH v11 04/13] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-01-26 Thread Nicholas Piggin
This will be used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 64 +++- 1 file changed, 33 insertions(+), 31 deletions(-) diff --git a/mm/ioremap.c b/mm/ioremap.c ind

Re: [PATCH v11 04/13] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-01-26 Thread Christoph Hellwig
Looks good, Reviewed-by: Christoph Hellwig

Re: [PATCH] bus: mvebu-mbus: make iounmap() symmetric with ioremap()

2021-01-26 Thread Thomas Petazzoni
vers/bus/mvebu-mbus.c:1113:2-8: ERROR: missing iounmap; ioremap on > >> line 1106 and execution via conditional on line > >> > >> It took some staring but I don't think there is a problem because the > >> file global `mbus_state` is passed mvebu_mbus_co

Re: [PATCH] bus: mvebu-mbus: make iounmap() symmetric with ioremap()

2021-01-26 Thread Chris Packham
Hi All, On 12/11/20 9:02 pm, Thomas Petazzoni wrote: > On Thu, 12 Nov 2020 16:21:49 +1300 > Chris Packham wrote: > >> make coccicheck complains: >> >>./drivers/bus/mvebu-mbus.c:1113:2-8: ERROR: missing iounmap; ioremap on >> line 1106 and execution via condi

Re: [PATCH v10 04/12] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-01-24 Thread Nicholas Piggin
Excerpts from Christoph Hellwig's message of January 24, 2021 9:36 pm: > On Sun, Jan 24, 2021 at 06:22:22PM +1000, Nicholas Piggin wrote: >> This will be used as a generic kernel virtual mapping function, so >> re-name it in preparation. > > The new name looks ok, but shouldn't it also move to vma

Re: [PATCH v10 04/12] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-01-24 Thread Christoph Hellwig
On Sun, Jan 24, 2021 at 06:22:22PM +1000, Nicholas Piggin wrote: > This will be used as a generic kernel virtual mapping function, so > re-name it in preparation. The new name looks ok, but shouldn't it also move to vmalloc.c with the more generic name and purpose?

[PATCH v10 04/12] mm/ioremap: rename ioremap_*_range to vmap_*_range

2021-01-24 Thread Nicholas Piggin
This will be used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 64 +++- 1 file changed, 33 insertions(+), 31 deletions(-) diff --git a/mm/ioremap.c b/mm/ioremap.c ind

[PATCH 4/4] ASoC: qcom: Remove duplicate error messages on ioremap

2021-01-14 Thread Stephen Boyd
We don't need to print an error message when these ioremap operations fail. The function that returns an error already prints an error message and properly attributes it to the device. Drop them to save some code. Cc: V Sujith Kumar Reddy Cc: Srinivasa Rao Cc: Srinivas Kandagatla Cc: Che

[PATCH v9 04/12] mm/ioremap: rename ioremap_*_range to vmap_*_range

2020-12-04 Thread Nicholas Piggin
This will be used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 64 +++- 1 file changed, 33 insertions(+), 31 deletions(-) diff --git a/mm/ioremap.c b/mm/ioremap.c ind

[PATCH v8 04/12] mm/ioremap: rename ioremap_*_range to vmap_*_range

2020-11-28 Thread Nicholas Piggin
This will be used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 64 +++- 1 file changed, 33 insertions(+), 31 deletions(-) diff --git a/mm/ioremap.c b/mm/ioremap.c ind

Re: [PATCH 1/2] remoteproc: qcom_q6v5_mss: Replace ioremap with memremap

2020-11-18 Thread Bjorn Andersson
On Wed 04 Nov 01:03 CST 2020, Sibi Sankar wrote: > Fix the sparse warnings reported by the kernel test bot by replacing > ioremap calls with memremap. > > Reported-by: kernel test robot Reviewed-by: Bjorn Andersson Regards, Bjorn > Signed-off-by: Sibi Sankar > --- >

Re: [PATCH 0/2] Rename ioremap functions that include request_mem

2020-11-13 Thread Thierry Reding
On Fri, Nov 13, 2020 at 09:53:25AM +0100, Uwe Kleine-König wrote: > Hello, > > here comes a patch set that implements the suggestion in the previous > mail so we have something to discuss about. > > Best regards > Uwe > > Uwe Kleine-König (2): > base: Rename devm_ioremap_resource to make the i

[PATCH 0/2] Rename ioremap functions that include request_mem

2020-11-13 Thread Uwe Kleine-König
Hello, here comes a patch set that implements the suggestion in the previous mail so we have something to discuss about. Best regards Uwe Uwe Kleine-König (2): base: Rename devm_ioremap_resource to make the implicit request_mem explicit platform: Rename devm_platform_ioremap_resource to

Re: [PATCH] bus: mvebu-mbus: make iounmap() symmetric with ioremap()

2020-11-12 Thread Thomas Petazzoni
On Thu, 12 Nov 2020 16:21:49 +1300 Chris Packham wrote: > make coccicheck complains: > > ./drivers/bus/mvebu-mbus.c:1113:2-8: ERROR: missing iounmap; ioremap on > line 1106 and execution via conditional on line > > It took some staring but I don't think there i

[PATCH] bus: mvebu-mbus: make iounmap() symmetric with ioremap()

2020-11-11 Thread Chris Packham
make coccicheck complains: ./drivers/bus/mvebu-mbus.c:1113:2-8: ERROR: missing iounmap; ioremap on line 1106 and execution via conditional on line It took some staring but I don't think there is a problem because the file global `mbus_state` is passed mvebu_mbus_common_init() a

[PATCH 1/2] remoteproc: qcom_q6v5_mss: Replace ioremap with memremap

2020-11-03 Thread Sibi Sankar
Fix the sparse warnings reported by the kernel test bot by replacing ioremap calls with memremap. Reported-by: kernel test robot Signed-off-by: Sibi Sankar --- I'll send out the patches to convert ioremap to memremap on other qc remoteproc drivers once I get a chance to test them. dr

Re: [PATCH 1/2] sparc32: Move ioremap/iounmap declaration before asm-generic/io.h include

2020-10-02 Thread David Miller
From: Lorenzo Pieralisi Date: Fri, 2 Oct 2020 15:50:29 +0100 > On Tue, Sep 15, 2020 at 01:11:21PM -0700, David Miller wrote: >> From: Lorenzo Pieralisi >> Date: Tue, 15 Sep 2020 10:32:02 +0100 >> >> > Move the ioremap/iounmap declaration before asm-generic/io.h

Re: [PATCH 1/2] sparc32: Move ioremap/iounmap declaration before asm-generic/io.h include

2020-10-02 Thread Lorenzo Pieralisi
On Tue, Sep 15, 2020 at 01:11:21PM -0700, David Miller wrote: > From: Lorenzo Pieralisi > Date: Tue, 15 Sep 2020 10:32:02 +0100 > > > Move the ioremap/iounmap declaration before asm-generic/io.h is > > included so that it is visible within it. > > > >

[PATCH 4.19 133/245] PCI: Use ioremap(), not phys_to_virt() for platform ROM

2020-09-29 Thread Greg Kroah-Hartman
xa7/0x180 [drm] radeon_pci_probe+0x10f/0x1a0 [radeon] pci_device_probe+0xd4/0x140 Fix the issue by updating all drivers which can access a platform provided ROM. Instead of calling the helper function pci_platform_rom() which uses phys_to_virt(), call ioremap() directly on the pdev->rom. radeon_r

[PATCH 5.4 210/388] PCI: Use ioremap(), not phys_to_virt() for platform ROM

2020-09-29 Thread Greg Kroah-Hartman
xa7/0x180 [drm] radeon_pci_probe+0x10f/0x1a0 [radeon] pci_device_probe+0xd4/0x140 Fix the issue by updating all drivers which can access a platform provided ROM. Instead of calling the helper function pci_platform_rom() which uses phys_to_virt(), call ioremap() directly on the pdev->rom. radeon_r

[PATCH AUTOSEL 5.4 216/330] PCI: Use ioremap(), not phys_to_virt() for platform ROM

2020-09-17 Thread Sasha Levin
xa7/0x180 [drm] radeon_pci_probe+0x10f/0x1a0 [radeon] pci_device_probe+0xd4/0x140 Fix the issue by updating all drivers which can access a platform provided ROM. Instead of calling the helper function pci_platform_rom() which uses phys_to_virt(), call ioremap() directly on the pdev->rom. radeon_r

[PATCH AUTOSEL 4.19 132/206] PCI: Use ioremap(), not phys_to_virt() for platform ROM

2020-09-17 Thread Sasha Levin
xa7/0x180 [drm] radeon_pci_probe+0x10f/0x1a0 [radeon] pci_device_probe+0xd4/0x140 Fix the issue by updating all drivers which can access a platform provided ROM. Instead of calling the helper function pci_platform_rom() which uses phys_to_virt(), call ioremap() directly on the pdev->rom. radeon_r

[PATCH v8 2/7] RISC-V: Add early ioremap support

2020-09-17 Thread Atish Patra
UEFI uses early IO or memory mappings for runtime services before normal ioremap() is usable. Add the necessary fixmap bindings and pmd mappings for generic ioremap support to work. Signed-off-by: Atish Patra Reviewed-by: Anup Patel Reviewed-by: Palmer Dabbelt Signed-off-by: Palmer Dabbelt

[PATCH v2 2/3] sparc32: Move ioremap/iounmap declaration before asm-generic/io.h include

2020-09-16 Thread Lorenzo Pieralisi
Move the ioremap/iounmap declaration before asm-generic/io.h is included so that it is visible within it. Signed-off-by: Lorenzo Pieralisi Cc: "David S. Miller" --- arch/sparc/include/asm/io_32.h | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/

Re: [PATCH 1/2] sparc32: Move ioremap/iounmap declaration before asm-generic/io.h include

2020-09-15 Thread Christoph Hellwig
#define memcpy_toio(d,s,sz) _memcpy_toio(d,s,sz) > > +#ifdef __KERNEL__ > + > +/* > + * Bus number may be embedded in the higher bits of the physical address. > + * This is why we have no bus number argument to ioremap(). > + */ > +void __iomem *ioremap(phys_addr_t o

Re: [PATCH 1/2] sparc32: Move ioremap/iounmap declaration before asm-generic/io.h include

2020-09-15 Thread Lorenzo Pieralisi
32.h > > @@ -11,6 +11,16 @@ > > #define memcpy_fromio(d,s,sz) _memcpy_fromio(d,s,sz) > > #define memcpy_toio(d,s,sz) _memcpy_toio(d,s,sz) > > > > +#ifdef __KERNEL__ > > + > > +/* > > + * Bus number may be embedded in the higher bits of the physica

Re: [PATCH 1/2] sparc32: Move ioremap/iounmap declaration before asm-generic/io.h include

2020-09-15 Thread David Miller
From: Lorenzo Pieralisi Date: Tue, 15 Sep 2020 10:32:02 +0100 > Move the ioremap/iounmap declaration before asm-generic/io.h is > included so that it is visible within it. > > Signed-off-by: Lorenzo Pieralisi Acked-by: David S. Miller

[PATCH 1/2] sparc32: Move ioremap/iounmap declaration before asm-generic/io.h include

2020-09-15 Thread Lorenzo Pieralisi
Move the ioremap/iounmap declaration before asm-generic/io.h is included so that it is visible within it. Signed-off-by: Lorenzo Pieralisi Cc: "David S. Miller" --- arch/sparc/include/asm/io_32.h | 16 ++-- 1 file changed, 10 insertions(+), 6 deletions(-) diff --git a/

Re: [PATCH] fbdev: sm712fb: handle ioremap() errors in probe

2020-09-08 Thread Bartlomiej Zolnierkiewicz
On 7/13/20 10:05 AM, Evgeny Novikov wrote: > smtcfb_pci_probe() does not handle ioremap() errors for case 0x720. The > patch fixes that exactly like for case 0x710/2. > > Found by Linux Driver Verification project (linuxtesting.org). > > Signed-off-by: Evgeny Novikov Applie

[PATCH v7 2/9] RISC-V: Add early ioremap support

2020-08-28 Thread Atish Patra
UEFI uses early IO or memory mappings for runtime services before normal ioremap() is usable. Add the necessary fixmap bindings and pmd mappings for generic ioremap support to work. Signed-off-by: Atish Patra Reviewed-by: Anup Patel Reviewed-by: Palmer Dabbelt --- arch/riscv/Kconfig

[PATCH v7 04/12] mm/ioremap: rename ioremap_*_range to vmap_*_range

2020-08-25 Thread Nicholas Piggin
This will be used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 64 +++- 1 file changed, 33 insertions(+), 31 deletions(-) diff --git a/mm/ioremap.c b/mm/ioremap.c ind

[PATCH v6 04/12] mm/ioremap: rename ioremap_*_range to vmap_*_range

2020-08-21 Thread Nicholas Piggin
This will be used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 64 +++- 1 file changed, 33 insertions(+), 31 deletions(-) diff --git a/mm/ioremap.c b/mm/ioremap.c ind

Re: [PATCH v5 4/8] lib/ioremap: rename ioremap_*_range to vmap_*_range

2020-08-20 Thread Christoph Hellwig
On Fri, Aug 21, 2020 at 02:44:23PM +1000, Nicholas Piggin wrote: > This will be moved to mm/ and used as a generic kernel virtual mapping > function, so re-name it in preparation. > > Signed-off-by: Nicholas Piggin > --- > mm/ioremap.c | 55 ++-- >

[PATCH v5 4/8] lib/ioremap: rename ioremap_*_range to vmap_*_range

2020-08-20 Thread Nicholas Piggin
This will be moved to mm/ and used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 55 ++-- 1 file changed, 23 insertions(+), 32 deletions(-) diff --git a/mm/ioremap.c b

[PATCH v6 2/9] RISC-V: Add early ioremap support

2020-08-19 Thread Atish Patra
UEFI uses early IO or memory mappings for runtime services before normal ioremap() is usable. Add the necessary fixmap bindings and pmd mappings for generic ioremap support to work. Signed-off-by: Atish Patra Reviewed-by: Anup Patel Reviewed-by: Palmer Dabbelt --- arch/riscv/Kconfig

[PATCH v4 4/8] lib/ioremap: rename ioremap_*_range to vmap_*_range

2020-08-16 Thread Nicholas Piggin
This will be moved to mm/ and used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 55 ++-- 1 file changed, 23 insertions(+), 32 deletions(-) diff --git a/mm/ioremap.c b

Re: [PATCH v5 2/9] RISC-V: Add early ioremap support

2020-08-15 Thread Palmer Dabbelt
On Wed, 12 Aug 2020 16:47:51 PDT (-0700), Atish Patra wrote: UEFI uses early IO or memory mappings for runtime services before normal ioremap() is usable. Add the necessary fixmap bindings and pmd mappings for generic ioremap support to work. Signed-off-by: Atish Patra --- arch/riscv/Kconfig

[tip: x86/mm] x86/mm/64: Do not sync vmalloc/ioremap mappings

2020-08-15 Thread tip-bot2 for Joerg Roedel
: Ingo Molnar CommitterDate: Sat, 15 Aug 2020 13:56:16 +02:00 x86/mm/64: Do not sync vmalloc/ioremap mappings Remove the code to sync the vmalloc and ioremap ranges for x86-64. The page-table pages are all pre-allocated so that synchronization is no longer necessary. This is a patch that

[PATCH 0/2] x86: Retry to remove vmalloc/ioremap synchronzation

2020-08-14 Thread Joerg Roedel
From: Joerg Roedel Hi, as discussed here are the updates to the recent patches and fixes to pre-allocate the vmalloc/ioremap second-level page-table pages on x86-64. Patch one is a re-send of commit 8bb9bf242d1f ("x86/mm/64: Do not sync vmalloc/ioremap mappings")

[PATCH 1/2] x86/mm/64: Do not sync vmalloc/ioremap mappings

2020-08-14 Thread Joerg Roedel
From: Joerg Roedel Remove the code to sync the vmalloc and ioremap ranges for x86-64. The page-table pages are all pre-allocated so that synchronization is no longer necessary. This is a patch that already went into the kernel as: commit 8bb9bf242d1f ("x86/mm/64: Do not sync vm

Re: [PATCH v5 2/9] RISC-V: Add early ioremap support

2020-08-13 Thread Anup Patel
On Thu, Aug 13, 2020 at 5:18 AM Atish Patra wrote: > > UEFI uses early IO or memory mappings for runtime services before > normal ioremap() is usable. Add the necessary fixmap bindings and > pmd mappings for generic ioremap support to work. > > Signed-off-by: Atish Patra &

[PATCH v5 2/9] RISC-V: Add early ioremap support

2020-08-12 Thread Atish Patra
UEFI uses early IO or memory mappings for runtime services before normal ioremap() is usable. Add the necessary fixmap bindings and pmd mappings for generic ioremap support to work. Signed-off-by: Atish Patra --- arch/riscv/Kconfig | 1 + arch/riscv/include/asm/Kbuild | 1

[PATCH v3 4/8] lib/ioremap: rename ioremap_*_range to vmap_*_range

2020-08-09 Thread Nicholas Piggin
This will be moved to mm/ and used as a generic kernel virtual mapping function, so re-name it in preparation. Signed-off-by: Nicholas Piggin --- mm/ioremap.c | 55 ++-- 1 file changed, 23 insertions(+), 32 deletions(-) diff --git a/mm/ioremap.c b

[tip: x86/urgent] Revert "x86/mm/64: Do not sync vmalloc/ioremap mappings"

2020-08-06 Thread tip-bot2 for Ingo Molnar
: Ingo Molnar CommitterDate: Thu, 06 Aug 2020 15:11:03 +02:00 Revert "x86/mm/64: Do not sync vmalloc/ioremap mappings" This reverts commit 8bb9bf242d1fee925636353807c511d54fde8986. Jason reported that this causes a new oops in process_one_work(), and bisected it to this comm

[RFT PATCH v4 2/9] RISC-V: Add early ioremap support

2020-07-29 Thread Atish Patra
UEFI uses early IO or memory mappings for runtime services before normal ioremap() is usable. Add the necessary fixmap bindings and pmd mappings for generic ioremap support to work. Signed-off-by: Atish Patra --- arch/riscv/Kconfig | 1 + arch/riscv/include/asm/Kbuild | 1

[tip: x86/mm] x86/mm/64: Do not sync vmalloc/ioremap mappings

2020-07-27 Thread tip-bot2 for Joerg Roedel
: Ingo Molnar CommitterDate: Mon, 27 Jul 2020 12:32:29 +02:00 x86/mm/64: Do not sync vmalloc/ioremap mappings Remove the code to sync the vmalloc and ioremap ranges for x86-64. The page-table pages are all pre-allocated now so that synchronization is no longer necessary. Signed-off-by: Joerg

Re: [PATCH v3 0/3] x86/mm/64: Remove vmalloc/ioremap pgtable synchronization

2020-07-27 Thread Ingo Molnar
* Joerg Roedel wrote: > From: Joerg Roedel > > Hi, > > here is the third version of the patches to pre-allocate P4D/PUD pages > for the vmalloc/ioremap areas on x86-64. This makes the page-table > synchronization code obsolete and so it is also removed. > >

Re: [RFC PATCH] platform: ioremap: Build iomap functions even without HAS_IOMEM

2020-07-23 Thread Jonathan Cameron
stubs for > devm_platform_ioremap_resource() and its dependencies to build, we can > remove the HAS_IOMEM requirement here, rather than playing whack-a-mole > with different drivers which don't try to build against ARCH=um. > > The reason this works at the moment is that stub ioremap and iounmap >

Re: [RFC PATCH] platform: ioremap: Build iomap functions even without HAS_IOMEM

2020-07-21 Thread Brendan Higgins
nt stubs for > devm_platform_ioremap_resource() and its dependencies to build, we can > remove the HAS_IOMEM requirement here, rather than playing whack-a-mole > with different drivers which don't try to build against ARCH=um. > > The reason this works at the moment is that stub ioremap and iounmap > fun

Re: [PATCH v3 0/3] x86/mm/64: Remove vmalloc/ioremap pgtable synchronization

2020-07-21 Thread Mike Rapoport
On Tue, Jul 21, 2020 at 11:59:50AM +0200, Joerg Roedel wrote: > From: Joerg Roedel > > Hi, > > here is the third version of the patches to pre-allocate P4D/PUD pages > for the vmalloc/ioremap areas on x86-64. This makes the page-table > synchronization code obsolete and

[PATCH v3 0/3] x86/mm/64: Remove vmalloc/ioremap pgtable synchronization

2020-07-21 Thread Joerg Roedel
From: Joerg Roedel Hi, here is the third version of the patches to pre-allocate P4D/PUD pages for the vmalloc/ioremap areas on x86-64. This makes the page-table synchronization code obsolete and so it is also removed. Please review. Thanks, Joerg Changes to v2: - Rebased to

[PATCH v3 2/3] x86/mm/64: Do not sync vmalloc/ioremap mappings

2020-07-21 Thread Joerg Roedel
From: Joerg Roedel Remove the code to sync the vmalloc and ioremap ranges for x86-64. The page-table pages are all pre-allocated now so that synchronization is no longer necessary. Signed-off-by: Joerg Roedel --- arch/x86/include/asm/pgtable_64_types.h | 2 -- arch/x86/mm/init_64.c

[RFC PATCH] platform: ioremap: Build iomap functions even without HAS_IOMEM

2020-07-20 Thread David Gow
HAS_IOMEM requirement here, rather than playing whack-a-mole with different drivers which don't try to build against ARCH=um. The reason this works at the moment is that stub ioremap and iounmap functions were added to UML to support this sort-of thing[3]. This particular change doesn't requ

Re: ioremap and dma cleanups and fixes for superh (2nd resend)

2020-07-20 Thread Rich Felker
On Mon, Jul 20, 2020 at 10:53:26AM -0400, Rich Felker wrote: > On Mon, Jul 20, 2020 at 03:42:38PM +0200, John Paul Adrian Glaubitz wrote: > > Hi Christoph! > > > > On 7/20/20 3:38 PM, Christoph Hellwig wrote: > > > On Wed, Jul 15, 2020 at 01:12:33AM +0200, John Paul Adrian Glaubitz wrote: > > >> H

Re: ioremap and dma cleanups and fixes for superh (2nd resend)

2020-07-20 Thread Rich Felker
On Mon, Jul 20, 2020 at 03:42:38PM +0200, John Paul Adrian Glaubitz wrote: > Hi Christoph! > > On 7/20/20 3:38 PM, Christoph Hellwig wrote: > > On Wed, Jul 15, 2020 at 01:12:33AM +0200, John Paul Adrian Glaubitz wrote: > >> Hello! > >> > >> I have applied Christoph's full series on top of Linus' t

Re: ioremap and dma cleanups and fixes for superh (2nd resend)

2020-07-20 Thread John Paul Adrian Glaubitz
Hi Christoph! On 7/20/20 3:38 PM, Christoph Hellwig wrote: > On Wed, Jul 15, 2020 at 01:12:33AM +0200, John Paul Adrian Glaubitz wrote: >> Hello! >> >> I have applied Christoph's full series on top of Linus' tree and I can >> confirm that >> the kernel boots fine on my SH-7785LCR board. >> >> Thu

Re: ioremap and dma cleanups and fixes for superh (2nd resend)

2020-07-20 Thread Christoph Hellwig
On Wed, Jul 15, 2020 at 01:12:33AM +0200, John Paul Adrian Glaubitz wrote: > Hello! > > I have applied Christoph's full series on top of Linus' tree and I can > confirm that > the kernel boots fine on my SH-7785LCR board. > > Thus, for the whole series of patches: > > Tested-by: John Paul Adria

[PATCH v11 2/5] iommu/arm-smmu: ioremap smmu mmio region before implementation init

2020-07-18 Thread Krishna Reddy
ioremap smmu mmio region before calling into implementation init. This is necessary to allow mapped address available during vendor specific implementation init. Reviewed-by: Jon Hunter Reviewed-by: Nicolin Chen Reviewed-by: Pritesh Raithatha Reviewed-by: Robin Murphy Reviewed-by: Thierry

[RFT PATCH v3 2/9] RISC-V: Add early ioremap support

2020-07-16 Thread Atish Patra
UEFI uses early IO or memory mappings for runtime services before normal ioremap() is usable. Add the necessary fixmap bindings and pmd mappings for generic ioremap support to work. Signed-off-by: Atish Patra --- arch/riscv/Kconfig | 1 + arch/riscv/include/asm/Kbuild | 1

Re: ioremap and dma cleanups and fixes for superh (2nd resend)

2020-07-16 Thread John Paul Adrian Glaubitz
On 7/16/20 9:28 PM, Peter Zijlstra wrote: > For some reason I had a whole bunch of junk left in my checkout and had > to basically: rm `git status -s | awk '{print $2}'`. > > Sorry for the noise. > > OK, let me go try my own patches :-) FWIW, I just successfully built the "defconfig" configurati

  1   2   3   4   5   6   7   8   9   10   >