From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf0-f72.google.com (mail-lf0-f72.google.com [209.85.215.72]) by kanga.kvack.org (Postfix) with ESMTP id 47E086B0003 for ; Mon, 4 Jun 2018 00:37:19 -0400 (EDT) Received: by mail-lf0-f72.google.com with SMTP id b26-v6so4785511lfa.6 for ; Sun, 03 Jun 2018 21:37:19 -0700 (PDT) Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id a75-v6sor91232lfb.19.2018.06.03.21.37.17 for (Google Transport Security); Sun, 03 Jun 2018 21:37:17 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20180602220136.GA14810@bombadil.infradead.org> References: <20180602200407.GA15200@jordon-HP-15-Notebook-PC> <20180602220136.GA14810@bombadil.infradead.org> From: Souptick Joarder Date: Mon, 4 Jun 2018 10:07:16 +0530 Message-ID: Subject: Re: [PATCH v2] mm: Change return type int to vm_fault_t for fault handlers Content-Type: text/plain; charset="UTF-8" Sender: owner-linux-mm@kvack.org List-ID: To: Matthew Wilcox Cc: Al Viro , Hugh Dickins , Andrew Morton , Michal Hocko , Ross Zwisler , zi.yan@cs.rutgers.edu, "Kirill A. Shutemov" , Dan Williams , Greg KH , Mark Rutland , riel@redhat.com, pasha.tatashin@oracle.com, jschoenh@amazon.de, Kate Stewart , David Rientjes , tglx@linutronix.de, Peter Zijlstra , Mel Gorman , yang.s@alibaba-inc.com, Minchan Kim , linux-fsdevel , linux-kernel@vger.kernel.org, Linux-MM On Sun, Jun 3, 2018 at 3:31 AM, Matthew Wilcox wrote: > On Sun, Jun 03, 2018 at 01:34:07AM +0530, Souptick Joarder wrote: >> @@ -3570,9 +3571,8 @@ static int hugetlb_cow(struct mm_struct *mm, struct vm_area_struct *vma, >> return 0; >> } >> >> - ret = (PTR_ERR(new_page) == -ENOMEM) ? >> - VM_FAULT_OOM : VM_FAULT_SIGBUS; >> - goto out_release_old; >> + ret = vmf_error(PTR_ERR(new_page)); >> + goto out_release_old; >> } >> >> /* > > Something weird happened to the goto here Didn't get it ? Do you refer to wrong indent in goto ?