On Thu, Oct 24, 2024 at 12:45 PM Michal Hocko <mhocko@xxxxxxxx> wrote: > > On Thu 24-10-24 10:26:15, Shakeel Butt wrote: > > On Thu, Oct 24, 2024 at 04:50:37PM GMT, Roman Gushchin wrote: > > > On Wed, Oct 23, 2024 at 11:57:12PM -0700, Shakeel Butt wrote: > > > > The memcg v1's charge move feature has been deprecated. There is no need > > > > to have any locking or protection against the moving charge. Let's > > > > proceed to remove all the locking code related to charge moving. > > > > > > > > Signed-off-by: Shakeel Butt <shakeel.butt@xxxxxxxxx> > > > > > > Reviewed-by: Roman Gushchin <roman.gushchin@xxxxxxxxx> > > > > Thanks Roman for the review. Based on Michal's question, I am planning > > to keep the RCU locking in the next version of this patch and folowup > > with clear understanding where we really need RCU and where we don't. > > I think it would be safer and easier to review if we drop each RCU > separately or in smaller batches. FWIW if we go with this route, I agree with Roman's idea about replacing folio_memcg_lock()/unlock() with an explicit rcu_read_lock()/rcu_read_unlock(), and then having separate patches/series that remove the RCU annotations. If done in a separate series, we should comment the explicit RCU calls appropriately to reflect the fact that they should mostly be removed (or at least re-evaluated).