Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp440698imm; Tue, 24 Jul 2018 23:18:29 -0700 (PDT) X-Google-Smtp-Source: AAOMgpfIKlYUXu4+72ljJQOous0fXKCSMXk4laU71HerI73x7a3ZEtfrxe3lxIPPgVItrUaps1xH X-Received: by 2002:a63:a5c:: with SMTP id z28-v6mr19065643pgk.209.1532499509034; Tue, 24 Jul 2018 23:18:29 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1532499509; cv=none; d=google.com; s=arc-20160816; b=e/EDwlv5zyKR6BFNc/Ak+kYCjh4lfoIbyk1BxFgHNAom2Ph2mpO5MzU2h+Eo2g+JxZ ETf9LPjYqTBTB7ZZ0b7esXVqwoetepz2tWYFnsaqDjbXvsAkRv/HHoVwPxzpN/0ovYIp p8rYRLylGkgldiBqKo4eH2eeW1QgfA8GGkWEbkl6X9zYbADCR6ovf5kQJSF98RXzRyMH xdWqHkjhU0Mwlx92Z0vZatCuuGkyo/RfgqTmt2gRodFpIHrUSB92BY8Shvo4EDrZa6Xu P5SfyLQQz9m0GDlFyL48l+ZROdywq3PwJzpL1WSaC0+L1KaCMZ4W71v77h7oHXyzfoqz t9dg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=yCy4/f+L37wqB7wUDfjUIvZaNWfsEirFE+mDK4+Q8zw=; b=iS3wuue063bSY0kx6QpFINODGIwY/5IBSJ11mRTc2PC9Gwb78GqaHkW/zQxTTY3ZYH V+bqnuXrWZzjE1q+zRIcT6rhWto5NBv8YPQizmvcHmaGkLG30APMFA/DLBKDF7rBPklu bsABVqZ8I2HuOQ7OqJPgoPG5dA+nZVMS8E4fJl8bapWVbiNFiYC2XqgA0v6XCYaanfc2 Su9EFtcD0XcY4zIQ0oskT5vx4UsuvHZhpRF4U/XI0Y/w7XlPwNtheLxlceFm2YoYD9Gy 87h/GLzS2n4Dqa7yqqwwc2+/EXbd51l1AJ9pjob5t6q+Gh6g7p8K6qEdqwjnUxfREH5J rKJA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 3-v6si12569726pld.36.2018.07.24.23.18.13; Tue, 24 Jul 2018 23:18:29 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728493AbeGYH1d (ORCPT + 99 others); Wed, 25 Jul 2018 03:27:33 -0400 Received: from mx2.suse.de ([195.135.220.15]:44306 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1728378AbeGYH1d (ORCPT ); Wed, 25 Jul 2018 03:27:33 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (unknown [195.135.220.254]) by mx1.suse.de (Postfix) with ESMTP id 51FF3AE21; Wed, 25 Jul 2018 06:17:23 +0000 (UTC) Date: Wed, 25 Jul 2018 08:17:22 +0200 From: Michal Hocko To: Andrew Morton Cc: LKML , linux-mm@kvack.org, "David (ChunMing) Zhou" , Paolo Bonzini , Radim =?utf-8?B?S3LEjW3DocWZ?= , Alex Deucher , David Airlie , Jani Nikula , Joonas Lahtinen , Rodrigo Vivi , Doug Ledford , Jason Gunthorpe , Mike Marciniszyn , Dennis Dalessandro , Sudeep Dutt , Ashutosh Dixit , Dimitri Sivanich , Boris Ostrovsky , Juergen Gross , =?iso-8859-1?B?Suly9G1l?= Glisse , Andrea Arcangeli , Felix Kuehling , kvm@vger.kernel.org, amd-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org, intel-gfx@lists.freedesktop.org, linux-rdma@vger.kernel.org, xen-devel@lists.xenproject.org, Christian =?iso-8859-1?Q?K=F6nig?= , David Rientjes , Leon Romanovsky Subject: Re: [PATCH] mm, oom: distinguish blockable mode for mmu notifiers Message-ID: <20180725061722.GT28386@dhcp22.suse.cz> References: <20180716115058.5559-1-mhocko@kernel.org> <20180720170902.d1137060c23802d55426aa03@linux-foundation.org> <20180724141747.GP28386@dhcp22.suse.cz> <20180724125307.d6035c447adf46b2d74dfbd7@linux-foundation.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180724125307.d6035c447adf46b2d74dfbd7@linux-foundation.org> User-Agent: Mutt/1.10.0 (2018-05-17) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue 24-07-18 12:53:07, Andrew Morton wrote: [...] > > On top of that the proposed cleanup looks as follows: > > > > Looks good to me. Seems a bit strange that we omit the pr_info() > output if the mm was partially reaped - people would still want to know > this? Not very important though. I think that having a single output once we are done is better but I do not have a strong opinion on this. Btw. here is the changelog for the cleanup. " Andrew has noticed someinconsistencies in oom_reap_task_mm. Notably - Undocumented return value. - comment "failed to reap part..." is misleading - sounds like it's referring to something which happened in the past, is in fact referring to something which might happen in the future. - fails to call trace_finish_task_reaping() in one case - code duplication. - Increases mmap_sem hold time a little by moving trace_finish_task_reaping() inside the locked region. So sue me ;) - Sharing the finish: path means that the trace event won't distinguish between the two sources of finishing. Add a short explanation for the return value and fix the rest by reorganizing the function a bit to have unified function exit paths. Suggested-by: Andrew Morton Signed-off-by: Michal Hocko " -- Michal Hocko SUSE Labs