Received: by 2002:a05:6a10:8c0a:0:0:0:0 with SMTP id go10csp587938pxb; Thu, 21 Jan 2021 14:48:29 -0800 (PST) X-Google-Smtp-Source: ABdhPJyYWQw/CurMeITgPS5yVDfT2SlrDDOykhTIMdgJVTMUEeCaDwN5m3cXlZwQ1XBMnpUfAUK7 X-Received: by 2002:a17:906:3781:: with SMTP id n1mr1107403ejc.296.1611269309741; Thu, 21 Jan 2021 14:48:29 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1611269309; cv=none; d=google.com; s=arc-20160816; b=czl3zout9GSnEGyTsl2H8IBT1YlnPC2szIKnSWAmLxKg+smPCgBqw5B06e6Jwk61SI Lvqc4zcmYxIVKfk5lz+7Pkztzua0xQwJwTzkBqsxmYPsJHsJmvprA3wxfu2GFFNIcx83 gXNet0WooqTMlO+y/J/t7+gNwYYrt4K0TrO0HRhJ4EshwUM0Xg3OoiC82Xy1VNVuoDFN hxwwQot3QlD8YuySFRnKOe9AL21wMsDLOyPgX7c5tBTT47aopb8Deeo23bRsJ8dhmx3Y FQIC35lGDfTmXFTHkkcs9+CnMy5I8Rh4BOWLgQXC3Wn0kY0bJ+2r55LIsyo89GPh5pkx 7Wog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature; bh=avL60cI0yMpal+41jNtFu3XfzAa4gWqWxQvUjMhX92Y=; b=g2eFsZ/lEx1Zf1y5bqtpkw9P+s9OldoN4pGznlMuTVtaCuCvzcKYnLKsAEo70E7f4D nPinh/iaNFUKvXH/3r9uGdTU3rgNttaQmsIh2g3P0ziGtw/g9rmS63eKBXJNKYmI62FI wKBpvgf/wyilOIHFHczlKvPBNgCPqr1K/G+tsodU1DPlEU6ZP0dYcBQjdo+QHjy0tt32 q0F9JkeFefZBhCC2tc6xipLDAE7iqiVjk26P9sd+u7bD6HnWWWdZY7+aiH3m7jigQwvu k7M8hDFMNqwI/cqicYn2+RqfBMYtys+H5uV+wnkmEw/6KQ8c5P0ij8Ib/FsKbNzA9875 Gzzw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linux-foundation.org header.s=korg header.b=FE+TJQtg; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l18si2276721ejr.658.2021.01.21.14.48.06; Thu, 21 Jan 2021 14:48:29 -0800 (PST) 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=@linux-foundation.org header.s=korg header.b=FE+TJQtg; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726920AbhAUWrW (ORCPT + 99 others); Thu, 21 Jan 2021 17:47:22 -0500 Received: from mail.kernel.org ([198.145.29.99]:47282 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726583AbhAUWrP (ORCPT ); Thu, 21 Jan 2021 17:47:15 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id C867F23A61; Thu, 21 Jan 2021 22:46:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linux-foundation.org; s=korg; t=1611269188; bh=96Z526pBbuqUE3z3L6f5CHO9G46NkdGHX9wOnkYrw4o=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=FE+TJQtgLz9AxfV9MtnIhD3VwHTBtqYreaWHiScdgFDyz6n9wbVOgT2mEmSFbIygR 4CbK9MItXsgMkSQTaTZcTt2MIJiGWdOHDxZwNUK4xv4aP9XCRpfbNikb7cwSqidx+O jO82+MkbvdL6lGQGjFROcRNzMsB/tuy24+FKhUV8= Date: Thu, 21 Jan 2021 14:46:27 -0800 From: Andrew Morton To: Jarkko Sakkinen Cc: Tianjia Zhang , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , Shuah Khan , haitao.huang@intel.com, Kai Huang , x86@kernel.org, linux-sgx@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-kselftest@vger.kernel.org, Jia Zhang Subject: Re: [PATCH] mm: Optimizing error condition detection in do_mprotect_pkey() Message-Id: <20210121144627.64a60437fe97786596f389d0@linux-foundation.org> In-Reply-To: References: <20210118133310.98375-1-tianjia.zhang@linux.alibaba.com> X-Mailer: Sylpheed 3.5.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 20 Jan 2021 16:29:20 +0200 Jarkko Sakkinen wrote: > > > On Mon, Jan 18, 2021 at 09:33:10PM +0800, Tianjia Zhang wrote: > > Obviously, the error variable detection of the if statement is > > for the mprotect callback function, so it is also put into the > > scope of calling callbck. > > > > Reported-by: Jia Zhang > > Signed-off-by: Tianjia Zhang > > No fixes tag, no description what this commit does. Nothing > makes sense to me. It's a little cleanup. Makes the flow at this site consistent with the other places where this function handles errors. I added a bit to the changelog mentioning this.