Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp4698618yba; Tue, 30 Apr 2019 02:57:06 -0700 (PDT) X-Google-Smtp-Source: APXvYqxatxS51pNwGxxRjviYuctv6uUx/rGtMt6JKy1AoMWuFHsdgwRd+qaxLvGl3F2lC/b3k6UU X-Received: by 2002:a17:902:8f88:: with SMTP id z8mr61717754plo.54.1556618226048; Tue, 30 Apr 2019 02:57:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1556618226; cv=none; d=google.com; s=arc-20160816; b=W3y6w1tQdhtIN0Ld3Rg1FS/fa3GmbYbQPyZcX3OAn3W59dn5AAICfZDDAMJz69pSG7 emHj3vn04uVBMteFmgEHA46Apb9mx6WAAwlIpHbG+FniNs0GFJK8VHM+NYs7aHV0+J5l XZ2PZNS351zM0oZ7m6PhWsgoIx/FBpIQzEea7JMtbNQyUQ1oRET3dMKeeK1kC+zoHRpA hbl/tMY11V2okyv5IbKGzKA7iKTsfr2MCsOXt1lkxxZ/+dljv8UPC6cnxleGjA42VYg5 XfXyLQheB7mAU2piresRtnImgvXetNdOmG0SWMj7KEgEdwdTUk+iYaZFKRiboQ37FNV9 T2uw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=uVlf09ii/gJaQyHiqAtHym+8xBl8rU9MIovaRXcsJS0=; b=xATwggQPiuGUYccHUKEULESH95F5LHB9tDHm082sx7EXEF4lnIU7l96u21OaGNpr2O bxJ63ld5GPMmwQOUKFBoKkpdr4vTqeYkrwkJiWoEv25c+OcvzeTaIVigVX23RkFnoo5S q4AePtSuqLeYfFfCwTm5G45CbudEhqD+Lr6Qz0pyJSZFd7cvxpnhgTgXah79LSysRL0D g5yXNvvSepuoyMWle83uv9jdiK6HdxY3CkYwj0XhWLY5JLw3sI31T3tG5I6HZLUU2EDn UkwJR6rJe9JUzovKAEXtWjaP6Vu/VvAhmaUb4A0muSdpK5/PIALRLoCtOoLA6oJPnGZK RroQ== 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=virtuozzo.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 3si8511050pgy.200.2019.04.30.02.56.49; Tue, 30 Apr 2019 02:57:06 -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=virtuozzo.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726983AbfD3JyC (ORCPT + 99 others); Tue, 30 Apr 2019 05:54:02 -0400 Received: from relay.sw.ru ([185.231.240.75]:40588 "EHLO relay.sw.ru" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726262AbfD3JyB (ORCPT ); Tue, 30 Apr 2019 05:54:01 -0400 Received: from [172.16.25.169] by relay.sw.ru with esmtp (Exim 4.91) (envelope-from ) id 1hLPSS-0007ia-U6; Tue, 30 Apr 2019 12:53:53 +0300 Subject: Re: [PATCH 1/3] mm: get_cmdline use arg_lock instead of mmap_sem To: Cyrill Gorcunov Cc: =?UTF-8?Q?Michal_Koutn=c3=bd?= , akpm@linux-foundation.org, arunks@codeaurora.org, brgl@bgdev.pl, geert+renesas@glider.be, ldufour@linux.ibm.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, mguzik@redhat.com, mhocko@kernel.org, rppt@linux.ibm.com, vbabka@suse.cz References: <20190418182321.GJ3040@uranus.lan> <20190430081844.22597-1-mkoutny@suse.com> <20190430081844.22597-2-mkoutny@suse.com> <4c79fb09-c310-4426-68f7-8b268100359a@virtuozzo.com> <20190430093808.GD2673@uranus.lan> From: Kirill Tkhai Message-ID: <1a7265fa-610b-1f2a-e55f-b3a307a39bf2@virtuozzo.com> Date: Tue, 30 Apr 2019 12:53:51 +0300 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.6.1 MIME-Version: 1.0 In-Reply-To: <20190430093808.GD2673@uranus.lan> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 30.04.2019 12:38, Cyrill Gorcunov wrote: > On Tue, Apr 30, 2019 at 12:09:57PM +0300, Kirill Tkhai wrote: >> >> This looks OK for me. >> >> But speaking about existing code it's a secret for me, why we ignore arg_lock >> in binfmt code, e.g. in load_elf_binary(). > > Well, strictly speaking we probably should but you know setup of > the @arg_start by kernel's elf loader doesn't cause any side > effects as far as I can tell (its been working this lockless > way for years, mmap_sem is taken later in the loader code). > Though for consistency sake we probably should set it up > under the spinlock. Ok, so elf loader doesn't change these parameters. Thanks for the explanation.