Received: by 2002:ac0:a581:0:0:0:0:0 with SMTP id m1-v6csp4099570imm; Mon, 25 Jun 2018 09:42:13 -0700 (PDT) X-Google-Smtp-Source: ADUXVKJLtam5+gYXObY8Cf4MUTgZiOPUMAyRTmzzTjWY67Ie9tpcpLksmml7Jz5GQqeO1sC3mbOI X-Received: by 2002:a65:61a7:: with SMTP id i7-v6mr11654253pgv.219.1529944933484; Mon, 25 Jun 2018 09:42:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529944933; cv=none; d=google.com; s=arc-20160816; b=ROxK5Lgc7lUFZL443AbZwWV6bvCbCkb6/jgboCorRgltWh0Dj8AKygnroKS469rH75 bsNyro6AbCEcTdaqAcvbQlLVY4pFRiry/ITgXMq8gQEcaW9r9OG+m5VPwS1CJMLLjSQ6 jCvnUvAXeSGzLYrI0B6Qnbjfzr/e/6e42oaYvaxS7SRuNVTQbYxffbL5+joP/mFqiJ4U xo5vnl3zHCqKlsLK8urp2pPmENxgTTiLCbgwcgkXzBgSb8WLQAr/ZkjRI8EawnPwLkE0 tGRhO4Z255jvF6GgHXLUPw4xBRgM/NbgBhJNU8Qw1I1GY0iNBXwSRBlKERPrLaBs0HrQ 7y9g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature :arc-authentication-results; bh=iVXyHQKoukiO6dey+GqA9zcWeHIXNC9R+ahCe23u8Ns=; b=kZxlzXL5Z6rBWbPK1CZc2VIKht0JjBnMDSgsuCzczDN2itudkGx4HEKiVnNSbuaB3m tHE7Sqw/LgryLOIYdpD9tyY4lBN7DPE+mbhSurtwHmGSfS54/CmTj5ac9KaeTaYBir2+ llz+vERfY9fkAU5tvEmGI1nlPPBzctN0TYxfwogBXTD0VodBBFQilrRVOM84aWn2YThV 1vAr9IWUd1VfFnDMY+PX1807cV2dLgQnwTzAo+9/T1s2LVyluWQQZPqyMvBB3/0POxhH fKluwmhbh41EeuG79TeJG6vpKsm8a0njzWXG8GOQ7XnciDM4//J6WwLFeOwgBIIcMXu+ xQSw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=ayRb6gMg; 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=pass (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 j193-v6si4681117pge.689.2018.06.25.09.41.57; Mon, 25 Jun 2018 09:42:13 -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; dkim=pass header.i=@kernel.org header.s=default header.b=ayRb6gMg; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755450AbeFYQkE (ORCPT + 99 others); Mon, 25 Jun 2018 12:40:04 -0400 Received: from mail.kernel.org ([198.145.29.99]:50558 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755335AbeFYQkC (ORCPT ); Mon, 25 Jun 2018 12:40:02 -0400 Received: from mail-wr0-f175.google.com (mail-wr0-f175.google.com [209.85.128.175]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 4A8F625792 for ; Mon, 25 Jun 2018 16:40:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1529944801; bh=XA+eIg1NmyZYTZQnEPJ7kb1o7KlTdRRU0dIcsTKQLTc=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=ayRb6gMgA5sN4t6qD5BJ6ILeuR/pNdvv6IXqBKYzGh1mdxQqhaPEu+ClGLVuX7Wzj Wn2v9uxiyNTJRI6o6XXXkOsHZKVNE+5tx3q0LCSBTlmwXpjBCoThw575duK8VFApFe QQlPbLb5xe5zAs1DWA/kJwOP5+xdMjLoFzDh+3QM= Received: by mail-wr0-f175.google.com with SMTP id w10-v6so14353800wrk.9 for ; Mon, 25 Jun 2018 09:40:01 -0700 (PDT) X-Gm-Message-State: APt69E2/d3i/WOSlPUIoqtKR/kRtiVKLUtJCd9OJSHgibl5gIms/Mcqc Lt5nQEx1n/wU67GCtbF0YXQ4F0jjarMixda7ljhD6Q== X-Received: by 2002:adf:e0c5:: with SMTP id e5-v6mr6789719wri.199.1529944799802; Mon, 25 Jun 2018 09:39:59 -0700 (PDT) MIME-Version: 1.0 References: <20180625155750.GA14306@jordon-HP-15-Notebook-PC> In-Reply-To: From: Andy Lutomirski Date: Mon, 25 Jun 2018 09:39:47 -0700 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH] x86/vdso: Change return type to vm_fault_t for fault handlers To: jrdr.linux@gmail.com Cc: Matthew Wilcox , Thomas Gleixner , Ingo Molnar , "H. Peter Anvin" , X86 ML , LKML , brajeswar.linux@gmail.com, sabyasachi.linux@gmail.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 25, 2018 at 9:15 AM Souptick Joarder wrote: > > On Mon, Jun 25, 2018 at 9:41 PM, Andy Lutomirski wrote: > > On Mon, Jun 25, 2018 at 8:55 AM Souptick Joarder wrote: > >> > >> Use new return type vm_fault_t for fault handler. For > >> now, this is just documenting that the function returns > >> a VM_FAULT value rather than an errno. Once all instances > >> are converted, vm_fault_t will become a distinct type. > > > > Whoa there.. Your commit message makes it sound like you're just > > changing the return type, but: > > > >> if (tsc_pg && vclock_was_used(VCLOCK_HVCLOCK)) > >> - ret = vm_insert_pfn(vma, vmf->address, > >> + ret = vmf_insert_pfn(vma, vmf->address, > >> vmalloc_to_pfn(tsc_pg)); > >> } > >> > >> - if (ret == 0 || ret == -EBUSY) > >> - return VM_FAULT_NOPAGE; > >> - > >> - return VM_FAULT_SIGBUS; > >> + return ret; > > > > You're refactoring the code, too. > > > > Please fix your changelog. > > > I have mentioned it. > > ******************** > Ref-> commit 1c8f422059ae ("mm: change return type to vm_fault_t") > > Previously vm_insert_pfn() returns err which has to > mapped into VM_FAULT_* type. The new function > vmf_insert_pfn() will replace this inefficiency by > returning VM_FAULT_* type. > ********************* The second line of your changelog says "For now, this is just documenting...". Please don't make future readers read all the way through the whole changelog and try to reconcile conflicting sentences to figure out what the patch does. I read your changelog, then I read through the diff to make sure that you were really just changing the return type (as your changelog seemed to claim), and I decided that your patch was incorrect. As the maintainer of this code, this means that you've made my work harder than it should be, so NAK. Please improve your changelog and resubmit. --Andy