[PATCH v2] f2fs: shrink spinlock coverage

2020-05-08 Thread Chao Yu
In f2fs_try_to_free_nids(), .nid_list_lock spinlock critical region will increase as expected shrink number increase, to avoid spining other CPUs for long time, we change to release nid caches with small batch each time under .nid_list_lock coverage. Signed-off-by: Chao Yu --- v2: - shrink free

Re: [PATCH v2] f2fs: shrink spinlock coverage

2020-05-07 Thread Jaegeuk Kim
On 05/07, Chao Yu wrote: > On 2020/5/6 23:05, Jaegeuk Kim wrote: > > On 05/06, Chao Yu wrote: > >> In f2fs_try_to_free_nids(), .nid_list_lock spinlock critical region will > >> increase as expected shrink number increase, to avoid spining other CPUs > >> for long time, it's better to implement

Re: [PATCH v2] f2fs: shrink spinlock coverage

2020-05-06 Thread Chao Yu
On 2020/5/6 23:05, Jaegeuk Kim wrote: > On 05/06, Chao Yu wrote: >> In f2fs_try_to_free_nids(), .nid_list_lock spinlock critical region will >> increase as expected shrink number increase, to avoid spining other CPUs >> for long time, it's better to implement like extent cache and nats >>

Re: [PATCH v2] f2fs: shrink spinlock coverage

2020-05-06 Thread Jaegeuk Kim
On 05/06, Chao Yu wrote: > In f2fs_try_to_free_nids(), .nid_list_lock spinlock critical region will > increase as expected shrink number increase, to avoid spining other CPUs > for long time, it's better to implement like extent cache and nats > shrinker. > > Signed-off-by: Chao Yu > --- > v2: >

[PATCH v2] f2fs: shrink spinlock coverage

2020-05-06 Thread Chao Yu
In f2fs_try_to_free_nids(), .nid_list_lock spinlock critical region will increase as expected shrink number increase, to avoid spining other CPUs for long time, it's better to implement like extent cache and nats shrinker. Signed-off-by: Chao Yu --- v2: - fix unlock wrong spinlock.