Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp963399img; Mon, 18 Mar 2019 19:30:46 -0700 (PDT) X-Google-Smtp-Source: APXvYqx7Ugkl1zD4C7G84RPi2+J5WXhsOFUTizmKatD7xSmYLWCZCicSzl5UlxQLm6YmdxOEfS9y X-Received: by 2002:a62:39c2:: with SMTP id u63mr32968pfj.11.1552962646585; Mon, 18 Mar 2019 19:30:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1552962646; cv=none; d=google.com; s=arc-20160816; b=RyHlhlaNFILinK9epFnET+wgF17WMgJ/tIH3KdnNvjODYhhexLckNWDaH8tlW80yHQ RUFljEmSNRErcxsAl+gBPj4ckBW0obR/aTqRFgBL3tOFmDZQxFrb+tRtnR3+Av5wVedK TCQgLVayjB4hewovtU8YQBJdpnoNS26mO0Gj2mmUsQ4SqhO568zXOmjlikj4/CD+a9DK cHKB6kdHwPnjiBBEGAK2zLMgVc+sF6raY8dyM7TuZnQcQS72wxjMVeLJUh0v4UoWb+lY bQ0Zm6AgsJJHDVHwmqpd3zEXvJXInLTzk0gQCaJxY6TNkWldxGCC5MGMNB8YUjGwdkhH uQwQ== 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; bh=t9LeluuAwbLdhqLKYrLQeqJxgvFSi8zRhy1PLSOWg3I=; b=f/aFOiVlY0DP7kwMEttlhT9ZG2abGBgAIBq55LdHms98z/uh/VVB450DOi0uBfrGUh 9fo7JmUBMwGvZzYk5ahLScN3jwjRr5wiE4se0TjpdJD9HN6ESlAgG1lVHY9sxIgTcF8b Oe9jBRuykHRFSn2rJJecP+cg3do3ZcassNAWNRmrXAF7GChUbiS9ohg3Kwo8QNXTK40L QLyMtXbysjd8VgNJIyWC7tKgeX/80q7mpTSNH4ZuchaSeF4fmzZrKHe+t3nQ+JH8zPud tkzLCXS9Zj7//AuokoOpun1TOfmv1XSL8EcWvTpn7pYMCbSJT5vkFVP/OYkFNn4K0YbK v68Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=MUFGUAJA; 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=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id n6si10667185pgj.96.2019.03.18.19.30.30; Mon, 18 Mar 2019 19:30:46 -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=@gmail.com header.s=20161025 header.b=MUFGUAJA; 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=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727245AbfCSC34 (ORCPT + 99 others); Mon, 18 Mar 2019 22:29:56 -0400 Received: from mail-lj1-f196.google.com ([209.85.208.196]:39345 "EHLO mail-lj1-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726774AbfCSC3z (ORCPT ); Mon, 18 Mar 2019 22:29:55 -0400 Received: by mail-lj1-f196.google.com with SMTP id l7so6101634ljg.6 for ; Mon, 18 Mar 2019 19:29:54 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=t9LeluuAwbLdhqLKYrLQeqJxgvFSi8zRhy1PLSOWg3I=; b=MUFGUAJAl/zJoucy75Z3xPtEwYsA3nnr8nu3V/s7YNK7VD/HcTmcZGLwodlNVAkQj9 X2Q0/0gM9y8qxFg+jjinDtvWD9oO1eLRRRaql73i9CtaS9pZSPHFSzStnCRcej3tHrRS gEwwyBLNZYt3bOaajqMqeOgWqQ5tXYVnkgjp5Y8V84ZBh15cihEoIlvsg0YER61WxGsw yMse9WUsVwQ0Hr7WhFyn1iBq68dgV0BlEg9FB0Rp8/VgmkDyqAtjo7mufoEzhgminBR6 LdmhTXwmnVQ2mXybEaEb3BPoWOt2gY7X+b+6axfJIQuclT0XSKXUhRuEWDO8Byng+qju cagA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=t9LeluuAwbLdhqLKYrLQeqJxgvFSi8zRhy1PLSOWg3I=; b=PhBqWhSBXut9ZpJj8bcjj74M8Z6PMMAa5AB8aLhoLrwxORxEX4hobw1f9V53wq++6v RYPVB71Gc4Yq9broa3o6qHMhF9DC7820eHDN9/nmWpmPajy57e9sKIsGi3FoBfmKg32K NfqOzzWLopY3vmx6gngryLJql2+WZwV9Tafskz5QEJeYleEBqGEq2S++bzZkDrPiQk0u fyBaaMH34v0etg29wDw/AhUpOKdo0CbaGLZMIkcvaIz0KNyoLN2RsuM4LadJbEDO9cO6 OrwXyzJakezOOO8fBJNoMRdCwjaXPSdB3Tp5NxcioafPTOLtN0hkGVBtVNIFhuv08gx1 Xjpg== X-Gm-Message-State: APjAAAWDCKPgiZkpBdmIBjUjYJlmUIGrfRl4pP+YB8q3ybGxzPIvMXOY zoH2HPNL8LRiU31Y5WBgohWG1khMbyQ4AnC3XOY= X-Received: by 2002:a2e:9916:: with SMTP id v22mr12140112lji.68.1552962593789; Mon, 18 Mar 2019 19:29:53 -0700 (PDT) MIME-Version: 1.0 References: <20190318162604.GA31553@jordon-HP-15-Notebook-PC> <08a039da-6bc2-0da9-e83e-46cce6d7264b@oracle.com> In-Reply-To: <08a039da-6bc2-0da9-e83e-46cce6d7264b@oracle.com> From: Souptick Joarder Date: Tue, 19 Mar 2019 08:04:19 +0530 Message-ID: Subject: Re: [PATCH] include/linux/hugetlb.h: Convert to use vm_fault_t To: Mike Kravetz Cc: Andrew Morton , Linux-MM , linux-kernel@vger.kernel.org, Matthew Wilcox 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 Tue, Mar 19, 2019 at 5:47 AM Mike Kravetz wrote: > > > On 3/18/19 9:26 AM, Souptick Joarder wrote: > > kbuild produces the below warning -> > > > > tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master > > head: 5453a3df2a5eb49bc24615d4cf0d66b2aae05e5f > > commit 3d3539018d2c ("mm: create the new vm_fault_t type") > > reproduce: > > # apt-get install sparse > > git checkout 3d3539018d2cbd12e5af4a132636ee7fd8d43ef0 > > make ARCH=x86_64 allmodconfig > > make C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' > > > >>> 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 > > > > This patch will convert to return vm_fault_t type for hugetlb_fault() > > when CONFIG_HUGETLB_PAGE =n. > > > > Signed-off-by: Souptick Joarder > > Thanks for fixing this. > > The BUG() here and in several other places in this file is unnecessary > and IMO should be cleaned up. But that is beyond the scope of this fix. > Added to my to do list. I can clean it up if you are fine ;-) > > Reviewed-by: Mike Kravetz > -- > Mike Kravetz