Re: [PATCH net] xsk: remove cheap_dma optimization

2020-07-08 Thread Robin Murphy
On 2020-07-08 07:50, Christoph Hellwig wrote: On Mon, Jun 29, 2020 at 04:41:16PM +0100, Robin Murphy wrote: On 2020-06-28 18:16, Bj�rn T�pel wrote: On 2020-06-27 09:04, Christoph Hellwig wrote: On Sat, Jun 27, 2020 at 01:00:19AM +0200, Daniel Borkmann wrote: Given there is roughly a ~5

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-07-08 Thread Christoph Hellwig
On Wed, Jul 08, 2020 at 07:57:23AM +, Song Bao Hua (Barry Song) wrote: > > int dma_map_batch_start(struct device *dev, size_t rounded_len, > > enum dma_data_direction dir, unsigned long attrs, dma_addr_t *addr); > > int dma_map_batch_add(struct device *dev, dma_addr_t *addr, struct page >

RE: [PATCH net] xsk: remove cheap_dma optimization

2020-07-08 Thread Song Bao Hua (Barry Song)
lanox.com; > konrad.w...@oracle.com; jonathan.le...@gmail.com; > linux-ker...@vger.kernel.org; iommu@lists.linux-foundation.org; > net...@vger.kernel.org; b...@vger.kernel.org; da...@davemloft.net; > magnus.karls...@intel.com > Subject: Re: [PATCH net] xsk: remove cheap_dma optimization >

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-07-08 Thread Christoph Hellwig
On Mon, Jun 29, 2020 at 04:41:16PM +0100, Robin Murphy wrote: > On 2020-06-28 18:16, Björn Töpel wrote: >> >> On 2020-06-27 09:04, Christoph Hellwig wrote: >>> On Sat, Jun 27, 2020 at 01:00:19AM +0200, Daniel Borkmann wrote: Given there is roughly a ~5 weeks window at max where this removal

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-07-01 Thread Björn Töpel
On 2020-06-29 17:41, Robin Murphy wrote: On 2020-06-28 18:16, Björn Töpel wrote: [...]> Somewhat related to the DMA API; It would have performance benefits for AF_XDP if the DMA range of the mapped memory was linear, i.e. by IOMMU utilization. I've started hacking a thing a little bit, but it

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-30 Thread Daniel Borkmann
On 6/30/20 7:07 AM, Christoph Hellwig wrote: On Mon, Jun 29, 2020 at 05:18:38PM +0200, Daniel Borkmann wrote: On 6/29/20 5:10 PM, Björn Töpel wrote: On 2020-06-29 15:52, Daniel Borkmann wrote: Ok, fair enough, please work with DMA folks to get this properly integrated and restored then.

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-29 Thread Christoph Hellwig
On Mon, Jun 29, 2020 at 05:18:38PM +0200, Daniel Borkmann wrote: > On 6/29/20 5:10 PM, Björn Töpel wrote: >> On 2020-06-29 15:52, Daniel Borkmann wrote: >>> >>> Ok, fair enough, please work with DMA folks to get this properly integrated >>> and >>> restored then. Applied, thanks! >> >> Daniel,

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-29 Thread Björn Töpel
On 2020-06-29 17:18, Daniel Borkmann wrote: Nice, tossed from bpf tree then! (Looks like it didn't land on the bpf list yet, but seems other mails are currently stuck as well on vger. I presume it will be routed to Linus via Christoph?) Thanks! Christoph (according to the other mail) was

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-29 Thread Robin Murphy
On 2020-06-28 18:16, Björn Töpel wrote: On 2020-06-27 09:04, Christoph Hellwig wrote: On Sat, Jun 27, 2020 at 01:00:19AM +0200, Daniel Borkmann wrote: Given there is roughly a ~5 weeks window at max where this removal could still be applied in the worst case, could we come up with a fix /

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-29 Thread Daniel Borkmann
On 6/29/20 5:10 PM, Björn Töpel wrote: On 2020-06-29 15:52, Daniel Borkmann wrote: Ok, fair enough, please work with DMA folks to get this properly integrated and restored then. Applied, thanks! Daniel, you were too quick! Please revert this one; Christoph just submitted a 4-patch-series

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-29 Thread Björn Töpel
On 2020-06-29 15:52, Daniel Borkmann wrote: Ok, fair enough, please work with DMA folks to get this properly integrated and restored then. Applied, thanks! Daniel, you were too quick! Please revert this one; Christoph just submitted a 4-patch-series that addresses both the DMA API, and the

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-29 Thread Daniel Borkmann
On 6/28/20 7:16 PM, Björn Töpel wrote: On 2020-06-27 09:04, Christoph Hellwig wrote: On Sat, Jun 27, 2020 at 01:00:19AM +0200, Daniel Borkmann wrote: Given there is roughly a ~5 weeks window at max where this removal could still be applied in the worst case, could we come up with a fix /

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-28 Thread Björn Töpel
On 2020-06-27 09:04, Christoph Hellwig wrote: On Sat, Jun 27, 2020 at 01:00:19AM +0200, Daniel Borkmann wrote: Given there is roughly a ~5 weeks window at max where this removal could still be applied in the worst case, could we come up with a fix / proposal first that moves this into the DMA

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-27 Thread Christoph Hellwig
On Sat, Jun 27, 2020 at 01:00:19AM +0200, Daniel Borkmann wrote: > Given there is roughly a ~5 weeks window at max where this removal could > still be applied in the worst case, could we come up with a fix / proposal > first that moves this into the DMA mapping core? If there is something that >

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-26 Thread Daniel Borkmann
On 6/26/20 3:43 PM, Björn Töpel wrote: From: Björn Töpel When the AF_XDP buffer allocation API was introduced it had an optimization, "cheap_dma". The idea was that when the umem was DMA mapped, the pool also checked whether the mapping required a synchronization (CPU to device, and vice

Re: [PATCH net] xsk: remove cheap_dma optimization

2020-06-26 Thread Jonathan Lemon
On Fri, Jun 26, 2020 at 03:43:58PM +0200, Björn Töpel wrote: > From: Björn Töpel > > When the AF_XDP buffer allocation API was introduced it had an > optimization, "cheap_dma". The idea was that when the umem was DMA > mapped, the pool also checked whether the mapping required a >