Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp4260914yba; Wed, 17 Apr 2019 07:57:00 -0700 (PDT) X-Google-Smtp-Source: APXvYqzikSLENQfs1B09hluhxtUBFARtZX+6SykAq1Qn4En9al7YhB4+1Hza5VmnFEzbLd1fDped X-Received: by 2002:aa7:8392:: with SMTP id u18mr63446197pfm.217.1555513020547; Wed, 17 Apr 2019 07:57:00 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1555513020; cv=none; d=google.com; s=arc-20160816; b=LSGl7DYOK2A4eCl1XddeYiQuxAp/8G7oyPNpxpPk83o6ALpUCDKJDWd8Vemp/d/bvr CfigiDgGYJPbN/RzxBhmrMMkn4maxRSJm/r0UGRjPOn4bJkUn5arwGBS+qzYIXSIOLdu KhxDofdNL5aSyoJIxJ7Gf1LBkC+DOpZv1QqlPiU/CG/AkJ9GvVcmAiwA/uU8s3WZVLpT pgMP7sv07tpvPzQcxVkM5sR+Yz0xOIpMXjxa/o6+lMd9/Q/UMf3wVPSUgE2dnpCYHrL8 MrN2pKHdeUoOwkgzzJEFotC7qaLVHoC8/6Gy14YjY3FQzHp/8YT+qzSYBOxs1l9p5VgO R/wg== 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; bh=I65fb2sNH1MOdVrP9ynMTyurS4TBSoyLtDkUCQrHD3A=; b=ET7aGiVkMHyEZVFi9cvHs/Byp7cBdKMpVeMHOLwDKxYnI7CxpOJ3ZGS1PKJCoNdgkf wSIT73odNUU5Vh84XFdFZbxhZT0SW/xzKOot/IA9w3Wx0uGoY9EY+RNV0/X2yFglDsiA 0gglgt0+GzLhzmRCwd3TgpownYPjBKZkuVbrVdRfF+rPQRB/YB4pVuN2Ot6/9wSWnH8x pkWFlkT5ObnuP2t/QyIWSCFbUgF/2Sahsf2JzsxxD3xZXcdRowXFTff+JtX++suWEHKl alKeRs/cYCEAeBysRHqGY1xSR4aLIqRbbGrtQQfydjurGklN6GMYnklkn4FTHMcgJVdf j+nA== 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 h29si55367237pfd.180.2019.04.17.07.56.45; Wed, 17 Apr 2019 07:57:00 -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 S1732535AbfDQOzv (ORCPT + 99 others); Wed, 17 Apr 2019 10:55:51 -0400 Received: from mx2.suse.de ([195.135.220.15]:57906 "EHLO mx1.suse.de" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1729356AbfDQOzu (ORCPT ); Wed, 17 Apr 2019 10:55:50 -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 78B5FAE0F; Wed, 17 Apr 2019 14:55:49 +0000 (UTC) Date: Wed, 17 Apr 2019 16:55:48 +0200 From: Michal Hocko To: Michal =?iso-8859-1?Q?Koutn=FD?= Cc: Bartosz Golaszewski , Arun KS , Geert Uytterhoeven , linux-mm@kvack.org, Andrew Morton , Mike Rapoport , Mateusz Guzik , Vlastimil Babka , linux-kernel@vger.kernel.org Subject: Re: [PATCH] mm: get_cmdline use arg_lock instead of mmap_sem Message-ID: <20190417145548.GN5878@dhcp22.suse.cz> References: <20190417120347.15397-1-mkoutny@suse.com> <20190417134152.GM5878@dhcp22.suse.cz> <20190417144142.GF8962@blackbody.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190417144142.GF8962@blackbody.suse.cz> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 17-04-19 16:41:42, Michal Koutny wrote: > On Wed, Apr 17, 2019 at 03:41:52PM +0200, Michal Hocko wrote: > > Don't we need to use the lock in prctl_set_mm as well then? > > Correct. The patch alone just moves the race from > get_cmdline/prctl_set_mm_map to get_cmdline/prctl_set_mm. > > arg_lock could be used in prctl_set_mm but the better idea (IMO) is > complete removal of that code in favor of prctl_set_mm_map [1]. Ohh, I have missed that patch. As long as both are merged together then no objections from me and you can add Acked-by: Michal Hocko > Michal > > [1] https://lore.kernel.org/lkml/20180405182651.GM15783@uranus.lan/ -- Michal Hocko SUSE Labs