Received: by 2002:a25:6193:0:0:0:0:0 with SMTP id v141csp625704ybb; Fri, 3 Apr 2020 08:56:21 -0700 (PDT) X-Google-Smtp-Source: APiQypI7aMwaNdQKHWHGXNqHVSCaMYDRNcoGMnmGGYfxYjNSllc7qWQFp+doADRuqENPqa+A2bmN X-Received: by 2002:a05:6808:206:: with SMTP id l6mr3604210oie.147.1585929381324; Fri, 03 Apr 2020 08:56:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1585929381; cv=none; d=google.com; s=arc-20160816; b=VdmO2UfyiRR0EW0YgsWYjBmYVygUe86mwfX+OfcPYI3pZ97+BW1mIvoyDM5QXwRn4A S9dQyzbsCXzgcFK868NV7Bak5BP5LbuQoQOI8J0+3P8vKyzrAAiMM58/h6ldTGt07KsB bVyQ5yIjqmoX0FYL4AoSSv3C75ggap7TBOTPw9WHdHaG1N1PnRpN6m74f3Opl5x+vhSp Y1V4bJnqiBxZdfO5n6MGNIJ2X728RNyM1ty4LHXTw7MaMWH/uH69gz/LK12pQFWu4DAs rbOXrzQMKXhMIo46LLgm3DE7ssjAF7cY5OZlWzhD8Fg7cL/xmTDCNVbtIgzXzReE9fFl Pl+g== 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 :message-id:to:from:cc:in-reply-to:subject:date:dkim-signature; bh=owgGAHZSGNRil4KZ/mw3izwPWS/tP0UsXJUitXCRVu8=; b=EfwEDKmI+Gc9OTrHhNPRs8vFLW0Qcqi/wi9rqx6ipvFMg9Z4OUJOuDSResr93RrbqM ysR3UINMJK0Nuwg9W6mTLzNTGamBvGxVClbu8hBaoe78UAMCB3fmP3011wHrar0yONSm txz4NN3jYzVmkZQXTdvPfCEZGCMxLzRLXvs/hIToaFcnCKkzQl89MAt3ZQM15nUVn78U kdEC0arAronTni9KSfVYLUK6jRcH1Lu5wDrg1ekVFDo/gQOtJ/EucEt7VLXszeTQB5Nn zUkx3oF4nBHrwre70hsUEAQ+h4sswau8Jee7pLA2L1S28vkbyOOj8/qo+81oe67wjlIl ky+g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@dabbelt-com.20150623.gappssmtp.com header.s=20150623 header.b=CUidE9OM; 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 c133si4098261oif.272.2020.04.03.08.56.08; Fri, 03 Apr 2020 08:56:21 -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=@dabbelt-com.20150623.gappssmtp.com header.s=20150623 header.b=CUidE9OM; 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 S1728268AbgDCPxQ (ORCPT + 99 others); Fri, 3 Apr 2020 11:53:16 -0400 Received: from mail-pl1-f193.google.com ([209.85.214.193]:35834 "EHLO mail-pl1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727927AbgDCPxP (ORCPT ); Fri, 3 Apr 2020 11:53:15 -0400 Received: by mail-pl1-f193.google.com with SMTP id c12so2841298plz.2 for ; Fri, 03 Apr 2020 08:53:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=dabbelt-com.20150623.gappssmtp.com; s=20150623; h=date:subject:in-reply-to:cc:from:to:message-id:mime-version :content-transfer-encoding; bh=owgGAHZSGNRil4KZ/mw3izwPWS/tP0UsXJUitXCRVu8=; b=CUidE9OMULKs/p+pZoJ2W3cCMfdlp1mq2Ce4gohC0F8wlVWB3a2pfxjRPX6bwvyA3Y /XTWjfyag+RP6/6ZNEqe1Q8TAQU5L7t/bRb1o7QxtRgeokfWSSziQSYnRZOgbJ+Zyk1p Z8s1CZWxzZxkCu1f2pMoVq2po2eaivsyY4OalQMiMGlCBH0E8DOTNIR1vBaN5fCiOJbU KDuIttH0EQu31c4YTJL6Rr7VTt0uUF54Ic7fwfO4wULP4dUBB3WUwAYgE37gtHNj+e1g MNvLKo3LECSkxcCu+jvfPhiJrbvbwXdwl3yMPovkPnSTG2nzzAcAkS8a7hGW279SogEx Defg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:subject:in-reply-to:cc:from:to:message-id :mime-version:content-transfer-encoding; bh=owgGAHZSGNRil4KZ/mw3izwPWS/tP0UsXJUitXCRVu8=; b=i2eA+Bvf10QYP0HR6clfwElPBhMqZHtAD20j/IL4l4w/OgZ8c13j6tB3k9iibDwZ8N +C6St7acoJzY0DcypnRtRQhUxmnTeiYOfV7uQMCK7txzn1ZCfwcEBQgQnETYwOOx14mw 05pQwzr96/mFY/cYsRecOah5HPPWXnvJ+w+uVc6gTZlVppnww6y90F05Vdgn7BwL/vUt Q5VpF1jmd+FG4HecITLk+KVLN1RNjnPVYIKc4AD2I2WidkvTE09NZy7SgWFeUVVZZyqJ OwaVB0QW4sk3KoowN1kr4LBMzYyjW+w28IbmZFM96Oz6e1Reg0l1bTuaDI+gcEgowKn7 rE/Q== X-Gm-Message-State: AGi0PuaVKCtlp8SjisVtlv7BpPrxPgJxw6FZDtZYqGEd7012jg03PjFN O/Tvhn7yky8ZlanOTmT230Y4/A== X-Received: by 2002:a17:90b:3610:: with SMTP id ml16mr10796623pjb.106.1585929192570; Fri, 03 Apr 2020 08:53:12 -0700 (PDT) Received: from localhost (76-210-143-223.lightspeed.sntcca.sbcglobal.net. [76.210.143.223]) by smtp.gmail.com with ESMTPSA id w9sm6122572pfd.94.2020.04.03.08.53.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 03 Apr 2020 08:53:11 -0700 (PDT) Date: Fri, 03 Apr 2020 08:53:11 -0700 (PDT) X-Google-Original-Date: Fri, 03 Apr 2020 08:21:21 PDT (-0700) Subject: Re: [RFC PATCH 3/7] riscv: Simplify MAXPHYSMEM config In-Reply-To: <20200322110028.18279-4-alex@ghiti.fr> CC: Paul Walmsley , zong.li@sifive.com, anup@brainfault.org, Christoph Hellwig , linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, alex@ghiti.fr From: Palmer Dabbelt To: alex@ghiti.fr Message-ID: Mime-Version: 1.0 (MHng) Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, 22 Mar 2020 04:00:24 PDT (-0700), alex@ghiti.fr wrote: > Either the user specifies maximum physical memory size of 2GB or the > user lives with the system constraint which is 128GB in 64BIT for now. > > Signed-off-by: Alexandre Ghiti > --- > arch/riscv/Kconfig | 20 ++++++-------------- > 1 file changed, 6 insertions(+), 14 deletions(-) > > diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig > index 8e4b1cbcf2c2..a475c78e66bc 100644 > --- a/arch/riscv/Kconfig > +++ b/arch/riscv/Kconfig > @@ -104,7 +104,7 @@ config PAGE_OFFSET > default 0xC0000000 if 32BIT && MAXPHYSMEM_2GB > default 0x80000000 if 64BIT && !MMU > default 0xffffffff80000000 if 64BIT && MAXPHYSMEM_2GB > - default 0xffffffe000000000 if 64BIT && MAXPHYSMEM_128GB > + default 0xffffffe000000000 if 64BIT && !MAXPHYSMEM_2GB > > config ARCH_FLATMEM_ENABLE > def_bool y > @@ -216,19 +216,11 @@ config MODULE_SECTIONS > bool > select HAVE_MOD_ARCH_SPECIFIC > > -choice > - prompt "Maximum Physical Memory" > - default MAXPHYSMEM_2GB if 32BIT > - default MAXPHYSMEM_2GB if 64BIT && CMODEL_MEDLOW > - default MAXPHYSMEM_128GB if 64BIT && CMODEL_MEDANY > - > - config MAXPHYSMEM_2GB > - bool "2GiB" > - config MAXPHYSMEM_128GB > - depends on 64BIT && CMODEL_MEDANY > - bool "128GiB" > -endchoice > - > +config MAXPHYSMEM_2GB > + bool "Maximum Physical Memory 2GiB" > + default y if 32BIT > + default y if 64BIT && CMODEL_MEDLOW > + default n > > config SMP > bool "Symmetric Multi-Processing" I'm not sure this actually helps with anything, but if it's all going away then it's fine. Originally the 2G/128G stuff was there to allow for larger VA spaces in the future.