Re: [PATCH 1/6] swap: Add comments to lock_cluster_or_swap_info()

2018-07-13 Thread Huang, Ying
Dave Hansen writes: >> +/* >> + * At most times, fine grained cluster lock is sufficient to protect > > Can we call out those times, please? To protect si->swap_map[], if HDD, si->lock is used, otherwise cluster lock is used. "at most times" is ambiguous here, I will fix it. >> + * the operati

Re: [PATCH 1/6] swap: Add comments to lock_cluster_or_swap_info()

2018-07-13 Thread Dave Hansen
> +/* > + * At most times, fine grained cluster lock is sufficient to protect Can we call out those times, please? > + * the operations on sis->swap_map. Please be careful with the naming. You can call it 'si' because that's what the function argument is named. Or, swap_info_struct because t

[PATCH 1/6] swap: Add comments to lock_cluster_or_swap_info()

2018-07-12 Thread Huang, Ying
From: Huang Ying To improve the code readability. Signed-off-by: "Huang, Ying" Suggested-by: Dave Hansen Cc: Michal Hocko Cc: Johannes Weiner Cc: Shaohua Li Cc: Hugh Dickins Cc: Minchan Kim Cc: Rik van Riel Cc: Daniel Jordan Cc: Dan Williams --- mm/swapfile.c | 6 ++ 1 file change