Re: [PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Song Liu
> On Jun 13, 2019, at 9:47 AM, Song Liu wrote: > > Hi Kirill, > >> On Jun 13, 2019, at 8:24 AM, Song Liu wrote: >> >> >> >>> On Jun 13, 2019, at 8:14 AM, Kirill A. Shutemov >>> wrote: >>> >>> On Thu, Jun 13, 2019 at 03:03:01PM +, Song Liu wrote: > On Jun 13, 2019, a

[PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Song Liu
This patches introduces a new foll_flag: FOLL_SPLIT_PMD. As the name says FOLL_SPLIT_PMD splits huge pmd for given mm_struct, the underlining huge page stays as-is. FOLL_SPLIT_PMD is useful for cases where we need to use regular pages, but would switch back to huge page and huge pmd on. One of suc

Re: [PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Song Liu
Hi Kirill, > On Jun 13, 2019, at 8:24 AM, Song Liu wrote: > > > >> On Jun 13, 2019, at 8:14 AM, Kirill A. Shutemov >> wrote: >> >> On Thu, Jun 13, 2019 at 03:03:01PM +, Song Liu wrote: >>> >>> On Jun 13, 2019, at 7:16 AM, Kirill A. Shutemov wrote: On Thu, Jun 13

Re: [PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Song Liu
> On Jun 13, 2019, at 8:14 AM, Kirill A. Shutemov > wrote: > > On Thu, Jun 13, 2019 at 03:03:01PM +, Song Liu wrote: >> >> >>> On Jun 13, 2019, at 7:16 AM, Kirill A. Shutemov >>> wrote: >>> >>> On Thu, Jun 13, 2019 at 01:57:30PM +, Song Liu wrote: > And I'm not convinced that

Re: [PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Kirill A. Shutemov
On Wed, Jun 12, 2019 at 03:03:17PM -0700, Song Liu wrote: > This patches introduces a new foll_flag: FOLL_SPLIT_PMD. As the name says > FOLL_SPLIT_PMD splits huge pmd for given mm_struct, the underlining huge > page stays as-is. > > FOLL_SPLIT_PMD is useful for cases where we need to use regular p

Re: [PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Kirill A. Shutemov
On Thu, Jun 13, 2019 at 03:03:01PM +, Song Liu wrote: > > > > On Jun 13, 2019, at 7:16 AM, Kirill A. Shutemov > > wrote: > > > > On Thu, Jun 13, 2019 at 01:57:30PM +, Song Liu wrote: > >>> And I'm not convinced that it belongs here at all. User requested PMD > >>> split and it is done

Re: [PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Song Liu
> On Jun 13, 2019, at 5:57 AM, Kirill A. Shutemov wrote: > > On Wed, Jun 12, 2019 at 03:03:17PM -0700, Song Liu wrote: >> This patches introduces a new foll_flag: FOLL_SPLIT_PMD. As the name says >> FOLL_SPLIT_PMD splits huge pmd for given mm_struct, the underlining huge >> page stays as-is. >

Re: [PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Kirill A. Shutemov
On Thu, Jun 13, 2019 at 01:57:30PM +, Song Liu wrote: > > And I'm not convinced that it belongs here at all. User requested PMD > > split and it is done after split_huge_pmd(). The rest can be handled by > > the caller as needed. > > I put this part here because split_huge_pmd() for file-backe

Re: [PATCH v3 3/5] mm, thp: introduce FOLL_SPLIT_PMD

2019-06-13 Thread Song Liu
> On Jun 13, 2019, at 7:16 AM, Kirill A. Shutemov wrote: > > On Thu, Jun 13, 2019 at 01:57:30PM +, Song Liu wrote: >>> And I'm not convinced that it belongs here at all. User requested PMD >>> split and it is done after split_huge_pmd(). The rest can be handled by >>> the caller as needed.