In the Linux kernel, the following vulnerability has been resolved: mm: listlru: fix UAF for memory cgroup The memcgroupfromslabobj() is supposed to be called under rcu lock or cgroupmutex or others which could prevent returned memcg from being freed. Fix it by adding missing rcu read lock. Found by code inspection. [songmuchun@bytedance.com: only grab rcu lock when necessary, per Vlastimil]