Received: by 2002:ac0:aed5:0:0:0:0:0 with SMTP id t21csp417701imb; Fri, 1 Mar 2019 04:19:21 -0800 (PST) X-Google-Smtp-Source: APXvYqxqxSK/mlNluOjEfTxAMI3uCgDBknkr0LWCo/7d+tW1hYvsWBS20gu791S8rBA6g6BXhKbM X-Received: by 2002:a17:902:24c:: with SMTP id 70mr5342382plc.54.1551442761646; Fri, 01 Mar 2019 04:19:21 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1551442761; cv=none; d=google.com; s=arc-20160816; b=g22EKB1v5k+XyWw9jwf80ZWMZO/W07n1jRLOnB9ESxhhKgF0CGA8V1aSRpTeWZm/y+ h4o2ueYgUw/0kHbVWwdN1r5ab2OQ1ISMI2c2jK1UxfFyroan41O8aFZgt1Vwht9kw1kI mx3PS9hMhZ1oy5Y3nG1ZZhf4m5styPD+u2eWC/jVww3934yVpJNKOWYaAjMNkWRyOOy/ 8fP0OElEUBCCyOZFkRY1W/GaAbracx2egW0Z8ZjjnI4wp4p1sUCbji/DHfiXb2aO7aM6 HIpqJWwAmh7UaQFSADnh7LyCqhlVApDU8GuTD9lro557JqShQiD7ThrN6hzs1YYKXuPp gKsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:user-agent:in-reply-to :content-disposition:mime-version:references:subject:cc:to:from:date; bh=TWXh/f/vxZucfd0azlrPKeVIpV2c4umlgI75dWBLNVQ=; b=TBXGj0P8IvO+P1uOPHpdw1WifSb9Ixs9aiqEfUF1NXv8uaiUvJgUjXPxJ7lSV84Aou NfjXNMftbpp5lnrzmh+NmrKS6YWhjXXd0atlnNmT/Jyr7LtaImJkM10Yg0Ry2j+FXPtY Ng6H1jlVNzT5srzaFPiBO0eZOec7uZxL2ZzFywB4OsozeyvhWdbEucYsz2T2d4vb9uRH ZbN6VQTX6bZW3qGaaUlmUYJsQAo8QqL3h8nP013ZU05F6BhHiginAYClY+iBk6YiYa7t p2UrPdIgA8hW+S2cENHeuChsW8L8UcEdff51dnPuASRuEtopSXkunUy1IHkw3RqUI/Ar FGQg== 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; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z18si20646616pgf.66.2019.03.01.04.19.03; Fri, 01 Mar 2019 04:19:21 -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; 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=fail (p=NONE sp=NONE dis=NONE) header.from=ibm.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387710AbfCALqU (ORCPT + 99 others); Fri, 1 Mar 2019 06:46:20 -0500 Received: from mx0b-001b2d01.pphosted.com ([148.163.158.5]:50800 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S2387677AbfCALqU (ORCPT ); Fri, 1 Mar 2019 06:46:20 -0500 Received: from pps.filterd (m0098421.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.27/8.16.0.27) with SMTP id x21Bj2p1138866 for ; Fri, 1 Mar 2019 06:46:16 -0500 Received: from e06smtp03.uk.ibm.com (e06smtp03.uk.ibm.com [195.75.94.99]) by mx0a-001b2d01.pphosted.com with ESMTP id 2qy2cj5cj3-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Fri, 01 Mar 2019 06:46:13 -0500 Received: from localhost by e06smtp03.uk.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 1 Mar 2019 11:46:10 -0000 Received: from b06cxnps4074.portsmouth.uk.ibm.com (9.149.109.196) by e06smtp03.uk.ibm.com (192.168.101.133) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Fri, 1 Mar 2019 11:46:03 -0000 Received: from d06av23.portsmouth.uk.ibm.com (d06av23.portsmouth.uk.ibm.com [9.149.105.59]) by b06cxnps4074.portsmouth.uk.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id x21Bk2Cb32505906 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Fri, 1 Mar 2019 11:46:02 GMT Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 4E71CA404D; Fri, 1 Mar 2019 11:46:02 +0000 (GMT) Received: from d06av23.portsmouth.uk.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B5AB8A4051; Fri, 1 Mar 2019 11:45:57 +0000 (GMT) Received: from rapoport-lnx (unknown [9.148.204.73]) by d06av23.portsmouth.uk.ibm.com (Postfix) with ESMTPS; Fri, 1 Mar 2019 11:45:57 +0000 (GMT) Date: Fri, 1 Mar 2019 13:45:54 +0200 From: Mike Rapoport To: Steven Price Cc: Geert Uytterhoeven , Mark Rutland , the arch/x86 maintainers , Arnd Bergmann , Ard Biesheuvel , Peter Zijlstra , Catalin Marinas , Dave Hansen , Will Deacon , Linux Kernel Mailing List , Linux MM , =?iso-8859-1?B?Suly9G1l?= Glisse , Ingo Molnar , Borislav Petkov , Andy Lutomirski , "H. Peter Anvin" , James Morse , Thomas Gleixner , linux-m68k , Linux ARM , "Liang, Kan" Subject: Re: [PATCH v3 09/34] m68k: mm: Add p?d_large() definitions References: <20190227170608.27963-1-steven.price@arm.com> <20190227170608.27963-10-steven.price@arm.com> <20190228113653.GB3766@rapoport-lnx> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.24 (2015-08-30) X-TM-AS-GCONF: 00 x-cbid: 19030111-0012-0000-0000-000002FBBE46 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 19030111-0013-0000-0000-000021336E2C Message-Id: <20190301114553.GC5156@rapoport-lnx> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2019-03-01_09:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1903010083 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Feb 28, 2019 at 12:04:08PM +0000, Steven Price wrote: > On 28/02/2019 11:53, Geert Uytterhoeven wrote: > > Hi Mike, > > > > On Thu, Feb 28, 2019 at 12:37 PM Mike Rapoport wrote: > >> On Wed, Feb 27, 2019 at 08:27:40PM +0100, Geert Uytterhoeven wrote: > >>> On Wed, Feb 27, 2019 at 6:07 PM Steven Price wrote: > >>>> walk_page_range() is going to be allowed to walk page tables other than > >>>> those of user space. For this it needs to know when it has reached a > >>>> 'leaf' entry in the page tables. This information is provided by the > >>>> p?d_large() functions/macros. > >>>> > >>>> For m68k, we don't support large pages, so add stubs returning 0 > >>>> > >>>> CC: Geert Uytterhoeven > >>>> CC: linux-m68k@lists.linux-m68k.org > >>>> Signed-off-by: Steven Price > >>> > >>> Thanks for your patch! > >>> > >>>> arch/m68k/include/asm/mcf_pgtable.h | 2 ++ > >>>> arch/m68k/include/asm/motorola_pgtable.h | 2 ++ > >>>> arch/m68k/include/asm/pgtable_no.h | 1 + > >>>> arch/m68k/include/asm/sun3_pgtable.h | 2 ++ > >>>> 4 files changed, 7 insertions(+) > >>> > >> Maybe I'm missing something, but why the stubs have to be defined in > >> arch/*/include/asm/pgtable.h rather than in include/asm-generic/pgtable.h? > > > > That would even make more sense, given most architectures don't > > support huge pages. > > Where the architecture has folded a level stubs are provided by the > asm-generic layer, see this later patch: > > https://lore.kernel.org/lkml/20190227170608.27963-25-steven.price@arm.com/ > > However just because an architecture port doesn't (currently) support > huge pages doesn't mean that the architecture itself can't have large[1] > mappings at higher levels of the page table. For instance an > architecture might use large pages for the linear map but not support > huge page mappings for user space. Well, I doubt m68k can support large mappings at higher levels at all. This, IMHO, applies to many other architectures and spreading p?d_large all over those architecture seems wrong to me... > My previous posting of this series attempted to define generic versions > of p?d_large(), but it was pointed out to me that this was fragile and > having a way of knowing whether the page table was a 'leaf' is actually > useful, so I've attempted to implement for all architectures. See the > discussion here: > https://lore.kernel.org/lkml/20190221113502.54153-1-steven.price@arm.com/T/#mf0bd0155f185a19681b48a288be212ed1596e85d I'll reply on that thread, somehow I missed it then. > Steve > -- Sincerely yours, Mike.