lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180529173445.GD15148@bombadil.infradead.org>
Date:   Tue, 29 May 2018 10:34:45 -0700
From:   Matthew Wilcox <willy@...radead.org>
To:     Souptick Joarder <jrdr.linux@...il.com>
Cc:     Al Viro <viro@...iv.linux.org.uk>, Hugh Dickins <hughd@...gle.com>,
        Andrew Morton <akpm@...ux-foundation.org>,
        Michal Hocko <mhocko@...e.com>,
        Ross Zwisler <ross.zwisler@...ux.intel.com>,
        zi.yan@...rutgers.edu,
        "Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>,
        Dan Williams <dan.j.williams@...el.com>,
        Greg KH <gregkh@...uxfoundation.org>,
        Mark Rutland <mark.rutland@....com>, riel@...hat.com,
        pasha.tatashin@...cle.com, jschoenh@...zon.de,
        Kate Stewart <kstewart@...uxfoundation.org>,
        David Rientjes <rientjes@...gle.com>, tglx@...utronix.de,
        Peter Zijlstra <peterz@...radead.org>,
        Mel Gorman <mgorman@...e.de>, yang.s@...baba-inc.com,
        Minchan Kim <minchan@...nel.org>,
        linux-fsdevel <linux-fsdevel@...r.kernel.org>,
        linux-kernel@...r.kernel.org, Linux-MM <linux-mm@...ck.org>
Subject: Re: [PATCH] mm: Change return type to vm_fault_t

On Tue, May 29, 2018 at 09:25:05PM +0530, Souptick Joarder wrote:
> On Tue, May 29, 2018 at 8:20 PM, Matthew Wilcox <willy@...radead.org> wrote:
> > On Tue, May 29, 2018 at 08:01:26PM +0530, 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.
> >
> > I don't believe you've checked this with sparse.
> >
> >> @@ -802,7 +802,8 @@ int fixup_user_fault(struct task_struct *tsk, struct mm_struct *mm,
> >>                    bool *unlocked)
> >>  {
> >>       struct vm_area_struct *vma;
> >> -     int ret, major = 0;
> >> +     int major = 0;
> >> +     vm_fault_t ret;
> >>
> >>       if (unlocked)
> >>               fault_flags |= FAULT_FLAG_ALLOW_RETRY;
> >
> > ...
> >         major |= ret & VM_FAULT_MAJOR;
> >
> > That should be throwing a warning.
> 
> Sorry, but I verified again and didn't see similar warnings.
> 
> steps followed -
> 
> apply the patch
> make c=2 -j4 ( build for x86_64)
> looking for warnings in files because of this patch.
> 
> The only error I am seeing "error: undefined identifier '__COUNTER__' "
> which is pointing to BUG(). There are few warnings but those are not
> related to this patch.
> 
> In my test tree the final patch to create new vm_fault_t type is
> already applied.
> 
> Do you want me to verify in some other way ?

I see:

mm/gup.c:817:15: warning: invalid assignment: |=
mm/gup.c:817:15:    left side has type int
mm/gup.c:817:15:    right side has type restricted vm_fault_t

are you building with 'c=2' or 'C=2'?

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ