Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp4937786ybf; Wed, 4 Mar 2020 13:51:50 -0800 (PST) X-Google-Smtp-Source: ADFU+vuv5JbtlChO/RzQ6bNQz3MtG2ptrP6rKwnoqOkv/WtFlgkNUSCwDjmiLdZU+15Bhyko5le5 X-Received: by 2002:a05:6830:15d3:: with SMTP id j19mr3792407otr.51.1583358710616; Wed, 04 Mar 2020 13:51:50 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1583358710; cv=none; d=google.com; s=arc-20160816; b=mcoz7ZPkM5aNdmcuWtJoDFx9d+vLOhiDKfr8ZhfRwPMl2fo6TKK5pJwoNkkweGxR/E MM4r45qj+r1KHgDZ5tv03BIAe/UaE4SKiIF/B5e5nuAEbpfUBRaeoV0rCtaCwTrliJzW +eJtN09e+EIMDbnV3c30L6ivfeaM1gFuVVfr7UAQarcQo2HUcCsjdoRzlmIQFdRrEiTI 2VuagdZ1sVFpN3UKb8zsPOx+2eE5xQZaz2L9xbjKZQsIBe6M25/W9YcJeDS2sGom5e79 elp9VfEXk/r8TbDJiWjLaLtHJKRqEDjneUda5O3N5egaIBrCJ4b0TQYXuK4qNqCYD5Nc OrtA== 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=T+FdcFfDtwhQccBKWARRAr6ihm0aho+o41U3xi/SwOU=; b=qSWadMjLkCsMkbAvjVBOLIsDtKbMsRe1AUwrAo1n1o8KHBhVTvQOcmEgHyhNUl/gYn KyWzrrkvOHG0e4iLcjJHxIdxxQsY2lYxx+s0KpI1R1/cwrZA+Rs8cUj9NJbgk19LR8XM oNiGBgwrDW5aZVlaFetTCSNpACIeLyHoT0F4xlv0ebNypdBeJqgz5WhH1sY9avK2/aJm eMn7DfNGPXD0+w18EyzQT2GDK34yTGJhnaZ2yrhe6HbMq866BBM+LX5HUMjzCFfLmA/Z VlGAuVxtkm4+kUGuK6VbThrUjs2PAZwS5DN7IAf+UcaDQucTbUOfrQw15+VWW3+vRIY6 XMZg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=LmWDx1sW; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l1si2058671otn.213.2020.03.04.13.51.39; Wed, 04 Mar 2020 13:51:50 -0800 (PST) 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=LmWDx1sW; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388399AbgCDVvP (ORCPT + 99 others); Wed, 4 Mar 2020 16:51:15 -0500 Received: from mail.kernel.org ([198.145.29.99]:34234 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388338AbgCDVvO (ORCPT ); Wed, 4 Mar 2020 16:51:14 -0500 Received: from mail-wr1-f49.google.com (mail-wr1-f49.google.com [209.85.221.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id ED5DC21744 for ; Wed, 4 Mar 2020 21:51:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1583358674; bh=XvJqeL9Dkwgz8DG/GvAWCcKvRlJMAOJtbu4NVFvKZTc=; h=References:In-Reply-To:From:Date:Subject:To:Cc:From; b=LmWDx1sWG0yVE0/Eh7z7VqCtWsxacrnGIghlxQgHOyPF3CwSZfGTAcXb5DGXys6L3 xwjnQ1wR1+Uy1B7y3igsW52Du5QuYOYpQQUwPP9RgaVPPcljdfJ+tofOXLfh9UrYlG L7Mhu0m/Q69F2D2vyVZS1+zKPtBPRLEM/nWYuSCk= Received: by mail-wr1-f49.google.com with SMTP id h9so4390221wrr.10 for ; Wed, 04 Mar 2020 13:51:13 -0800 (PST) X-Gm-Message-State: ANhLgQ2dEXK+qQwCx0rbAZWg5uQXHI2BLMnSDTG1QJYugQquWSUrPFIs HD+Osv6xiNyFyVyYwokQYD7M8z/TadKK1FUxjMM4pA== X-Received: by 2002:adf:f84a:: with SMTP id d10mr6182793wrq.208.1583358672314; Wed, 04 Mar 2020 13:51:12 -0800 (PST) MIME-Version: 1.0 References: <20200303205445.3965393-1-nivedita@alum.mit.edu> <20200303205445.3965393-2-nivedita@alum.mit.edu> <20200304154908.GB998825@rani.riverdale.lan> <20200304185042.GA281042@rani.riverdale.lan> <20200304191053.GA291311@rani.riverdale.lan> <20200304195447.GA295419@rani.riverdale.lan> In-Reply-To: <20200304195447.GA295419@rani.riverdale.lan> From: Ard Biesheuvel Date: Wed, 4 Mar 2020 22:51:01 +0100 X-Gmail-Original-Message-ID: Message-ID: Subject: Re: [PATCH 1/4] x86/mm/pat: Handle no-GBPAGES case correctly in populate_pud To: Arvind Sankar Cc: Dave Hansen , Andy Lutomirski , Peter Zijlstra , Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , "the arch/x86 maintainers" , linux-efi , Linux Kernel Mailing List 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 Wed, 4 Mar 2020 at 20:54, Arvind Sankar wrote: > > On Wed, Mar 04, 2020 at 08:22:36PM +0100, Ard Biesheuvel wrote: > > The wrong one, obviously :-) > > > > With Haswell, I get [before] > > > > [ 0.368541] 0x0000000000900000-0x0000000000a00000 1M > > RW NX pte > > [ 0.369118] 0x0000000000a00000-0x0000000080000000 2038M > > RW PSE NX pmd > > [ 0.369592] 0x0000000080000000-0x00000000b9800000 920M > > pmd > > [ 0.370177] 0x00000000b9800000-0x00000000b9856000 344K > > pte > ^^ so this is showing the region that didn't get mapped, so you did > reproduce the issue. > > [ 0.370649] 0x00000000b9856000-0x00000000b9a00000 1704K > > RW NX pte > > [ 0.371066] 0x00000000b9a00000-0x00000000baa00000 16M > > ro PSE x pmd > > > > and after > > > > [ 0.349577] 0x0000000000a00000-0x0000000080000000 2038M > > RW PSE NX pmd > > [ 0.350049] 0x0000000080000000-0x00000000b9800000 920M > > pmd > > [ 0.350514] 0x00000000b9800000-0x00000000b9856000 344K > > pte > ^^ but it didn't get fixed :( This region should now be mapped properly > with flags RW/NX. > > [ 0.351013] 0x00000000b9856000-0x00000000b9a00000 1704K > > RW NX pte > > > > so i'm still doing something wrong, I think? > > You're *sure* the after is actually after? There seems to be no change > at all, the patch should have had some effect. Duh. Yes, you are right. It was 'operator error'