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.8 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS autolearn=unavailable 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 1D1A9C433ED for ; Thu, 6 May 2021 06:38:36 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id D19EF613F6 for ; Thu, 6 May 2021 06:38:35 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232377AbhEFGjc (ORCPT ); Thu, 6 May 2021 02:39:32 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54964 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229844AbhEFGj3 (ORCPT ); Thu, 6 May 2021 02:39:29 -0400 Received: from mail-pj1-x1033.google.com (mail-pj1-x1033.google.com [IPv6:2607:f8b0:4864:20::1033]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D2CE1C06174A for ; Wed, 5 May 2021 23:38:30 -0700 (PDT) Received: by mail-pj1-x1033.google.com with SMTP id fa21-20020a17090af0d5b0290157eb6b590fso2918880pjb.5 for ; Wed, 05 May 2021 23:38:30 -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=DBi3J0U/gMNKjsB0LwZ+5D1Q+LerQmb17H4luqHtBA/nLWvTW+L0R9rhwusfget9MO Ry75EbbPaJWomuh53WEkzGfbAzcicnCJ2RKSz/AyEmoIb/omv5DuRFehuqHY7SYv8f0b nsrZVD8KrsVaLdtqUP9NnB5qsmO2MM3sy3fnO0e9uOq+fw6bRupz9O/B4MtMDpPptSVx kpSO+bq924Z/HH//IABnITFOxS1ZmBwnABxuX1cBlU/o4PHr1/E1L5jNv2EdPy6vjAAm VA8spyhJ4i2AdBJX21SZoHXbKM+q9R/CxDAUT9Jnkw/NZtMbIBkYFAhFuWWxJh6g4sd/ 6tCg== X-Gm-Message-State: AOAM530RIhzM58N/ehfA+UMFrheYlYoVqe8nQmPi3wh2OQfyQdyiOmJI 6xDR7YQoqDGegJtcOe4Bz6N80A== 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 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 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(".data") = { >> >> > * 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 >> >> > += 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=implicit-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 this one up.