Re: [PoC] arm: dma-mapping: direct: Apply dma_pfn_offset only when it is valid

2020-01-30 Thread Peter Ujfalusi via iommu
On 30/01/2020 9.53, Christoph Hellwig wrote: > [skipping the DT bits, as I'm everything but an expert on that..] > > On Mon, Jan 27, 2020 at 04:00:30PM +0200, Peter Ujfalusi wrote: >> I agree on the phys_to_dma(). It should fail for addresses which does >> not fall into any of the ranges. >> It

Re: [PATCH] dma-contiguous: CMA: give precedence to cmdline

2020-01-30 Thread Christoph Hellwig
I've picked this up for Linux 5.6, sorry for the delay. ___ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu

Re: [PATCH v2] iommu/arm-smmu-v3: Add SMMUv3.2 range invalidation support

2020-01-30 Thread Auger Eric
Hi Rob, On 1/17/20 10:16 PM, Rob Herring wrote: > Arm SMMUv3.2 adds support for TLB range invalidate operations. > Support for range invalidate is determined by the RIL bit in the IDR3 > register. > > The range invalidate is in units of the leaf page size and operates on > 1-32 chunks of a power o

Re: [PATCH] dma-contiguous: CMA: give precedence to cmdline

2020-01-30 Thread Nicolas Saenz Julienne
On Thu Jan 30, 2020 at 2:42 PM, Christoph Hellwig wrote: > I've picked this up for Linux 5.6, sorry for the delay. Thanks! ___ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu

Re: [PoC] arm: dma-mapping: direct: Apply dma_pfn_offset only when it is valid

2020-01-30 Thread Christoph Hellwig
On Thu, Jan 30, 2020 at 03:04:37PM +0200, Peter Ujfalusi via iommu wrote: > On 30/01/2020 9.53, Christoph Hellwig wrote: > > [skipping the DT bits, as I'm everything but an expert on that..] > > > > On Mon, Jan 27, 2020 at 04:00:30PM +0200, Peter Ujfalusi wrote: > >> I agree on the phys_to_dma().

Re: [PATCH v2] iommu/arm-smmu-v3: Add SMMUv3.2 range invalidation support

2020-01-30 Thread Robin Murphy
On 30/01/2020 3:06 pm, Auger Eric wrote: Hi Rob, On 1/17/20 10:16 PM, Rob Herring wrote: Arm SMMUv3.2 adds support for TLB range invalidate operations. Support for range invalidate is determined by the RIL bit in the IDR3 register. The range invalidate is in units of the leaf page size and oper

[PATCH] dma-debug: dynamic allocation of hash table

2020-01-30 Thread Eric Dumazet via iommu
Increasing the size of dma_entry_hash size by 327680 bytes has reached some bootloaders limitations. Simply use dynamic allocations instead, and take this opportunity to increase the hash table to 65536 buckets. Finally my 40Gbit mlx4 NIC can sustain line rate with CONFIG_DMA_API_DEBUG=y. Fixes:

[PATCH] dma-debug: add a per-cpu cache to avoid lock contention

2020-01-30 Thread Eric Dumazet via iommu
Networking drivers very often have to replace one page with another for their RX ring buffers. A multi-queue NIC will severly hit a contention point in dma-debug while grabbing free_entries_lock spinlock. Adding a one entry per-cpu cache removes the need to grab this spinlock twice per page repla

Re: [PATCH] dma-debug: dynamic allocation of hash table

2020-01-30 Thread Robin Murphy
Hi Eric, On 2020-01-30 7:10 pm, Eric Dumazet via iommu wrote: Increasing the size of dma_entry_hash size by 327680 bytes has reached some bootloaders limitations. [ That might warrant some further explanation - I don't quite follow how this would relate to a bootloader specifically :/ ] Si

Re: [PATCH] dma-debug: dynamic allocation of hash table

2020-01-30 Thread Eric Dumazet via iommu
On Thu, Jan 30, 2020 at 3:46 PM Robin Murphy wrote: > > Hi Eric, > > On 2020-01-30 7:10 pm, Eric Dumazet via iommu wrote: > > Increasing the size of dma_entry_hash size by 327680 bytes > > has reached some bootloaders limitations. > > [ That might warrant some further explanation - I don't quite f