From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-8.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2D1DFCA9EAF for ; Thu, 24 Oct 2019 06:23:16 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id E9FFA2166E for ; Thu, 24 Oct 2019 06:23:15 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org E9FFA2166E Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=linux-m68k.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 71BE36B0005; Thu, 24 Oct 2019 02:23:15 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 6CCE36B0006; Thu, 24 Oct 2019 02:23:15 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 5E3FA6B0007; Thu, 24 Oct 2019 02:23:15 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0173.hostedemail.com [216.40.44.173]) by kanga.kvack.org (Postfix) with ESMTP id 4F3436B0005 for ; Thu, 24 Oct 2019 02:23:15 -0400 (EDT) Received: from smtpin22.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay03.hostedemail.com (Postfix) with SMTP id C7DC782499A8 for ; Thu, 24 Oct 2019 06:23:14 +0000 (UTC) X-FDA: 76077685908.22.skin82_1c4467d8d733b X-HE-Tag: skin82_1c4467d8d733b X-Filterd-Recvd-Size: 5126 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by imf09.hostedemail.com (Postfix) with ESMTP for ; Thu, 24 Oct 2019 06:23:14 +0000 (UTC) Received: from [10.44.0.22] (unknown [103.48.210.53]) (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 2C14921655; Thu, 24 Oct 2019 06:23:06 +0000 (UTC) Subject: Re: [PATCH 04/12] m68k: nommu: use pgtable-nopud instead of 4level-fixup To: Mike Rapoport Cc: linux-mm@kvack.org, Andrew Morton , Anton Ivanov , Arnd Bergmann , "David S. Miller" , Geert Uytterhoeven , Greentime Hu , Helge Deller , "James E.J. Bottomley" , Jeff Dike , "Kirill A. Shutemov" , Linus Torvalds , Mark Salter , Matt Turner , Michal Simek , Richard Weinberger , Russell King , Sam Creasey , Vincent Chen , Vineet Gupta , linux-alpha@vger.kernel.org, linux-arch@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-c6x-dev@linux-c6x.org, linux-kernel@vger.kernel.org, linux-m68k@lists.linux-m68k.org, linux-parisc@vger.kernel.org, linux-um@lists.infradead.org, sparclinux@vger.kernel.org, Mike Rapoport References: <1571822941-29776-1-git-send-email-rppt@kernel.org> <1571822941-29776-5-git-send-email-rppt@kernel.org> <20191024053533.GA12281@rapoport-lnx> From: Greg Ungerer Message-ID: <24454c38-184a-b5fe-e534-aad3713c157e@linux-m68k.org> Date: Thu, 24 Oct 2019 16:23:04 +1000 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.9.0 MIME-Version: 1.0 In-Reply-To: <20191024053533.GA12281@rapoport-lnx> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Hi Mike, On 24/10/19 3:35 pm, Mike Rapoport wrote: > Hi Greg, >=20 > On Thu, Oct 24, 2019 at 02:09:01PM +1000, Greg Ungerer wrote: >> Hi Mike, >> >> On 23/10/19 7:28 pm, Mike Rapoport wrote: >>> From: Mike Rapoport >>> >>> The generic nommu implementation of page table manipulation takes car= e of >>> folding of the upper levels and does not require fixups. >>> >>> Simply replace of include/asm-generic/4level-fixup.h with >>> include/asm-generic/pgtable-nopud.h. >>> >>> Signed-off-by: Mike Rapoport >>> --- >>> arch/m68k/include/asm/pgtable_no.h | 2 +- >>> 1 file changed, 1 insertion(+), 1 deletion(-) >>> >>> diff --git a/arch/m68k/include/asm/pgtable_no.h b/arch/m68k/include/a= sm/pgtable_no.h >>> index c18165b..ccc4568 100644 >>> --- a/arch/m68k/include/asm/pgtable_no.h >>> +++ b/arch/m68k/include/asm/pgtable_no.h >>> @@ -2,7 +2,7 @@ >>> #ifndef _M68KNOMMU_PGTABLE_H >>> #define _M68KNOMMU_PGTABLE_H >>> -#include >>> +#include >>> /* >>> * (C) Copyright 2000-2002, Greg Ungerer >> >> This fails to compile for me (targeting m5208evb_defconfig): >> >> CC init/main.o >> In file included from ./arch/m68k/include/asm/pgtable_no.h:56:0, >> from ./arch/m68k/include/asm/pgtable.h:3, >> from ./include/linux/mm.h:99, >> from ./include/linux/ring_buffer.h:5, >> from ./include/linux/trace_events.h:6, >> from ./include/trace/syscall.h:7, >> from ./include/linux/syscalls.h:85, >> from init/main.c:21: >> ./include/asm-generic/pgtable.h:738:34: error: unknown type name =E2=80= =98pmd_t=E2=80=99 >> static inline int pmd_soft_dirty(pmd_t pmd) >> ^ >=20 > ... >=20 >> scripts/Makefile.build:265: recipe for target 'init/main.o' failed >> make[1]: *** [init/main.o] Error 1 >> Makefile:1649: recipe for target 'init' failed >> make: *** [init] Error 2 >=20 > The hunk below fixes the build. >=20 > diff --git a/arch/m68k/include/asm/page.h b/arch/m68k/include/asm/page.= h > index c00b67a..05e1e1e 100644 > --- a/arch/m68k/include/asm/page.h > +++ b/arch/m68k/include/asm/page.h > @@ -21,7 +21,7 @@ > /* > * These are used to make use of C type-checking.. > */ > -#if CONFIG_PGTABLE_LEVELS =3D=3D 3 > +#if !defined(CONFIG_MMU) || CONFIG_PGTABLE_LEVELS =3D=3D 3 > typedef struct { unsigned long pmd[16]; } pmd_t; > #define pmd_val(x) ((&x)->pmd[0]) > #define __pmd(x) ((pmd_t) { { (x) }, }) That looks better. Thanks. Tested and working on m68knommu. For the combined patches: Acked-by: Greg Ungerer Regards Greg