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.6 required=3.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS 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 B5ED0C433ED for ; Thu, 6 May 2021 06:38:33 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id 21B0E6140F for ; Thu, 6 May 2021 06:38:33 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 21B0E6140F Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=dabbelt.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=owner-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix) id 646F16B006C; Thu, 6 May 2021 02:38:32 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 623586B006E; Thu, 6 May 2021 02:38:32 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 4B8976B0070; Thu, 6 May 2021 02:38:32 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0029.hostedemail.com [216.40.44.29]) by kanga.kvack.org (Postfix) with ESMTP id 306316B006C for ; Thu, 6 May 2021 02:38:32 -0400 (EDT) Received: from smtpin18.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id DE913180AD830 for ; Thu, 6 May 2021 06:38:31 +0000 (UTC) X-FDA: 78109852422.18.5411FAF Received: from mail-pj1-f49.google.com (mail-pj1-f49.google.com [209.85.216.49]) by imf16.hostedemail.com (Postfix) with ESMTP id C58CD80192F1 for ; Thu, 6 May 2021 06:38:22 +0000 (UTC) Received: by mail-pj1-f49.google.com with SMTP id g24so2803188pji.4 for ; Wed, 05 May 2021 23:38:31 -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=4pB76DI3Wkv2k+3Ah6E6o80wVVbTYgSMN4+zljmic/s=; b=F3VwvTrhJqDf7jP0FJSLtwO120b7Mf8vKLXOH2MJocvZQJMphG+bHlfFJe8MPPcKHO YXhVQS6DfmJyJMCgM5LZnWZHyG3tQt73DRmd3ICxYECMLEo/MYOVZKOhyVCKR5CmgVac 9BR3mf5u2IkbAbcbOvELUusMbfM/jhczAPgMkHd2w/aGpc0p8K0Vuxj3LWqwo2iX8jGI MsxPvwddQr+NARZBgN3sZbiYBaLwj3bT3PgPVbSg76PuRiKfStkZqyepZPwhBo/42lIC 0hYWSeF4bbbeFe5P4gvik60dLfaeaauTh5PqFNC4gy2nxGwOHNtgJO0V2wLUTmC+shqQ pD9w== 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=4pB76DI3Wkv2k+3Ah6E6o80wVVbTYgSMN4+zljmic/s=; b=fNid0C3z0VTN/k2NNg/YvOS2SUTh3Pj+IF8GlWyWx/62M3IgFM/C7tRCISvME2Qxy4 xOQ5Bn7wIIvHVRaqM21gVVwRdMLy5VWHfbaQdDGZR+ELqg++3YkqQlh0k718yx33X1sz zFXdoIX7x52WFoAnpuVvVzV8WyNSmVkZ1pi8BAAhPHLrXGTfb7x+KEHbL4eORPYjI930 3n9nGlAxnz8YpNNk7T0UXkzHr/3RjFPjM65Yg+2H5M7odpn6EOw4Ur44J7CdaxW6skRP X+7oWuyfNpUk0BWU9XJxqStlIhrUCjZ5kwZ9I25gX8lyWqPhpTtOLOR6AJf/qPOwWm8x Qmtg== X-Gm-Message-State: AOAM533T6n1vm7HCVKwDjAmIJsNUu6rif6IWL5eNTsn0kOtEqqyQKqNv bgFGb8AQ95Qeng7Bg2bH9c0Seg== X-Google-Smtp-Source: ABdhPJwjlJoVmo+6a8XDUXjGWJK6yuc+LZUn/I5j2bvw1wuEzN68RA3bmZmY0Echj2/a31sOJGD7bg== X-Received: by 2002:a17:902:7081:b029:ed:5f:20af with SMTP id z1-20020a1709027081b02900ed005f20afmr3082620plk.60.1620283110274; Wed, 05 May 2021 23:38:30 -0700 (PDT) Received: from localhost (76-210-143-223.lightspeed.sntcca.sbcglobal.net. [76.210.143.223]) by smtp.gmail.com with ESMTPSA id n129sm1143567pfn.54.2021.05.05.23.38.29 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 05 May 2021 23:38:29 -0700 (PDT) Date: Wed, 05 May 2021 23:38:29 -0700 (PDT) X-Google-Original-Date: Wed, 05 May 2021 23:38:26 PDT (-0700) Subject: Re: [PATCH v8] RISC-V: enable XIP In-Reply-To: CC: alex@ghiti.fr, vitaly.wool@konsulko.com, Paul Walmsley , aou@eecs.berkeley.edu, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arch@vger.kernel.org, linux-mm@kvack.org, lkft-triage@lists.linaro.org From: Palmer Dabbelt To: naresh.kamboju@linaro.org Message-ID: Mime-Version: 1.0 (MHng) Content-Type: text/plain; charset=utf-8; format=flowed Authentication-Results: imf16.hostedemail.com; dkim=pass header.d=dabbelt-com.20150623.gappssmtp.com header.s=20150623 header.b=F3VwvTrh; dmarc=none; spf=pass (imf16.hostedemail.com: domain of palmer@dabbelt.com designates 209.85.216.49 as permitted sender) smtp.mailfrom=palmer@dabbelt.com X-Rspamd-Server: rspam03 X-Stat-Signature: gty5uzmh5qcsmyz945xgz719d1ar197b X-Rspamd-Queue-Id: C58CD80192F1 Received-SPF: none (dabbelt.com>: No applicable sender policy available) receiver=imf16; identity=mailfrom; envelope-from=""; helo=mail-pj1-f49.google.com; client-ip=209.85.216.49 X-HE-DKIM-Result: pass/pass X-HE-Tag: 1620283102-595169 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: On Mon, 26 Apr 2021 09:46:16 PDT (-0700), naresh.kamboju@linaro.org wrote= : > my two cents, > > The riscv build failed on Linux -next 20210426 tag kernel due to > below warnings / errors. > Following builds failed. > - riscv (tinyconfig) with gcc-8 > - riscv (allnoconfig) with gcc-8 > - riscv (tinyconfig) with gcc-9 > - riscv (allnoconfig) with gcc-9 > - riscv (tinyconfig) with gcc-10 > - riscv (allnoconfig) with gcc-10 > >> >> > diff --git a/arch/riscv/kernel/setup.c b/arch/riscv/kernel/setup.= c >> >> > index 30e4af0fd50c..2ddf654c72bb 100644 >> >> > --- a/arch/riscv/kernel/setup.c >> >> > +++ b/arch/riscv/kernel/setup.c >> >> > @@ -50,7 +50,11 @@ struct screen_info screen_info __section(".dat= a") =3D { >> >> > * This is used before the kernel initializes the BSS so it can'= t be in the >> >> > * BSS. >> >> > */ >> >> > -atomic_t hart_lottery __section(".sdata"); >> >> > +atomic_t hart_lottery __section(".sdata") >> >> > +#ifdef CONFIG_XIP_KERNEL >> >> > +=3D ATOMIC_INIT(0xC001BEEF) >> >> > +#endif >> >> > +; >> >> > unsigned long boot_cpu_hartid; >> >> > static DEFINE_PER_CPU(struct cpu, cpu_devices); >> >> > >> >> > @@ -254,7 +258,7 @@ void __init setup_arch(char **cmdline_p) >> >> > #if IS_ENABLED(CONFIG_BUILTIN_DTB) >> >> > unflatten_and_copy_device_tree(); >> >> > #else >> >> > - if (early_init_dt_verify(__va(dtb_early_pa))) >> >> > + if (early_init_dt_verify(__va(XIP_FIXUP(dtb_early_pa)))) > > arch/riscv/kernel/setup.c: In function 'setup_arch': > arch/riscv/kernel/setup.c:284:32: error: implicit declaration of > function 'XIP_FIXUP' [-Werror=3Dimplicit-function-declaration] > if (early_init_dt_verify(__va(XIP_FIXUP(dtb_early_pa)))) > ^~~~~~~~~ > arch/riscv/include/asm/page.h:112:62: note: in definition of macro > 'linear_mapping_pa_to_va' > #define linear_mapping_pa_to_va(x) ((void *)((unsigned long)(x) + > va_pa_offset)) > ^ > arch/riscv/include/asm/page.h:156:27: note: in expansion of macro > '__pa_to_va_nodebug' > #define __va(x) ((void *)__pa_to_va_nodebug((phys_addr_t)(x))) > ^~~~~~~~~~~~~~~~~~ > arch/riscv/kernel/setup.c:284:27: note: in expansion of macro '__va' > if (early_init_dt_verify(__va(XIP_FIXUP(dtb_early_pa)))) > ^~~~ > cc1: some warnings being treated as errors > > Reported-by: Naresh Kamboju > > > steps to reproduce: > --------------------------- > # TuxMake is a command line tool and Python library that provides > # portable and repeatable Linux kernel builds across a variety of > # architectures, toolchains, kernel configurations, and make targets. > # > # TuxMake supports the concept of runtimes. > # See https://docs.tuxmake.org/runtimes/, for that to work it requires > # that you install podman or docker on your system. > # > # To install tuxmake on your system globally: > # sudo pip3 install -U tuxmake > # > # See https://docs.tuxmake.org/ for complete documentation. > > > tuxmake --runtime podman --target-arch riscv --toolchain gcc-8 > --kconfig allnoconfig Sorry, I didn't notice this as it went by but I think I've already fixed=20 this one up.