Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp2285984ybb; Sat, 21 Mar 2020 18:02:09 -0700 (PDT) X-Google-Smtp-Source: ADFU+vv/U4MB6MLnOUuBin4qKuHHtHmRmz++pdAo6yamyuSNcBqXJvLV5lE6TamyKNjqfdMaEAor X-Received: by 2002:aca:5191:: with SMTP id f139mr12581477oib.140.1584838929435; Sat, 21 Mar 2020 18:02:09 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1584838929; cv=none; d=google.com; s=arc-20160816; b=BLHtyd8QOtvVeTIfRJE/RgjFhVKPXYOWwDfV+KzRJko04rneDlo9xwFaRUq/b21O2r 0M8jJKPEkIRKPIgFjgzIV95uhaScOHDHOsO0NmwMafueL9hX1Q1c+G1qiGyUp7ULzQvS a3a26y/VDMQjnaHcGveE+hzLcopHiUA/ekR9Rf/Q/gjXPYFWlHT+92quUOW9fhzxN+Oj 4KuFyDSt3AjR23DiyAkkPD1proA9XKVIfcZ8nEGLF9yvIRVvmiWuyi+PkymoiYQFjswe Ry0BD4PL/Afkk+o71PYl+cZu6i2ah+rE6WwuCs3AIyGlO5d/PZKj3XhbLS2U6VnktRhf WLNQ== 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 :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:subject; bh=7cjIiOUEcbwS/UbP8Y9TGrJNziXT15Tlta+u6JI1Diw=; b=w237uHxYv2n5501hKjOiDbCXoWPo5dMsfR0CsI1Mzx/7XX2tmqXMZ7QLoy5zj9HcSB 41iMxsPrVvJARd9X3kUZg5ODFfw145r4W0Qd34bHizbvPjZA6reKgbxB8eOIft+RQvVA fJ05lrxnni/YGnUsaiCUPv95iL9arbwd6FOM+p2QW68kkt33MW5L4MkZ6QmEsPqSQYhe kYRLw/TduFSxjRhjP3cT046APrqnA5/QapsWQRF2guKPZ2xoLE8vowo5GzC3w3T18aSX 7JLzufcPwMKpbPWgk7bmmTTVsSg7AWYhkbQvqgp+vq0fydmhxVplrdILch/dXrDM3kBi 2C2Q== ARC-Authentication-Results: i=1; mx.google.com; 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 j5si5539807otn.216.2020.03.21.18.01.55; Sat, 21 Mar 2020 18:02:09 -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; 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 S1728226AbgCVBAn (ORCPT + 99 others); Sat, 21 Mar 2020 21:00:43 -0400 Received: from foss.arm.com ([217.140.110.172]:38458 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727296AbgCVBAn (ORCPT ); Sat, 21 Mar 2020 21:00:43 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id E0B3131B; Sat, 21 Mar 2020 18:00:42 -0700 (PDT) Received: from [192.168.0.129] (unknown [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id D8DE63F305; Sat, 21 Mar 2020 18:00:38 -0700 (PDT) Subject: Re: [PATCH] x86/mm: Make pud_present() check _PAGE_PROTNONE and _PAGE_PSE as well To: John Hubbard , "Kirill A. Shutemov" Cc: linux-mm@kvack.org, Thomas Gleixner , Ingo Molnar , Borislav Petkov , "H. Peter Anvin" , Dave Hansen , Andrew Morton , x86@kernel.org, linux-kernel@vger.kernel.org, Dan Williams References: <1584507679-11976-1-git-send-email-anshuman.khandual@arm.com> <20200320114741.c62iolt2yzltnscf@box> <2e7a04cf-80cb-58c1-7344-2f8422ed7d31@arm.com> <082aae4a-b190-7b54-eda9-0bbc28c8a6b3@nvidia.com> From: Anshuman Khandual Message-ID: <0a3ac234-303c-26b7-abb7-de42025b3e0d@arm.com> Date: Sun, 22 Mar 2020 06:30:35 +0530 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <082aae4a-b190-7b54-eda9-0bbc28c8a6b3@nvidia.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 03/21/2020 01:20 AM, John Hubbard wrote: > On 3/20/20 6:22 AM, Anshuman Khandual wrote: > ... >>>> +Cc: Kirill A. Shutemov >>>> +Cc: Dan Williams >>> >>> Or we can just drop the pud_mknotpresent(). There's no users AFAICS and >>> only x86 provides it. > > +1 > >> >> Yes that will be an option but IMHO fixing pud_present() here might be >> a better choice because, >> >> (1) pud_mknotpresent() with fixed pud_present() might be required later > > > It might. Or it might not. Let's wait until it's actually used, and see. > Dead code is an avoidable expense (adds size, space on the screen, email > traffic and other wasted time), so let's avoid it here. Sure, will resend with pud_mknotpresent() dropped. > > >> (2) PMD & PUD will be exact same (THP is supported on either level) >> >> Nonetheless, I am happy to go either way. >> > > > thanks,