Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-10 Thread Felix Kuehling
On 2021-12-09 8:31 p.m., Alistair Popple wrote: On Friday, 10 December 2021 3:54:31 AM AEDT Sierra Guiza, Alejandro (Alex) wrote: On 12/9/2021 10:29 AM, Felix Kuehling wrote: Am 2021-12-09 um 5:53 a.m. schrieb Alistair Popple: On Thursday, 9 December 2021 5:55:26 AM AEDT Sierra Guiza, Alejand

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-09 Thread Alistair Popple
On Friday, 10 December 2021 3:54:31 AM AEDT Sierra Guiza, Alejandro (Alex) wrote: > > On 12/9/2021 10:29 AM, Felix Kuehling wrote: > > Am 2021-12-09 um 5:53 a.m. schrieb Alistair Popple: > >> On Thursday, 9 December 2021 5:55:26 AM AEDT Sierra Guiza, Alejandro > >> (Alex) wrote: > >>> On 12/8/20

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-09 Thread Felix Kuehling
Am 2021-12-09 um 5:53 a.m. schrieb Alistair Popple: > On Thursday, 9 December 2021 5:55:26 AM AEDT Sierra Guiza, Alejandro (Alex) > wrote: >> On 12/8/2021 11:30 AM, Felix Kuehling wrote: >>> Am 2021-12-08 um 11:58 a.m. schrieb Felix Kuehling: Am 2021-12-08 um 6:31 a.m. schrieb Alistair Popple

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-09 Thread Sierra Guiza, Alejandro (Alex)
On 12/9/2021 10:29 AM, Felix Kuehling wrote: Am 2021-12-09 um 5:53 a.m. schrieb Alistair Popple: On Thursday, 9 December 2021 5:55:26 AM AEDT Sierra Guiza, Alejandro (Alex) wrote: On 12/8/2021 11:30 AM, Felix Kuehling wrote: Am 2021-12-08 um 11:58 a.m. schrieb Felix Kuehling: Am 2021-12-08

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-09 Thread Alistair Popple
On Thursday, 9 December 2021 5:55:26 AM AEDT Sierra Guiza, Alejandro (Alex) wrote: > > On 12/8/2021 11:30 AM, Felix Kuehling wrote: > > Am 2021-12-08 um 11:58 a.m. schrieb Felix Kuehling: > >> Am 2021-12-08 um 6:31 a.m. schrieb Alistair Popple: > >>> On Tuesday, 7 December 2021 5:52:43 AM AEDT Al

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-09 Thread Jason Gunthorpe
On Thu, Dec 09, 2021 at 12:45:24PM +1100, Alistair Popple wrote: > On Thursday, 9 December 2021 12:53:45 AM AEDT Jason Gunthorpe wrote: > > > I think a similar problem exists for device private fault handling as > > > well and > > > it has been on my list of things to fix for a while. I think the

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-09 Thread Alistair Popple
On Thursday, 9 December 2021 12:53:45 AM AEDT Jason Gunthorpe wrote: > > I think a similar problem exists for device private fault handling as well > > and > > it has been on my list of things to fix for a while. I think the solution > > is to > > call try_get_page(), except it doesn't work with

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-08 Thread Sierra Guiza, Alejandro (Alex)
On 12/8/2021 11:30 AM, Felix Kuehling wrote: Am 2021-12-08 um 11:58 a.m. schrieb Felix Kuehling: Am 2021-12-08 um 6:31 a.m. schrieb Alistair Popple: On Tuesday, 7 December 2021 5:52:43 AM AEDT Alex Sierra wrote: Avoid long term pinning for Coherent device type pages. This could interfere wit

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-08 Thread Felix Kuehling
Am 2021-12-08 um 11:58 a.m. schrieb Felix Kuehling: > Am 2021-12-08 um 6:31 a.m. schrieb Alistair Popple: >> On Tuesday, 7 December 2021 5:52:43 AM AEDT Alex Sierra wrote: >>> Avoid long term pinning for Coherent device type pages. This could >>> interfere with their own device memory manager. >>

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-08 Thread Felix Kuehling
Am 2021-12-08 um 6:31 a.m. schrieb Alistair Popple: > On Tuesday, 7 December 2021 5:52:43 AM AEDT Alex Sierra wrote: >> Avoid long term pinning for Coherent device type pages. This could >> interfere with their own device memory manager. >> If caller tries to get user device coherent pages with PIN

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-08 Thread Jason Gunthorpe
On Wed, Dec 08, 2021 at 10:31:58PM +1100, Alistair Popple wrote: > On Tuesday, 7 December 2021 5:52:43 AM AEDT Alex Sierra wrote: > > Avoid long term pinning for Coherent device type pages. This could > > interfere with their own device memory manager. > > If caller tries to get user device coheren

Re: [PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-08 Thread Alistair Popple
On Tuesday, 7 December 2021 5:52:43 AM AEDT Alex Sierra wrote: > Avoid long term pinning for Coherent device type pages. This could > interfere with their own device memory manager. > If caller tries to get user device coherent pages with PIN_LONGTERM flag > set, those pages will be migrated back t

[PATCH v2 03/11] mm/gup: migrate PIN_LONGTERM dev coherent pages to system

2021-12-06 Thread Alex Sierra
Avoid long term pinning for Coherent device type pages. This could interfere with their own device memory manager. If caller tries to get user device coherent pages with PIN_LONGTERM flag set, those pages will be migrated back to system memory. Signed-off-by: Alex Sierra --- mm/gup.c | 32 ++