Re: [RFC PATCH 1/2] xen/unpopulated-alloc: Introduce helpers for DMA allocations

2022-06-16 Thread Roger Pau Monné
On Tue, Jun 14, 2022 at 05:45:53PM -0700, Stefano Stabellini wrote: > Basically, if we allocate (and free) page-by-page it leads to more > efficient resource utilization but it is slower. If we allocate larger > contiguous chunks it is faster but it leads to less efficient resource > utilization.

Re: [RFC PATCH 1/2] xen/unpopulated-alloc: Introduce helpers for DMA allocations

2022-06-15 Thread Oleksandr
On 15.06.22 03:45, Stefano Stabellini wrote: Hello Stefano On Tue, 14 Jun 2022, Oleksandr wrote: On 11.06.22 03:12, Stefano Stabellini wrote: On Wed, 8 Jun 2022, Oleksandr wrote: 2. Drop the "page_list" entirely and use "dma_pool" for all (contiguous and non-contiguous) allocations.

Re: [RFC PATCH 1/2] xen/unpopulated-alloc: Introduce helpers for DMA allocations

2022-06-14 Thread Stefano Stabellini
On Tue, 14 Jun 2022, Oleksandr wrote: > On 11.06.22 03:12, Stefano Stabellini wrote: > > On Wed, 8 Jun 2022, Oleksandr wrote: > > > 2. Drop the "page_list" entirely and use "dma_pool" for all (contiguous > > > and > > > non-contiguous) allocations. After all, all pages are initially contiguous > >

Re: [RFC PATCH 1/2] xen/unpopulated-alloc: Introduce helpers for DMA allocations

2022-06-14 Thread Oleksandr
On 11.06.22 03:12, Stefano Stabellini wrote: Hello Stefano On Wed, 8 Jun 2022, Oleksandr wrote: 2. Drop the "page_list" entirely and use "dma_pool" for all (contiguous and non-contiguous) allocations. After all, all pages are initially contiguous in fill_list() as they are built from the

Re: [RFC PATCH 1/2] xen/unpopulated-alloc: Introduce helpers for DMA allocations

2022-06-10 Thread Stefano Stabellini
On Wed, 8 Jun 2022, Oleksandr wrote: > 2. Drop the "page_list" entirely and use "dma_pool" for all (contiguous and > non-contiguous) allocations. After all, all pages are initially contiguous in > fill_list() as they are built from the resource. This changes behavior for all > users of

Re: [RFC PATCH 1/2] xen/unpopulated-alloc: Introduce helpers for DMA allocations

2022-06-08 Thread Oleksandr
On 04.06.22 00:52, Stefano Stabellini wrote: Hello Stefano Thank you for having a look and sorry for the late response. On Tue, 17 May 2022, Oleksandr Tyshchenko wrote: From: Oleksandr Tyshchenko Add ability to allocate unpopulated DMAable (contiguous) pages suitable for grant mapping

Re: [RFC PATCH 1/2] xen/unpopulated-alloc: Introduce helpers for DMA allocations

2022-06-03 Thread Stefano Stabellini
On Tue, 17 May 2022, Oleksandr Tyshchenko wrote: > From: Oleksandr Tyshchenko > > Add ability to allocate unpopulated DMAable (contiguous) pages > suitable for grant mapping into. This is going to be used by gnttab > code (see gnttab_dma_alloc_pages()). > > TODO: There is a code duplication in

[RFC PATCH 1/2] xen/unpopulated-alloc: Introduce helpers for DMA allocations

2022-05-17 Thread Oleksandr Tyshchenko
From: Oleksandr Tyshchenko Add ability to allocate unpopulated DMAable (contiguous) pages suitable for grant mapping into. This is going to be used by gnttab code (see gnttab_dma_alloc_pages()). TODO: There is a code duplication in fill_dma_pool(). Also pool oparations likely need to be