Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp3310359pxf; Mon, 15 Mar 2021 06:54:23 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzW9xFHXa5d6+wwgr85qCoDp4X0UyOd6XFkvP0QuGmgBpl3pcjZ+4g/kNS33svbUZ8vdEew X-Received: by 2002:a17:907:d09:: with SMTP id gn9mr22964208ejc.538.1615816463470; Mon, 15 Mar 2021 06:54:23 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1615816463; cv=none; d=google.com; s=arc-20160816; b=D1Byv64wSCSw9q6Yg7B4w1BFchEHEnk+02fEMbi5HZjjb38DiZrsPEar8xkUYaePjY 5lLjEm/5/ssZ90o4BJov2BLjKgXU5Ohf06UsI308BqbmWLaB+133guHRNIQ2MwjnCHKs aKMybwGgGicKW08uDHfccQ8LgDfqO9/EEusVMOQ7i1sBpHdblKtR1PDpR7CNArQSV2OB ti5ivvsogbqPqWOtFPOmYxIWdSwXqnO9goP9bLD7rAoaUG2YWNP5SHZvZFISIZfEwcM6 TaE2QSv/g0E18JA0e6cv0vWENY/c/bG9XugpTlrQfLc4xsWlrSqPJr2hRKiH6XptPIIs Bjig== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=dy4PRHmstKgNVDldtP4AfAN87fMyz+4pw4KdPsRLyB8=; b=Ahvfkk6N1MEKyZFH0ds2iGDLc4rth9Pk4+UgLaQijztfT9CJrB+PdjzZw9VjGJheoB dVt0NXBjfggvE7YXYWvUu7EXvdCSWhKx3UWJmLMFsV1ilrUAFCjj+5nXkiqUNM+f9fwH q7WXlbWbMKqMhU7PT4WDCfWBFe+rSpmTdEpLBcnobTdiGYidLypKTvB6cXaxU9KMXS6x bVQH+PE9XQ7lKfIzG+4Q5MDdan7uxgHzqJvql7MGmAfbk7WjWcBJ5wqsJoQg4k15V9DI OREuqzoJ3Wfc3WHEZNi9aVhoMvNmb7wxIt2VTSzYvbPuYFbw73MaVUmd7+vH68yJlCAx 1leQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=bEsEqmLS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e9si11299948edv.149.2021.03.15.06.53.59; Mon, 15 Mar 2021 06:54:23 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=bEsEqmLS; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229901AbhCONxF (ORCPT + 99 others); Mon, 15 Mar 2021 09:53:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43066 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229796AbhCONwi (ORCPT ); Mon, 15 Mar 2021 09:52:38 -0400 Received: from mail-lj1-x231.google.com (mail-lj1-x231.google.com [IPv6:2a00:1450:4864:20::231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 55D5AC06174A for ; Mon, 15 Mar 2021 06:52:38 -0700 (PDT) Received: by mail-lj1-x231.google.com with SMTP id z25so16318015lja.3 for ; Mon, 15 Mar 2021 06:52:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=dy4PRHmstKgNVDldtP4AfAN87fMyz+4pw4KdPsRLyB8=; b=bEsEqmLShjpPLJm1IVJ6jucNB38hcg56W6nS6QQ+mxkcLPQtEy/D9K1iMizxd46fqb riaAiuU8Vco3PP0s6+H50DC/gcuvZ8Grp/jgnNtP6u23QtKjwQMyBvOrhKbfopH2V4cU VKfFloDVl7S/Qpcx8IScT34d15oDsSVhEUYKDNxEBtefzeAq6nV/rVeTlbXz3sIbEkmH WMPYms+tF+9G8fevqQAycsy54iS3nDajfaYIKF61FWhNV/ofUy6h7rnPX6laLM0hWvvz z//8awNhZyHZNmCpqrE0iUXPD9eMztuFb2Pztc2A3mjo30NLwfnQgHPNI2qthoaM7d6G 0atQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=dy4PRHmstKgNVDldtP4AfAN87fMyz+4pw4KdPsRLyB8=; b=mMG/IBMMyb8j0GVAI3Pjd2kwln+lcU9c+CVg+yRB5Mvu1388qLnT5MuTtTJIZ99JIj 9wp4Pv6MLJKJTtHxUpMpHexAJZRTSpPDNV8Vwpa0UcO/D0N6hWUd1s2BK201xF7VzyGy +vrjbk5CWTxNWQ0pAzqmbWa7MpUpuyJ0JKw6Zq+b4HRPa8IXlfjghPhJYjUG01YxdDg0 gpve34uRiUSgaJLuVSNaPI35OKrqB/RYMDZB/gmp4nZdzf84YMhjuPpcCwT7Z1CUaTPu b3ng0sX2yQPajnjSJg2JlS2/4pObm/Y83aZUdg1hlLsJ347BtswvDRTcGQugV5bGNLFg Hx+A== X-Gm-Message-State: AOAM533oVSV2k4vvQXao8I9qBnLys1l0LSd+AkdP524IXnPtxmU7uQ4u PnIp+w5x8LrTWUL2bULkEI0= X-Received: by 2002:a2e:8084:: with SMTP id i4mr11029534ljg.122.1615816356846; Mon, 15 Mar 2021 06:52:36 -0700 (PDT) Received: from grain.localdomain ([5.18.171.94]) by smtp.gmail.com with ESMTPSA id j25sm2681988lfm.25.2021.03.15.06.52.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Mar 2021 06:52:35 -0700 (PDT) Received: by grain.localdomain (Postfix, from userid 1000) id 282825601CE; Mon, 15 Mar 2021 16:52:35 +0300 (MSK) Date: Mon, 15 Mar 2021 16:52:35 +0300 From: Cyrill Gorcunov To: Oleg Nesterov Cc: Alexey Dobriyan , akpm@linux-foundation.org, linux-kernel@vger.kernel.org, security@kernel.org Subject: Re: [PATCH] prctl: fix PR_SET_MM_AUXV kernel stack leak Message-ID: References: <20210315120803.GA13620@redhat.com> <20210315131911.GB13620@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210315131911.GB13620@redhat.com> User-Agent: Mutt/2.0.5 (2021-01-21) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Mar 15, 2021 at 02:19:12PM +0100, Oleg Nesterov wrote: > > > > > > And why task_lock(current) ? What does it try to protect? > > > > As far as I remember this was related to reading from procfs > > at time the patch was written for first time. Looks like this > > not relevant anymore and could be dropped. > > I think this was never relevant, ->alloc_lock is per-thread, not per mm. Then we can safely drop it. I'll take one more look once time permit and prepare a patch.