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 Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id DD372ECAAD4 for ; Tue, 30 Aug 2022 21:07:24 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 9F3BC845F4; Tue, 30 Aug 2022 23:07:22 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=quarantine dis=none) header.from=paral.in Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Received: by phobos.denx.de (Postfix, from userid 109) id 4A11C84994; Tue, 30 Aug 2022 22:29:13 +0200 (CEST) Received: from mail-pf1-f173.google.com (mail-pf1-f173.google.com [209.85.210.173]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 6BAD18021D for ; Tue, 30 Aug 2022 22:29:10 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=quarantine dis=none) header.from=paral.in Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=kidovate@gmail.com Received: by mail-pf1-f173.google.com with SMTP id c66so2197850pfc.10 for ; Tue, 30 Aug 2022 13:29:10 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:message-id:date:references:in-reply-to:subject:cc:cc :to:from:x-gm-message-state:from:to:cc; bh=pBv/tslIkZTZ+vi8/J7tRdxf3IEBS2Ll2J9orbSmR+Y=; b=UQElS8Hkug1W0mfldtL+crnTBxxJnvLr28t2gI0dwGkzMdG+OgfNNnXH2NSUEdtwth HATw8rRsKvNA/wG8LgX/Mr+f1y5hWFEKu5VKRSTgQypsD0X3fiTIPuRC4uytQBgrduA8 TSMAB5x71eRylAeme73YEJFHKmLLx5XqmZFbIDG0o8wGkkitawxfaCVM6qkbdq6LY6Wy RfkUf1sdCgSfvN+FjzZxxJ53VFVzhHu6iENOPU5qWu7XfAjm1x/E3680I+mgPiDYvn1C Zwed3WeQmL0Y1qzmE92xlAz4QNx9x1Olh9hvYT6MzS3gEP4mMC2pNyCFXgu3Tq8sTjBg vXFg== X-Gm-Message-State: ACgBeo3UsH/G734ubrJFxbjOsfVZQExDLsAwvJ68NUnucxRyhGcJ9Wti fOVm8Rds3RiDG+9ddyHhJzk= X-Google-Smtp-Source: AA6agR7RBCCntiPxYEApjvi9uJlk70YWKLJLuT/eV2HhPVd9JR9mgC/5rC6H7y41lGb5TEQPZlkIIA== X-Received: by 2002:a05:6a00:2349:b0:536:bf09:9c0a with SMTP id j9-20020a056a00234900b00536bf099c0amr22986598pfj.32.1661891348686; Tue, 30 Aug 2022 13:29:08 -0700 (PDT) Received: from forge (ip184-189-231-225.sb.sd.cox.net. [184.189.231.225]) by smtp.gmail.com with ESMTPSA id i22-20020a631316000000b0041c30f78fa6sm1987988pgl.69.2022.08.30.13.29.07 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Aug 2022 13:29:07 -0700 (PDT) From: Christian Stewart To: Heiko Cc: Rick Chen , Leo , Aurelien Jarno , Heinrich Schuchardt , u-boot@lists.denx.de, Alexandre Ghiti , Coelacanthus Cc: Subject: Re: [PATCH] riscv: Fix build against binutils 2.38 In-Reply-To: <2249202.ElGaqSPkdT@diego> (heiko@sntech.de's message of "Thu, 23 Jun 2022 15:40:18 +0200") References: <20220128134713.2322800-1-alexandre.ghiti@canonical.com> <2249202.ElGaqSPkdT@diego> Date: Tue, 30 Aug 2022 13:28:56 -0700 Message-ID: <87sfldfpbr.fsf@paral.in> MIME-Version: 1.0 Content-Type: text/plain X-Mailman-Approved-At: Tue, 30 Aug 2022 23:07:21 +0200 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.6 at phobos.denx.de X-Virus-Status: Clean Hi all, Am Freitag, 28. Januar 2022, 14:47:13 CEST schrieb Alexandre Ghiti: > The following description is copied from the equivalent patch for the > Linux Kernel proposed by Aurelien Jarno: > > From version 2.38, binutils default to ISA spec version 20191213. This > means that the csr read/write (csrr*/csrw*) instructions and fence.i > instruction has separated from the `I` extension, become two standalone > extensions: Zicsr and Zifencei. As the kernel uses those instruction, > this causes the following build failure: > > arch/riscv/cpu/mtrap.S: Assembler messages: > arch/riscv/cpu/mtrap.S:65: Error: unrecognized opcode `csrr a0,scause' > arch/riscv/cpu/mtrap.S:66: Error: unrecognized opcode `csrr a1,sepc' > arch/riscv/cpu/mtrap.S:67: Error: unrecognized opcode `csrr a2,stval' > arch/riscv/cpu/mtrap.S:70: Error: unrecognized opcode `csrw sepc,a0' > > Signed-off-by: Alexandre Ghiti Heiko wrote: > Is there progress in getting this patch applied to u-boot in some way? > Also it looks like there was another patch with similar content submitted > recently [0]. > > In any case: > > On a D1-Nezha it fixes the build (and boot) > Tested-by: Heiko Stuebner Fixes the boot with u-boot in Buildroot: [0] https://lore.kernel.org/all/PH7PR14MB5594FD11D1BE74284F554BEBCED49@PH7PR14MB5594.namprd14.prod.outlook.com/ [1] https://github.com/skiffos/u-boot/commit/3bb93519563146419aa06e8d21394089163302b6 This is for a few Risc-v boards based on D1. Tested-by: Christian Stewart Thanks & best, Christian Stewart