Received: by 2002:ac0:950c:0:0:0:0:0 with SMTP id f12csp3959870imc; Thu, 14 Mar 2019 09:03:57 -0700 (PDT) X-Google-Smtp-Source: APXvYqyzOj4JXps57AYhWxMSOGh0ULieWsiT1BYDVc5w2OSH+FZ2fw0lzGVNsdei2ct7dbCFWanB X-Received: by 2002:a63:6f49:: with SMTP id k70mr15413821pgc.132.1552579437285; Thu, 14 Mar 2019 09:03:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1552579437; cv=none; d=google.com; s=arc-20160816; b=wFOeRrEeg8W05vTH+FifYL+8JrPhg27IsTUH79jQ5F8sZ0tYi5gYz2cM8VvgK9O2Br ObvZZfO7zZw+sC1AqULxYFDSl5ZMOV6I1lH/x5OqQ6vkHFmkBlx8A0QEHNjNAIzCs/Wv BI6wTGVHV1OlZOZEV66vlnFrsNMYsjSTtHcIRQSxeG3iedmjzepiMcOD/9yRQcigUINS b8ykhVZQ7CXHE7DIWJljr6HdPgi8gPCd2lUTtuiQ4RTk9CaDxv/f9Cwmj1wcy4/4jdwI tGfAbx6oXQdxewTTgFkhV2rMLuEpM4zMvZzJ0gp7WCs23vJR6hgZuGY+lqdjUxqj19+C U/iw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=0BRZmjWpl5Sc1xK8Fz95Tal8y+zU630oI+RCC6+Hs4Q=; b=y4tLW/gzvA7ydM3yTSPKx3ZGqPDa3si85lwjeQwXubsNb3t6bM6d6ViTxGfRPKMCpa 5K0chWgyA5Xb3jN3xFma6WT46nrAj437AGAKoTQqqu4KjQBEhIrYyZHPWs9gdfGwbe/0 2Omyram+ODLu5gCigKJ63i0oCDHN6hrEtwdKsEtlWgaYm8UcCRvb0G8H1OZg3qjyQR8x eVOpK6WDnDbQw8MsBtrvxIYd/wbNoOf1zE/zSfMC3fZxom6xKwAPQM3dLadlnpguAKgB uqzFYBdRhXJAYIuhL7RHBxwHBWCgJgaY+BOK62yIBMBhxd0Ahc3i9uOWijLSY05ZFXhs Qaug== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=GD8Z4IVc; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l10si12663514pgh.535.2019.03.14.09.03.41; Thu, 14 Mar 2019 09:03:57 -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=fail header.i=@infradead.org header.s=bombadil.20170209 header.b=GD8Z4IVc; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727405AbfCNQA4 (ORCPT + 99 others); Thu, 14 Mar 2019 12:00:56 -0400 Received: from bombadil.infradead.org ([198.137.202.133]:39054 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727367AbfCNQA4 (ORCPT ); Thu, 14 Mar 2019 12:00:56 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=In-Reply-To:Content-Type:MIME-Version :References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=0BRZmjWpl5Sc1xK8Fz95Tal8y+zU630oI+RCC6+Hs4Q=; b=GD8Z4IVcQkEnA7tmQZRmDMsZD acod4OPFsUrsOfuR1FLKJ7jA6erX0GyfzkAUFalRqQTr0Wc3TKoZdJNJn8bnGOw1Tuwdk0yZnf64/ pHdMOlRrDmx/7IEqQ2GJCttrttVDEbZnPlnVXa/Qa5+V4mhw8zHKfWPeKpTViw6WFl+GFz/H2TmaG 4qFtmgaq3A/Nx1q4BNCMbmX10cEE5rq+9ERqls/hf1LDnS18ontilivt/3dX71VKoTcfON3Jd9RIv iAQfJKRmrX3ZqBsjJswgiXTngc2vG+33cgA8AIHPVWsNtlDueAJM3S6t3N16/Dfynz5q0V1zwwby5 vq3znBuDQ==; Received: from willy by bombadil.infradead.org with local (Exim 4.90_1 #2 (Red Hat Linux)) id 1h4Smr-0005gI-10; Thu, 14 Mar 2019 16:00:53 +0000 Date: Thu, 14 Mar 2019 09:00:52 -0700 From: Matthew Wilcox To: Souptick Joarder Cc: kbuild test robot , kbuild-all@01.org, linux-kernel@vger.kernel.org, William Kucharski , Mike Rapoport , Andrew Morton , Linux Memory Management List Subject: Re: mm/memory.c:3968:21: sparse: incorrect type in assignment (different base types) Message-ID: <20190314160052.GM19508@bombadil.infradead.org> References: <201903140301.VeDCo2VR%lkp@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.2 (2017-12-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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; })