Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp3743244img; Mon, 25 Mar 2019 17:19:34 -0700 (PDT) X-Google-Smtp-Source: APXvYqyRNnBgA8h/B9k6U0sZbHrGO0PS1iqFBYafmaGxIDYdbX53aTq31xxgCuaUbWMTLT9gFC8X X-Received: by 2002:a65:4342:: with SMTP id k2mr26530191pgq.445.1553559574285; Mon, 25 Mar 2019 17:19:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553559574; cv=none; d=google.com; s=arc-20160816; b=yp5FBM+q+kSsWa/9K2/5/3KAugV47IzUIVoEGFD9TyF+gikaZ0US+D4Htwf70nMm9W +EOnyvje0XpFpPZ6cXw5EM9ppOL9NOPwWe6Z+ni3vxXp+I1MIlkdoF8deZJKnAnMBN2V xmAJeJZOF4dSJCgKLIqgLsF6U+1JITMQbqMs2/CwtiaZj2USWwPjW/J0vRqlSs0pd81d rAstL7QTJfeh9afI6qMX0vo1hYXSLF/DaLubGhxtYk0ljg4/pxkoXhaY2BWiR3NOMBnL vkSjSpEiW5lbc3RhxGH0iJaSJOaqFWJqIk3mjEGsPfLt6JbSrSQZnevhCi5lxXrEdDNr dq4A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:dkim-signature:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from; bh=Ar2rKTHyUtl4aYwVRAxRlJMl89iafQ2aXTYpxu+WCO0=; b=h3a/yFYFryK5IUpjwTrWlicl9+oNf6GGEnjaTbfdkXyOOoWk/44niJYYcvGgML2qd3 SIxTN1+rN6BrGkg/rz2Bo3rN2TE8VEDE86ifc/Ti7fwFSWxux2tHpR1C6gbiqgv1b70j 0Y+B7vN7hRqaTkj6a8ZPK7qXFhfWQdrh6RBzrbM/UYqgM7fn1EBqqvyRMcpRbJhY3e06 k0sWxxghAMQGuKnApz8oWlSnulneCLXNb4d8kwYrp3WkUkHTPFMJ+GDyUOPpf4GI4lny 478hL+V0HFbd4KE/tpxis/ZW4vqCWdxYAkYq2Wda8EbQSIGQLgI8N6eOsFPKLawbmAHX hItg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@nvidia.com header.s=n1 header.b=cqvRgXjd; 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=NONE dis=NONE) header.from=nvidia.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id d14si8121098pgb.26.2019.03.25.17.19.18; Mon, 25 Mar 2019 17:19:34 -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=@nvidia.com header.s=n1 header.b=cqvRgXjd; 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=NONE dis=NONE) header.from=nvidia.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727501AbfCZASo (ORCPT + 99 others); Mon, 25 Mar 2019 20:18:44 -0400 Received: from hqemgate16.nvidia.com ([216.228.121.65]:15872 "EHLO hqemgate16.nvidia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726186AbfCZASo (ORCPT ); Mon, 25 Mar 2019 20:18:44 -0400 Received: from hqpgpgate102.nvidia.com (Not Verified[216.228.121.13]) by hqemgate16.nvidia.com (using TLS: TLSv1.2, DES-CBC3-SHA) id ; Mon, 25 Mar 2019 17:18:41 -0700 Received: from hqmail.nvidia.com ([172.20.161.6]) by hqpgpgate102.nvidia.com (PGP Universal service); Mon, 25 Mar 2019 17:18:43 -0700 X-PGP-Universal: processed; by hqpgpgate102.nvidia.com on Mon, 25 Mar 2019 17:18:43 -0700 Received: from rcampbell-dev.nvidia.com (10.124.1.5) by HQMAIL101.nvidia.com (172.20.187.10) with Microsoft SMTP Server (TLS) id 15.0.1473.3; Tue, 26 Mar 2019 00:18:43 +0000 From: To: CC: Ralph Campbell , Craig Bergstrom , Linus Torvalds , Boris Ostrovsky , Fengguang Wu , Greg Kroah-Hartman , Hans Verkuil , Mauro Carvalho Chehab , Peter Zijlstra , Sander Eikelenboom , Sean Young , Thomas Gleixner , Ingo Molnar Subject: [PATCH v2 0/1] x86/mm: Fix limit mmap() of /dev/mem to valid physical Date: Mon, 25 Mar 2019 17:18:16 -0700 Message-ID: <20190326001817.15413-1-rcampbell@nvidia.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 X-NVConfidentiality: public X-Originating-IP: [10.124.1.5] X-ClientProxiedBy: HQMAIL105.nvidia.com (172.20.187.12) To HQMAIL101.nvidia.com (172.20.187.10) Content-Transfer-Encoding: quoted-printable Content-Type: text/plain DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nvidia.com; s=n1; t=1553559521; bh=Ar2rKTHyUtl4aYwVRAxRlJMl89iafQ2aXTYpxu+WCO0=; h=X-PGP-Universal:From:To:CC:Subject:Date:Message-ID:X-Mailer: MIME-Version:X-NVConfidentiality:X-Originating-IP: X-ClientProxiedBy:Content-Transfer-Encoding:Content-Type; b=cqvRgXjdzSmLk9NZ6OfUvmp4wfyVlWef1Yu+K6xe08gd/khlZs1opUw4eVZGGEiHD jrz0wdXsmNw0Hr2JZJgM47gqZPDvd8JW90kKtyxyBS3/speV+cHWThkXLHJ52JoxNr vzx/4TspKXwl3U73Jh1pSmy2V62CUG34vVHZBTAhFvxkjgFEHIYUvi9BDiL/XB6f1o mKWCfTKg8jOMQBwgAWQA3JVEnRl06UDuTHSjswHdY4Tns3TYCJmW7X4NrpVMGFfBeR 4fc8y5uXU87hs63ghTqjx/VzEKI0I2yspZ4hjfQzAatZ2TBAw4MajGMjcvxI22DXv/ ZGvsFQYj7f8tw== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Ralph Campbell I was debugging with v5.1.0-rc1 and while booting I hit a kernel BUG at arch/x86/mm/physaddr.c:27 which I fixed with the following patch but now I can't seem to reproduce the exact setup that triggered it. Still, it seems like a valid problem and maybe my difficulty in reproducing it explains why others haven't seen it earlier. Changes from v1 to v2: * Updated the change log and patch as suggested by Thomas Gleixner. Ralph Campbell (1): x86/mm: Fix limit mmap() of /dev/mem to valid physical addresses arch/x86/mm/mmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --=20 2.20.1