Received: by 2002:a05:6a10:a841:0:0:0:0 with SMTP id d1csp261817pxy; Wed, 28 Apr 2021 03:55:54 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyM/MO1kgG02TsDLngr45khjbNzBlNCQjMdVtTEISWGSBDuvuy71Oq+vyLD5KbLDrKivyXt X-Received: by 2002:a17:907:7b98:: with SMTP id ne24mr27849066ejc.304.1619607353826; Wed, 28 Apr 2021 03:55:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619607353; cv=none; d=google.com; s=arc-20160816; b=ZhKd4aslEFx6z5Ew4Rw7ubCCKWGvLNopyLYA+juuM3z/Nv1WsjP11Ffe4rYbu0Y7GQ x3G5a99Do+wsrxk7L3JR0jlF0ODKj7sa6oBziqY+Ht0ND47sS+cY+Ejlm9LNKknCJh5H 4JiGQzeUIrtr1FE8hAsPUBudm5JmCZmK7BRK+pxZI5HYPN15QR9UsRCXHHRFVEZXDWAh lUXJ4UQkKf3NZkMIkngSYxoO6DEYfbbI0dENnbBlcxl8sB5NfaCTI3hwLA4zSHpB2PZ1 OYwy6dJW6uZW8pEtb19+ZZCtPC0AJQWQiR1rX2DRsrgr42d7zIwiaGiuS/FfGgNvwOAx sYvg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:to:from; bh=FhjFqrmX6Z4m5rwG+KnoiIC7rL99vsd++HssJueXv/I=; b=jTyFUcMMth7Z1SICuLzVKqPlbcCjozZbDSRPFsW68wFuBXd9FsxQ5uDDxkqkQdE4eV A5nq5k6L5dt/+08aCLgO8v9+Z4lWOJimIGsW4v/0Y/fpSJ+wAlIN992EvVlksLhl41YT eEz5tulwEXiSMglvbSq6D0uoyZB7dxjTfmu+JnJn72KYzNCBVnbrD0WQl4JvuhCJrjd6 Jb3BVx0vpnIZzFZobxNgIQAbwyyAR6o65fbVpsa1t+B/oznO4e03b5x50PMRNER2DpX5 9Hdf14ZwZkzC4oy9YUZf76icJiFRpI7uxtgArxGaeVUCFbqRFdlwtfyl0n8sJ2HgMvc3 fWWA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w8si2723115eje.293.2021.04.28.03.55.29; Wed, 28 Apr 2021 03:55:53 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238821AbhD1KDN (ORCPT + 99 others); Wed, 28 Apr 2021 06:03:13 -0400 Received: from relay10.mail.gandi.net ([217.70.178.230]:46151 "EHLO relay10.mail.gandi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238455AbhD1KDH (ORCPT ); Wed, 28 Apr 2021 06:03:07 -0400 Received: from debian.home (lfbn-lyo-1-457-219.w2-7.abo.wanadoo.fr [2.7.49.219]) (Authenticated sender: alex@ghiti.fr) by relay10.mail.gandi.net (Postfix) with ESMTPSA id 07E77240008; Wed, 28 Apr 2021 10:02:20 +0000 (UTC) From: Alexandre Ghiti To: Paul Walmsley , Palmer Dabbelt , Albert Ou , Alexandre Ghiti , linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [PATCH] riscv: Fix 32b kernel build with CONFIG_DEBUG_VIRTUAL=y Date: Wed, 28 Apr 2021 06:02:17 -0400 Message-Id: <20210428100217.15964-1-alex@ghiti.fr> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Declare kernel_virt_addr for 32b kernel since it is used in __phys_addr_symbol defined when CONFIG_DEBUG_VIRTUAL is set. Fixes: 2bfc6cd81bd17 ("riscv: Move kernel mapping outside of linear mapping") Signed-off-by: Alexandre Ghiti --- arch/riscv/include/asm/page.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/riscv/include/asm/page.h b/arch/riscv/include/asm/page.h index e280ba60cb34..6a7761c86ec2 100644 --- a/arch/riscv/include/asm/page.h +++ b/arch/riscv/include/asm/page.h @@ -106,9 +106,9 @@ extern unsigned long pfn_base; #define ARCH_PFN_OFFSET (PAGE_OFFSET >> PAGE_SHIFT) #endif /* CONFIG_MMU */ -#ifdef CONFIG_64BIT extern unsigned long kernel_virt_addr; +#ifdef CONFIG_64BIT #define linear_mapping_pa_to_va(x) ((void *)((unsigned long)(x) + va_pa_offset)) #ifdef CONFIG_XIP_KERNEL #define kernel_mapping_pa_to_va(y) ({ \ -- 2.20.1