Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755050AbcDDJmR (ORCPT ); Mon, 4 Apr 2016 05:42:17 -0400 Received: from mail-lb0-f196.google.com ([209.85.217.196]:33010 "EHLO mail-lb0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754010AbcDDJmQ (ORCPT ); Mon, 4 Apr 2016 05:42:16 -0400 Date: Mon, 4 Apr 2016 11:42:13 +0200 From: Michal Hocko To: Vladimir Davydov Cc: Andrew Morton , Linus Torvalds , Johannes Weiner , Mel Gorman , David Rientjes , Tetsuo Handa , Hillf Danton , KAMEZAWA Hiroyuki , linux-mm@kvack.org, LKML Subject: Re: [PATCH 1/3] mm, oom: rework oom detection Message-ID: <20160404094213.GB13463@dhcp22.suse.cz> References: <1450203586-10959-1-git-send-email-mhocko@kernel.org> <1450203586-10959-2-git-send-email-mhocko@kernel.org> <20160404082343.GD6610@esperanza> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20160404082343.GD6610@esperanza> User-Agent: Mutt/1.5.24 (2015-08-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1073 Lines: 33 On Mon 04-04-16 11:23:43, Vladimir Davydov wrote: > On Tue, Dec 15, 2015 at 07:19:44PM +0100, Michal Hocko wrote: > ... > > @@ -2592,17 +2589,10 @@ static bool shrink_zones(struct zonelist *zonelist, struct scan_control *sc) > > &nr_soft_scanned); > > sc->nr_reclaimed += nr_soft_reclaimed; > > sc->nr_scanned += nr_soft_scanned; > > - if (nr_soft_reclaimed) > > - reclaimable = true; > > /* need some check for avoid more shrink_zone() */ > > } > > > > - if (shrink_zone(zone, sc, zone_idx(zone) == classzone_idx)) > > - reclaimable = true; > > - > > - if (global_reclaim(sc) && > > - !reclaimable && zone_reclaimable(zone)) > > - reclaimable = true; > > + shrink_zone(zone, sc, zone_idx(zone)); > > Shouldn't it be > > shrink_zone(zone, sc, zone_idx(zone) == classzone_idx); > > ? I cannot remember the reason why I have removed it so it is more likely this was unintentional. Thanks for catching this. I will fold it into the original patch before I repost the full series (this week hopefully). -- Michal Hocko SUSE Labs