Re: [Xen-devel] [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64

2019-09-11 Thread Stefano Stabellini
On Wed, 11 Sep 2019, Peng Fan wrote: > > Subject: Re: [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64 > > > > + Juergen, Boris > > > > On Fri, 30 Aug 2019, Christoph Hellwig wrote: > > > Can we take a step back and figure out what we want to do here? > > > > > > AFAICS this function allocates

Re: [Xen-devel] [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64

2019-09-10 Thread Peng Fan
> Subject: Re: [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64 > > + Juergen, Boris > > On Fri, 30 Aug 2019, Christoph Hellwig wrote: > > Can we take a step back and figure out what we want to do here? > > > > AFAICS this function allocates memory for the swiotlb-xen buffer, and > > that

Re: [Xen-devel] [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64

2019-09-03 Thread Juergen Gross
On 02.09.19 17:57, Christoph Hellwig wrote: On Fri, Aug 30, 2019 at 07:40:42PM -0700, Stefano Stabellini wrote: + Juergen, Boris On Fri, 30 Aug 2019, Christoph Hellwig wrote: Can we take a step back and figure out what we want to do here? AFAICS this function allocates memory for the

Re: [Xen-devel] [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64

2019-09-02 Thread Christoph Hellwig
On Fri, Aug 30, 2019 at 07:40:42PM -0700, Stefano Stabellini wrote: > + Juergen, Boris > > On Fri, 30 Aug 2019, Christoph Hellwig wrote: > > Can we take a step back and figure out what we want to do here? > > > > AFAICS this function allocates memory for the swiotlb-xen buffer, > > and that

Re: [Xen-devel] [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64

2019-08-30 Thread Stefano Stabellini
+ Juergen, Boris On Fri, 30 Aug 2019, Christoph Hellwig wrote: > Can we take a step back and figure out what we want to do here? > > AFAICS this function allocates memory for the swiotlb-xen buffer, > and that means it must be <= 32-bit addressable to satisfy the DMA API > guarantees. That

Re: [Xen-devel] [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64

2019-08-30 Thread Christoph Hellwig
Can we take a step back and figure out what we want to do here? AFAICS this function allocates memory for the swiotlb-xen buffer, and that means it must be <= 32-bit addressable to satisfy the DMA API guarantees. That means we generally want to use GFP_DMA32 everywhere that exists, but on

Re: [Xen-devel] [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64

2019-08-30 Thread Julien Grall
Hi Peng, On 30/08/2019 04:28, Peng Fan wrote: > From: Peng Fan > > arm64 shares some code under arch/arm/xen, including mm.c. > However ZONE_DMA is removed by commit > ad67f5a6545("arm64: replace ZONE_DMA with ZONE_DMA32"). > So introduce xen_set_gfp_dma for arm32/arm64 and using __GFP_DMA >

[Xen-devel] [PATCH V2] arm: xen: mm: use __GPF_DMA32 for arm64

2019-08-29 Thread Peng Fan
From: Peng Fan arm64 shares some code under arch/arm/xen, including mm.c. However ZONE_DMA is removed by commit ad67f5a6545("arm64: replace ZONE_DMA with ZONE_DMA32"). So introduce xen_set_gfp_dma for arm32/arm64 and using __GFP_DMA for the former and __GFP_DMA32 for the latter. Signed-off-by: