Re: [PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-12-03 Thread Huang, Ying
Daniel Jordan writes: > On Sat, Dec 01, 2018 at 08:34:06AM +0800, Huang, Ying wrote: >> Daniel Jordan writes: >> > What do you think? >> >> I think that swapoff() which is the main user of try_to_unuse() isn't a >> common operation in practical. So it's not necessary to make it more >>

Re: [PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-12-03 Thread Huang, Ying
Daniel Jordan writes: > On Sat, Dec 01, 2018 at 08:34:06AM +0800, Huang, Ying wrote: >> Daniel Jordan writes: >> > What do you think? >> >> I think that swapoff() which is the main user of try_to_unuse() isn't a >> common operation in practical. So it's not necessary to make it more >>

Re: [PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-12-03 Thread Daniel Jordan
On Sat, Dec 01, 2018 at 08:34:06AM +0800, Huang, Ying wrote: > Daniel Jordan writes: > > What do you think? > > I think that swapoff() which is the main user of try_to_unuse() isn't a > common operation in practical. So it's not necessary to make it more > complex for this. Ok, probably not

Re: [PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-12-03 Thread Daniel Jordan
On Sat, Dec 01, 2018 at 08:34:06AM +0800, Huang, Ying wrote: > Daniel Jordan writes: > > What do you think? > > I think that swapoff() which is the main user of try_to_unuse() isn't a > common operation in practical. So it's not necessary to make it more > complex for this. Ok, probably not

Re: [PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-11-30 Thread Huang, Ying
Hi, Daniel, Daniel Jordan writes: > Hi Ying, > > On Tue, Nov 20, 2018 at 04:54:36PM +0800, Huang Ying wrote: >> diff --git a/mm/swap_state.c b/mm/swap_state.c >> index 97831166994a..1eedbc0aede2 100644 >> --- a/mm/swap_state.c >> +++ b/mm/swap_state.c >> @@ -387,14 +389,42 @@ struct page

Re: [PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-11-30 Thread Huang, Ying
Hi, Daniel, Daniel Jordan writes: > Hi Ying, > > On Tue, Nov 20, 2018 at 04:54:36PM +0800, Huang Ying wrote: >> diff --git a/mm/swap_state.c b/mm/swap_state.c >> index 97831166994a..1eedbc0aede2 100644 >> --- a/mm/swap_state.c >> +++ b/mm/swap_state.c >> @@ -387,14 +389,42 @@ struct page

Re: [PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-11-30 Thread Daniel Jordan
Hi Ying, On Tue, Nov 20, 2018 at 04:54:36PM +0800, Huang Ying wrote: > diff --git a/mm/swap_state.c b/mm/swap_state.c > index 97831166994a..1eedbc0aede2 100644 > --- a/mm/swap_state.c > +++ b/mm/swap_state.c > @@ -387,14 +389,42 @@ struct page *__read_swap_cache_async(swp_entry_t entry, > gfp_t

Re: [PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-11-30 Thread Daniel Jordan
Hi Ying, On Tue, Nov 20, 2018 at 04:54:36PM +0800, Huang Ying wrote: > diff --git a/mm/swap_state.c b/mm/swap_state.c > index 97831166994a..1eedbc0aede2 100644 > --- a/mm/swap_state.c > +++ b/mm/swap_state.c > @@ -387,14 +389,42 @@ struct page *__read_swap_cache_async(swp_entry_t entry, > gfp_t

[PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-11-20 Thread Huang Ying
To swapin a THP in one piece, we need to read a huge swap cluster from the swap device. This patch revised the __read_swap_cache_async() and its callers and callees to support this. If __read_swap_cache_async() find the swap cluster of the specified swap entry is huge, it will try to allocate a

[PATCH -V7 RESEND 08/21] swap: Support to read a huge swap cluster for swapin a THP

2018-11-20 Thread Huang Ying
To swapin a THP in one piece, we need to read a huge swap cluster from the swap device. This patch revised the __read_swap_cache_async() and its callers and callees to support this. If __read_swap_cache_async() find the swap cluster of the specified swap entry is huge, it will try to allocate a