lkml.org 
[lkml]   [2019]   [Mar]   [14]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: mm/memory.c:3968:21: sparse: incorrect type in assignment (different base types)
On Thu, Mar 14, 2019 at 03:10:19PM +0530, Souptick Joarder wrote:
> > >> mm/memory.c:3968:21: sparse: incorrect type in assignment (different base types) @@ expected restricted vm_fault_t [usertype] ret @@ got e] ret @@
> > mm/memory.c:3968:21: expected restricted vm_fault_t [usertype] ret
> > mm/memory.c:3968:21: got int
>
> Looking into https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
> hugetlb_fault() is converted to return vm_fault_t. Not sure, why sparse is
> still throwing warnings.

Because there are two definitions of hugetlb_fault():

$ git grep -wn hugetlb_fault
include/linux/hugetlb.h:108:vm_fault_t hugetlb_fault(struct mm_struct *mm, struct vm_area_struct *vma,
include/linux/hugetlb.h:206:#define hugetlb_fault(mm, vma, addr, flags) ({ BUG(); 0; })


\
 
 \ /
  Last update: 2019-03-14 17:01    [W:0.078 / U:51.592 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site