[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20160311102925.GG27701@dhcp22.suse.cz>
Date: Fri, 11 Mar 2016 11:29:25 +0100
From: Michal Hocko <mhocko@...nel.org>
To: Vladimir Davydov <vdavydov@...tuozzo.com>
Cc: Andrew Morton <akpm@...ux-foundation.org>,
Johannes Weiner <hannes@...xchg.org>, linux-mm@...ck.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH] mm: memcontrol: zap oom_info_lock
On Fri 11-03-16 13:11:23, Vladimir Davydov wrote:
> mem_cgroup_print_oom_info is always called under oom_lock, so
> oom_info_lock is redundant.
>
> Signed-off-by: Vladimir Davydov <vdavydov@...tuozzo.com>
Acked-by: Michal Hocko <mhocko@...e.com>
> ---
> mm/memcontrol.c | 4 ----
> 1 file changed, 4 deletions(-)
>
> diff --git a/mm/memcontrol.c b/mm/memcontrol.c
> index fa7bf354ae32..36db05fa8acb 100644
> --- a/mm/memcontrol.c
> +++ b/mm/memcontrol.c
> @@ -1150,12 +1150,9 @@ static bool mem_cgroup_wait_acct_move(struct mem_cgroup *memcg)
> */
> void mem_cgroup_print_oom_info(struct mem_cgroup *memcg, struct task_struct *p)
> {
> - /* oom_info_lock ensures that parallel ooms do not interleave */
> - static DEFINE_MUTEX(oom_info_lock);
> struct mem_cgroup *iter;
> unsigned int i;
>
> - mutex_lock(&oom_info_lock);
> rcu_read_lock();
>
> if (p) {
> @@ -1199,7 +1196,6 @@ void mem_cgroup_print_oom_info(struct mem_cgroup *memcg, struct task_struct *p)
>
> pr_cont("\n");
> }
> - mutex_unlock(&oom_info_lock);
> }
>
> /*
> --
> 2.1.4
--
Michal Hocko
SUSE Labs
Powered by blists - more mailing lists