Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp1076981ybl; Wed, 14 Aug 2019 10:19:07 -0700 (PDT) X-Google-Smtp-Source: APXvYqyz4opF1zhS/bsybDNIp7Cqko6WRLKorZUGClyhGwgfZ18P5F013FKoZnEPneW0RfwZqggM X-Received: by 2002:a63:4612:: with SMTP id t18mr220036pga.85.1565803147471; Wed, 14 Aug 2019 10:19:07 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1565803147; cv=none; d=google.com; s=arc-20160816; b=ziu9WlXe3qFsySMGMWqY0JYyy8Nh7dwnVGYKgULQYpeQGOnsM/vqZDPn2BsQ06ZyC0 WWmdLEE/NBHH9HAJExQTOG3ps0LkX66v67yIiD7HetHkSvSv5H2qvQ4pn3RYYLtGmafd QMLUsdTrm2PIOeP7t15hX0BTl3EL3nbPmW3Asm3YXJEtL8qg78zOvxcjlGwaUiSmKbFL 66IpkwZaVVx1w6HVSk2fyQNMqF8ypUb18sqP4+4PwJHom3dFpRRUy3lpZ1ddPOAOs/fY B/SnGPTewrCAn3aTumPwHW/OGg0fpX6Eopt4ka8njh3f3xSZXPYU7dNVWje537uZ+Y25 XfCw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=ivz2pi/danqyDTt2H6GTANzezZDKsGg9F1Txzor84MM=; b=w5WgaEjJeHDURg6qF2lhl8aUB2z5DmpKTS7XlUbbgsMI3mt+6J2d/UPZrKFKhua2Kr WcBWrp22Xo2s8bw9YJmUtVx3a2sFSCPAZAG+Wgbj5BAY0YbOO0J7WEwY1SYgPB6hNXCO z6WvKzuC++We7TUPZDl1dJmj5qOGRxiv/UuLxd+zjr0FuqrniZYAxGBgal+xenQt2A48 d7J4J95kpSMw+0+vIyvRxk+e48c6jDG2GTcGZi9QbpOGDfak5TUvPgPPGYvHsuI42DNT yf7iUpauXEWUWKLwUBt+NQ5YDhiON184XLB48+FrrHP8B9aQaibJtzSpI9glyzZq7g6S UIdA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=nh98G+Mf; 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 29si155186pgu.584.2019.08.14.10.18.52; Wed, 14 Aug 2019 10:19:07 -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=@kernel.org header.s=default header.b=nh98G+Mf; 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 S1730955AbfHNRNt (ORCPT + 99 others); Wed, 14 Aug 2019 13:13:49 -0400 Received: from mail.kernel.org ([198.145.29.99]:38178 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728900AbfHNRNs (ORCPT ); Wed, 14 Aug 2019 13:13:48 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 9A0CA2133F; Wed, 14 Aug 2019 17:13:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1565802828; bh=2YBuIsDcMpoL0U/IBSf8khny7Yz77o+fjErHr9vIHBM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nh98G+MfpEpEbXPehZ44xm8x5A8fAaujT09W69QOjckNPjA5Om+0rA8vZeEtXqHKs xt6ttBkyAIORd8t+dC/eGXSHugON74nddwCQZNEKXQHB5rWxzXTZM03G9i2aEssgzs Vb38A5uaGLd5YGS8/L3wFCG1OcJuqNf2dMJhSRuo= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Joerg Roedel , Thomas Gleixner , Dave Hansen Subject: [PATCH 4.14 15/69] x86/mm: Check for pfn instead of page in vmalloc_sync_one() Date: Wed, 14 Aug 2019 19:01:13 +0200 Message-Id: <20190814165746.553852707@linuxfoundation.org> X-Mailer: git-send-email 2.22.0 In-Reply-To: <20190814165744.822314328@linuxfoundation.org> References: <20190814165744.822314328@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Joerg Roedel commit 51b75b5b563a2637f9d8dc5bd02a31b2ff9e5ea0 upstream. Do not require a struct page for the mapped memory location because it might not exist. This can happen when an ioremapped region is mapped with 2MB pages. Fixes: 5d72b4fba40ef ('x86, mm: support huge I/O mapping capability I/F') Signed-off-by: Joerg Roedel Signed-off-by: Thomas Gleixner Reviewed-by: Dave Hansen Link: https://lkml.kernel.org/r/20190719184652.11391-2-joro@8bytes.org Signed-off-by: Greg Kroah-Hartman --- arch/x86/mm/fault.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/arch/x86/mm/fault.c +++ b/arch/x86/mm/fault.c @@ -266,7 +266,7 @@ static inline pmd_t *vmalloc_sync_one(pg if (!pmd_present(*pmd)) set_pmd(pmd, *pmd_k); else - BUG_ON(pmd_page(*pmd) != pmd_page(*pmd_k)); + BUG_ON(pmd_pfn(*pmd) != pmd_pfn(*pmd_k)); return pmd_k; }