Received: by 2002:ab2:620c:0:b0:1ef:ffd0:ce49 with SMTP id o12csp1284515lqt; Tue, 19 Mar 2024 20:51:07 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCU8nMU79e7PgRMKb3oracaGg9w1ZicMc8rmYdm5Igu7dBOn6p+xmOqyzaB+3aLWNqIg2QZqlxFT3W0qd9nI/6YhB5/BJxqlBg9ZeZ6vEQ== X-Google-Smtp-Source: AGHT+IECSO1DzK0xi8ynvU3sNorFWDkqvX203XupIqnI4ycEwg79m1fSy+7eekhAMSAY9+VL9uqe X-Received: by 2002:a05:6808:f93:b0:3c3:84cc:fd6c with SMTP id o19-20020a0568080f9300b003c384ccfd6cmr9230014oiw.3.1710906667409; Tue, 19 Mar 2024 20:51:07 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1710906667; cv=pass; d=google.com; s=arc-20160816; b=gj8coJeIKBO7YJ2tmq7b43WM6oQnZLifbnJ2FQSruZJLIg7rdHd9ZqU7ljK0nWqTjH BXygQqoc7CRgYrO88+I827EfiEPrhVuhnrAcqozBd9rVnL/f97GTaW/uQSxZWT2c4v4+ dhgq3SgPAZCFqZluvSYGuvnKGj/WC2gwirtXMk1P7RSU6uKmAGtWGkleFXOM300YK1YX D7uZj9PIADPte8TdyWZ+ukGvuekjLmdmM0XG1PpiktKQTMAPSuGSKa7I0D6VZVO5O+l8 OufdCGLQxtCSxhELr9KQ5g8zkfvlZES4ipexZHwPP19D708Gp4wYnEi5/ixLis3nItPL +rpQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=feedback-id:in-reply-to:content-disposition:mime-version :list-unsubscribe:list-subscribe:list-id:precedence:references :message-id:subject:cc:to:from:date; bh=BXKy2nV4h7u4sFn5cq/jUhfLt0YzuC8k3NbP95Kt5Bg=; fh=8O48orQG0Q2kDVPn/0a9qWqlMD36cjTfCFwu1h0OqfI=; b=gexzT0F3ZWSOl5wq6QIyO5F7CEVqKwKTo87Fw894LG6g86jQAFqFNqKbhaNdyzcwen zp1FWGHN022gGaVCDGWiwlLUcdbTgri+99yY1rqT5Et2PkG5/BPKeOtTPldTGsyneNdP /B9mNiXm+klUJJft24DXZJGtOan0qyC4PdXDAs6UhqEmlt3+RcBcR695LWrisSSVOBDc Jvwy4jCqXKjaRWdZf5sKcxytcq5Cv2wYPlLCqR+mRRdrILvMRDOd4CWrTXjkJ9FRw508 fjo2RBnO592eVoT2MibGeiUHqRgA61sZqmlZJbBuCvZbO3A7sxBgx1RYL/oku7wFdgEy ihRw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=shingroup.cn dmarc=pass fromdomain=shingroup.cn); spf=pass (google.com: domain of linux-kernel+bounces-108414-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-108414-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=shingroup.cn Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id ca17-20020a056a02069100b005e858f5a418si985072pgb.808.2024.03.19.20.51.07 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Mar 2024 20:51:07 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-108414-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=shingroup.cn dmarc=pass fromdomain=shingroup.cn); spf=pass (google.com: domain of linux-kernel+bounces-108414-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-108414-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=shingroup.cn Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id EFFFC282FD6 for ; Wed, 20 Mar 2024 03:51:06 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 6963811C92; Wed, 20 Mar 2024 03:51:01 +0000 (UTC) Received: from smtpbgjp3.qq.com (smtpbgjp3.qq.com [54.92.39.34]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9AACB11712 for ; Wed, 20 Mar 2024 03:50:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=54.92.39.34 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710906660; cv=none; b=kUM+3tEfh0T1U8wsxYxLrD/1+jc0wc1QNPBXYLK02udTHyvRO5dKOtiLw+gpy1pF2kperbtm9IhpAMPMs5/lzpL42+bc+crIxWBFFdz1ggxfcMZoc0/QDp0PjYzwG01+B1mawmylr393y79Zz6vAjfvykgymnwhVT/r8FfhwYo8= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1710906660; c=relaxed/simple; bh=gRj6ZPy0mZ2x9b+RuAzXtz+CTfqjk6gliIeOYr/1DrU=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=VtJp8Xw0lxYI0D3mmyZYZaEFo4c+kUK0SCe+6KEcF7ynGUER1QH0OF0uHIdsb3irGeUTLvf3G8a12N/yBwymNW7yKeWjygwuBW95TZDq6NSZdzZEU4em2UT1jVkPhqdEVaDENrgGqLzxRMMjgkTs7gK/ivUX8I6SNArdvZlr8HM= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=shingroup.cn; spf=pass smtp.mailfrom=shingroup.cn; arc=none smtp.client-ip=54.92.39.34 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=shingroup.cn Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=shingroup.cn X-QQ-mid: bizesmtp65t1710906586tp2f6pfr X-QQ-Originating-IP: ox81Nrupdyl0zdBekLqxnqdZYKJsG+1Wmht5/U+355Y= Received: from localhost ( [112.0.147.175]) by bizesmtp.qq.com (ESMTP) with id ; Wed, 20 Mar 2024 11:49:45 +0800 (CST) X-QQ-SSF: 01400000000000704000000A0000000 X-QQ-FEAT: 5q30pvLz2icV16dWzMxpWQz4znvu9bgI4WfLqgyFYlBMRPt7iNpzyVaIbczF9 WEZ0DOJGNY/yB6zSpkD1wyoKcUhQ0Pgcl03s2EUIGazZ5Ou0r7cxHxgN7uunmKu4KEn2XvV 0Flj3o72P6eEL7vRjvM6+ADVrG1AQPPU/YLqtIIc9IhuI1Si9zrZFjRbEzTzbNGBeFStUK5 t37xAgb7zTyZ5im0JCDI4dDgtR2C5hZFZyeZMPVgeRoQ+x/tJuen+0nENoBY6+kOqpYGexw HTsQgn2K4Q0EjYGtMcCz6vTAnxFHYuITAGlOf0VpISBoPtX9mk7iTSjo1gy5Coj5NiTYPAD KkvkU4lAPEGHAfKkEiohcyqlO1ftieofiW3j+02jbEgANQ4e1BAIrusRRUkzg== X-QQ-GoodBg: 2 X-BIZMAIL-ID: 11659824290670290864 Date: Wed, 20 Mar 2024 11:49:44 +0800 From: Dawei Li To: Alexandre Ghiti Cc: paul.walmsley@sifive.com, palmer@dabbelt.com, aou@eecs.berkeley.edu, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, set_pte_at@outlook.com Subject: Re: [PATCH] riscv: Remove redundant CONFIG_64BIT from pgtable_l{4,5}_enabled Message-ID: <1F5AC099870F5765+Zfpc2MoIn7EU38rs@centos8> References: <20240312085005.298657-1-dawei.li@shingroup.cn> <112ac071-71cc-466e-ab13-f624edb77bb9@ghiti.fr> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <112ac071-71cc-466e-ab13-f624edb77bb9@ghiti.fr> X-QQ-SENDSIZE: 520 Feedback-ID: bizesmtp:shingroup.cn:qybglogicsvrgz:qybglogicsvrgz5a-1 Hi Alex, Thanks for review. On Tue, Mar 19, 2024 at 01:36:13PM +0100, Alexandre Ghiti wrote: > Hi Dawei, > > On 12/03/2024 09:50, Dawei Li wrote: > > IS_ENABLED(CONFIG_64BIT) in assignment of pgtable_l{4,5}_enabled is > > redundant, remove it. > > > > While at it, annotate pgtable_l{4,5}_enabled with __ro_after_init. > > > I guess this comment ^ implies that you need to split this patch into 2 :) Indeed. I Will respin v2 as you suggested. > > Feel free to add on both: > > Reviewed-by: Alexandre Ghiti > > Thanks, > > Alex Thanks, Dawei > > > > > > Signed-off-by: Dawei Li > > --- > > arch/riscv/mm/init.c | 4 ++-- > > 1 file changed, 2 insertions(+), 2 deletions(-) > > > > diff --git a/arch/riscv/mm/init.c b/arch/riscv/mm/init.c > > index fa34cf55037b..204cdf5b829d 100644 > > --- a/arch/riscv/mm/init.c > > +++ b/arch/riscv/mm/init.c > > @@ -50,8 +50,8 @@ u64 satp_mode __ro_after_init = SATP_MODE_32; > > EXPORT_SYMBOL(satp_mode); > > #ifdef CONFIG_64BIT > > -bool pgtable_l4_enabled = IS_ENABLED(CONFIG_64BIT) && !IS_ENABLED(CONFIG_XIP_KERNEL); > > -bool pgtable_l5_enabled = IS_ENABLED(CONFIG_64BIT) && !IS_ENABLED(CONFIG_XIP_KERNEL); > > +bool pgtable_l4_enabled __ro_after_init = !IS_ENABLED(CONFIG_XIP_KERNEL); > > +bool pgtable_l5_enabled __ro_after_init = !IS_ENABLED(CONFIG_XIP_KERNEL); > > EXPORT_SYMBOL(pgtable_l4_enabled); > > EXPORT_SYMBOL(pgtable_l5_enabled); > > #endif > > _______________________________________________ > linux-riscv mailing list > linux-riscv@lists.infradead.org > http://lists.infradead.org/mailman/listinfo/linux-riscv >