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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3095CCDB483 for ; Tue, 17 Oct 2023 07:08:36 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 8A6E580032; Tue, 17 Oct 2023 03:08:35 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 8573780007; Tue, 17 Oct 2023 03:08:35 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 71E8A80032; Tue, 17 Oct 2023 03:08:35 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 5A30C80007 for ; Tue, 17 Oct 2023 03:08:35 -0400 (EDT) Received: from smtpin03.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 139CD40F00 for ; Tue, 17 Oct 2023 07:08:35 +0000 (UTC) X-FDA: 81354075390.03.34A6EF3 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by imf12.hostedemail.com (Postfix) with ESMTP id 133EA40020 for ; Tue, 17 Oct 2023 07:08:32 +0000 (UTC) Authentication-Results: imf12.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=nFkzCvI+; spf=pass (imf12.hostedemail.com: domain of conor@kernel.org designates 145.40.68.75 as permitted sender) smtp.mailfrom=conor@kernel.org; dmarc=pass (policy=none) header.from=kernel.org ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1697526513; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=W2bLwtGCdV+PGoS2BGnm4zuE6iSVvgyQb1le2NWb0Pk=; b=47prqKT10E9OLY1pFY2b/KBRw+g/XYyFsRnZHBZkluG1azvcTu6CIOTwryISkh/14MsK6e ePqNH+naz075wrQTVH6r+wP0EUjIULLEgRsvy1adFCnkLdyXX1AOlKRq7dQJMTvEyMxIFx kzTXZa/MOB+jl+st74w++VpQdTRdRrU= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1697526513; a=rsa-sha256; cv=none; b=c0c8s8qPo0x8hs4KJGmU2ao1UlTDK21uVsxuYr0Gni3xPmClTUx/Y0xwG+S+RHRAv5X2Qb DgHCfTodaiUgF3drhCNnVwyLQbisI+Z5rAigvvRJm+i/KyQRXTCTGk2hh0zIYivkruUcr/ loC2Ytl943cfomRvlnOevFLMnGoi9ko= ARC-Authentication-Results: i=1; imf12.hostedemail.com; dkim=pass header.d=kernel.org header.s=k20201202 header.b=nFkzCvI+; spf=pass (imf12.hostedemail.com: domain of conor@kernel.org designates 145.40.68.75 as permitted sender) smtp.mailfrom=conor@kernel.org; dmarc=pass (policy=none) header.from=kernel.org Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by ams.source.kernel.org (Postfix) with ESMTP id 6AFA2B816EC; Tue, 17 Oct 2023 07:08:31 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id E45D9C433C7; Tue, 17 Oct 2023 07:08:28 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1697526510; bh=KyBU6dt3CYdf3enQHahqiAZWcsaI56HgRKHkTWUgbgU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=nFkzCvI+aRqCWBg3782OqkE7/IaOGSk+bwDUQMjHApV9+XqtBI+W1GuuOAaHkAVS9 rHyN3swWPE0c1nObG2eOnK4aao0b58IYHChYgkrAAVLKzW9OXoWxb12K3f9CxIqJbY ejJKxQjITsFEuAlfmzKg32UwA1QHKUZHBWZJMuGYGck9oHiSvLZBlsFoTkAiLisxFf gyS3I5bWfW8he/eLTKNtVknma2uYsX80Tbcl7AvTkjmxrvC4SFRPcDmEeeCabL3sNz TG7mMP3skXidcJisMhmmzqcs1lRpnPRuD6PNRH4NnLIaEF05fiXee+EXl09bObY60/ MZ6pVIOwI8CtA== Date: Tue, 17 Oct 2023 08:08:26 +0100 From: Conor Dooley To: Charlie Jenkins Cc: linux-riscv@lists.infradead.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org, Eric Biederman , Kees Cook , Paul Walmsley , Palmer Dabbelt , Albert Ou Subject: Re: [PATCH v3 1/2] riscv: Add remaining module relocations Message-ID: <20231017-heaviness-husked-f3b81d5ecdfb@spud> References: <20231016-module_relocations-v3-0-a667fd6071e9@rivosinc.com> <20231016-module_relocations-v3-1-a667fd6071e9@rivosinc.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha256; protocol="application/pgp-signature"; boundary="wrP/R5I4xDPUBiaw" Content-Disposition: inline In-Reply-To: <20231016-module_relocations-v3-1-a667fd6071e9@rivosinc.com> X-Rspamd-Queue-Id: 133EA40020 X-Rspam-User: X-Rspamd-Server: rspam11 X-Stat-Signature: zzqeb1pb75mnfgq98bkaj37qosmk4oqa X-HE-Tag: 1697526512-57927 X-HE-Meta: U2FsdGVkX1/kCC9nQ5PgMpcTs7wR+33+oDwuaR6nMCDt+foiFeIhtEt8PeqbnTcj0xw0XbLXspuly3388hsvJBc0AYTTFVxlnCgMnPYKZVAwIGCjWTLo52Mw1IqrMECwoxdg29Httr/Te8EVAf+5xEKRYzHPXBA1sORml8/NBwAX9Ny8/y/DGkaAJ3XawnLVcG92u8nJMODDB7QAW45GWjK7EVtEv0LtHAMXzyuipPmGIqpPZq4Nwqou3Q5chsYuc4Lmz3LVDZ/I43qyxrIqblxNNgm2NtPgK3FUnrRdlrbWEZRR8KuZoFgkbFMpT/ohKGOhu84aoGEYxGhwUnxtTtNHY+K1yArwLpphcpO1BB150R/Wy/aC5a8GYCWYDToTt9yoEbOQUZTVpdSsqyo465AB3C6YFoW4Xr2tAJFnEaAfktMA22JDx/1Ez//TT3sllDWm14H1QinOjDDvwUjpk2gmsXuFFcsk/XJbv5iOWoLH3KFf1cEzaLiWeUS9Hspk2j0HeNJJxqAZllv6hqJHLGGEAAQ0Y6zkoUGKg9TzDH8vVMtu8Bn+32agtmhJ15kWxz8XtSTu9aM/Qfcz0yTX6hH5jK47it4AhzWI4dhhj2lbTrro8DXnQxZxlh2DJRXfH6KQfWcj0c8YwNyEzjiK7MGeMTzRWSNTlBqJdUxM5+FkmmuswhHNnkLLcYvouKswXq9E/WXOiBKibSpY7wg6F0lqnYc2lEX4qe0fpvsc6FVKooVx2QzVhGunf7XtXK+q8XKIUImlPPxEMW68klmbkE3sXx5MvymYRzzm431/DMyBwMLDUz2q8fr35cjhC2KrmlC4yCCwu7f9yEiblV4XoTermQz8db6v4Kd7NXv8zc3YfU7bKu6UPpbt/HkmAd2NEQ6Sox+2D1PggsEaAL39xQl8SwpEBT8yx6eJ38AIBebYmixAAMZWD3GivP2ftQRbj2xuvXlwHB8Kim+oqqC Nurj9Zl4 sRZApJ6Lmd73ofVD5wxGDnKjrYVA/a6DyMwpwKH87YCo6ipxZRK/MwNtuwGg4+l7Eb9TraEZvqr+7zQm0QvoPxSzA61ikWcmluvn+WCM8jJY7pcYv2O7BZ963YiONHpurbMaaIZWsphCPluvkBpfX5gT825d9xQW0XyPPVNT+N7iiGAyPWxwBUm1Xua9b9GGmOQ7cJE4/PntDhapZ6nVnj1JqDS/pxUxeuuo577P/4DDUAcOA+j/kGD8gfg9jTAE/0uviQwdzKvNhSlEU6bDjKEGUuoiZ7CWyoLy19fQTmGXeleVMl8ZftB+JYprgfyOB/QeDKyvx4AuPrUA1iFxXM9/j2g== 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: --wrP/R5I4xDPUBiaw Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, Oct 16, 2023 at 10:36:09AM -0700, Charlie Jenkins wrote: > Add all final module relocations and add error logs explaining the ones > that are not supported. In the patchwork automation's clang/llvm allmodconfig: ../arch/riscv/kernel/tests/module_test/test_uleb128.S:18:17: error: unknow= n relocation name ../arch/riscv/kernel/tests/module_test/test_uleb128.S:19:17: error: unknow= n relocation name (llvm-17 iirc) Cheers, Conor. >=20 > Signed-off-by: Charlie Jenkins > --- > arch/riscv/include/uapi/asm/elf.h | 6 +- > arch/riscv/kernel/module.c | 207 ++++++++++++++++++++++++++++++++= +----- > 2 files changed, 187 insertions(+), 26 deletions(-) >=20 > diff --git a/arch/riscv/include/uapi/asm/elf.h b/arch/riscv/include/uapi/= asm/elf.h > index d696d6610231..a9307a1c9ceb 100644 > --- a/arch/riscv/include/uapi/asm/elf.h > +++ b/arch/riscv/include/uapi/asm/elf.h > @@ -49,6 +49,7 @@ typedef union __riscv_fp_state elf_fpregset_t; > #define R_RISCV_TLS_DTPREL64 9 > #define R_RISCV_TLS_TPREL32 10 > #define R_RISCV_TLS_TPREL64 11 > +#define R_RISCV_IRELATIVE 58 > =20 > /* Relocation types not used by the dynamic linker */ > #define R_RISCV_BRANCH 16 > @@ -81,7 +82,7 @@ typedef union __riscv_fp_state elf_fpregset_t; > #define R_RISCV_ALIGN 43 > #define R_RISCV_RVC_BRANCH 44 > #define R_RISCV_RVC_JUMP 45 > -#define R_RISCV_LUI 46 > +#define R_RISCV_RVC_LUI 46 > #define R_RISCV_GPREL_I 47 > #define R_RISCV_GPREL_S 48 > #define R_RISCV_TPREL_I 49 > @@ -93,6 +94,9 @@ typedef union __riscv_fp_state elf_fpregset_t; > #define R_RISCV_SET16 55 > #define R_RISCV_SET32 56 > #define R_RISCV_32_PCREL 57 > +#define R_RISCV_PLT32 59 > +#define R_RISCV_SET_ULEB128 60 > +#define R_RISCV_SUB_ULEB128 61 > =20 > =20 > #endif /* _UAPI_ASM_RISCV_ELF_H */ > diff --git a/arch/riscv/kernel/module.c b/arch/riscv/kernel/module.c > index 7c651d55fcbd..73f47de538d2 100644 > --- a/arch/riscv/kernel/module.c > +++ b/arch/riscv/kernel/module.c > @@ -7,6 +7,7 @@ > #include > #include > #include > +#include > #include > #include > #include > @@ -268,6 +269,12 @@ static int apply_r_riscv_align_rela(struct module *m= e, u32 *location, > return -EINVAL; > } > =20 > +static int apply_r_riscv_add8_rela(struct module *me, u32 *location, Elf= _Addr v) > +{ > + *(u8 *)location +=3D (u8)v; > + return 0; > +} > + > static int apply_r_riscv_add16_rela(struct module *me, u32 *location, > Elf_Addr v) > { > @@ -289,6 +296,12 @@ static int apply_r_riscv_add64_rela(struct module *m= e, u32 *location, > return 0; > } > =20 > +static int apply_r_riscv_sub8_rela(struct module *me, u32 *location, Elf= _Addr v) > +{ > + *(u8 *)location -=3D (u8)v; > + return 0; > +} > + > static int apply_r_riscv_sub16_rela(struct module *me, u32 *location, > Elf_Addr v) > { > @@ -310,31 +323,149 @@ static int apply_r_riscv_sub64_rela(struct module = *me, u32 *location, > return 0; > } > =20 > -static int (*reloc_handlers_rela[]) (struct module *me, u32 *location, > - Elf_Addr v) =3D { > - [R_RISCV_32] =3D apply_r_riscv_32_rela, > - [R_RISCV_64] =3D apply_r_riscv_64_rela, > - [R_RISCV_BRANCH] =3D apply_r_riscv_branch_rela, > - [R_RISCV_JAL] =3D apply_r_riscv_jal_rela, > - [R_RISCV_RVC_BRANCH] =3D apply_r_riscv_rvc_branch_rela, > - [R_RISCV_RVC_JUMP] =3D apply_r_riscv_rvc_jump_rela, > - [R_RISCV_PCREL_HI20] =3D apply_r_riscv_pcrel_hi20_rela, > - [R_RISCV_PCREL_LO12_I] =3D apply_r_riscv_pcrel_lo12_i_rela, > - [R_RISCV_PCREL_LO12_S] =3D apply_r_riscv_pcrel_lo12_s_rela, > - [R_RISCV_HI20] =3D apply_r_riscv_hi20_rela, > - [R_RISCV_LO12_I] =3D apply_r_riscv_lo12_i_rela, > - [R_RISCV_LO12_S] =3D apply_r_riscv_lo12_s_rela, > - [R_RISCV_GOT_HI20] =3D apply_r_riscv_got_hi20_rela, > - [R_RISCV_CALL_PLT] =3D apply_r_riscv_call_plt_rela, > - [R_RISCV_CALL] =3D apply_r_riscv_call_rela, > - [R_RISCV_RELAX] =3D apply_r_riscv_relax_rela, > - [R_RISCV_ALIGN] =3D apply_r_riscv_align_rela, > - [R_RISCV_ADD16] =3D apply_r_riscv_add16_rela, > - [R_RISCV_ADD32] =3D apply_r_riscv_add32_rela, > - [R_RISCV_ADD64] =3D apply_r_riscv_add64_rela, > - [R_RISCV_SUB16] =3D apply_r_riscv_sub16_rela, > - [R_RISCV_SUB32] =3D apply_r_riscv_sub32_rela, > - [R_RISCV_SUB64] =3D apply_r_riscv_sub64_rela, > +static int dynamic_linking_not_supported(struct module *me, u32 *locatio= n, > + Elf_Addr v) > +{ > + pr_err("%s: Dynamic linking not supported in kernel modules PC =3D %p\n= ", > + me->name, location); > + return -EINVAL; > +} > + > +static int tls_not_supported(struct module *me, u32 *location, Elf_Addr = v) > +{ > + pr_err("%s: Thread local storage not supported in kernel modules PC =3D= %p\n", > + me->name, location); > + return -EINVAL; > +} > + > +static int apply_r_riscv_sub6_rela(struct module *me, u32 *location, Elf= _Addr v) > +{ > + *(u8 *)location -=3D (u8)v & 0x3F; > + return 0; > +} > + > +static int apply_r_riscv_set6_rela(struct module *me, u32 *location, Elf= _Addr v) > +{ > + *(u8 *)location =3D (*(u8 *)location & 0xc0) | ((u8)v & 0x3F); > + return 0; > +} > + > +static int apply_r_riscv_set8_rela(struct module *me, u32 *location, Elf= _Addr v) > +{ > + *(u8 *)location =3D (u8)v; > + return 0; > +} > + > +static int apply_r_riscv_set16_rela(struct module *me, u32 *location, > + Elf_Addr v) > +{ > + *(u16 *)location =3D (u16)v; > + return 0; > +} > + > +static int apply_r_riscv_set32_rela(struct module *me, u32 *location, > + Elf_Addr v) > +{ > + *(u32 *)location =3D (u32)v; > + return 0; > +} > + > +static int apply_r_riscv_32_pcrel_rela(struct module *me, u32 *location, > + Elf_Addr v) > +{ > + *(u32 *)location =3D (u32)v; > + return 0; > +} > + > +static int apply_r_riscv_plt32_rela(struct module *me, u32 *location, > + Elf_Addr v) > +{ > + *(u32 *)location =3D (u32)v; > + return 0; > +} > + > +static int apply_r_riscv_set_uleb128(struct module *me, u32 *location, E= lf_Addr v) > +{ > + /* > + * Relocation is only performed if R_RISCV_SET_ULEB128 is followed by > + * R_RISCV_SUB_ULEB128 so do computation there > + */ > + return 0; > +} > + > +static int apply_r_riscv_sub_uleb128(struct module *me, u32 *location, E= lf_Addr v) > +{ > + if (v >=3D 128) { > + pr_err("%s: uleb128 must be in [0, 127] (not %ld) at PC =3D %p\n", > + me->name, (unsigned long)v, location); > + return -EINVAL; > + } > + > + *location =3D v; > + return 0; > +} > + > +/* > + * Relocations defined in the riscv-elf-psabi-doc. > + * This handles static linking only. > + */ > +static int (*reloc_handlers_rela[])(struct module *me, u32 *location, > + Elf_Addr v) =3D { > + [R_RISCV_32] =3D apply_r_riscv_32_rela, > + [R_RISCV_64] =3D apply_r_riscv_64_rela, > + [R_RISCV_RELATIVE] =3D dynamic_linking_not_supported, > + [R_RISCV_COPY] =3D dynamic_linking_not_supported, > + [R_RISCV_JUMP_SLOT] =3D dynamic_linking_not_supported, > + [R_RISCV_TLS_DTPMOD32] =3D dynamic_linking_not_supported, > + [R_RISCV_TLS_DTPMOD64] =3D dynamic_linking_not_supported, > + [R_RISCV_TLS_DTPREL32] =3D dynamic_linking_not_supported, > + [R_RISCV_TLS_DTPREL64] =3D dynamic_linking_not_supported, > + [R_RISCV_TLS_TPREL32] =3D dynamic_linking_not_supported, > + [R_RISCV_TLS_TPREL64] =3D dynamic_linking_not_supported, > + /* 12-15 undefined */ > + [R_RISCV_BRANCH] =3D apply_r_riscv_branch_rela, > + [R_RISCV_JAL] =3D apply_r_riscv_jal_rela, > + [R_RISCV_CALL] =3D apply_r_riscv_call_rela, > + [R_RISCV_CALL_PLT] =3D apply_r_riscv_call_plt_rela, > + [R_RISCV_GOT_HI20] =3D apply_r_riscv_got_hi20_rela, > + [R_RISCV_TLS_GOT_HI20] =3D tls_not_supported, > + [R_RISCV_TLS_GD_HI20] =3D tls_not_supported, > + [R_RISCV_PCREL_HI20] =3D apply_r_riscv_pcrel_hi20_rela, > + [R_RISCV_PCREL_LO12_I] =3D apply_r_riscv_pcrel_lo12_i_rela, > + [R_RISCV_PCREL_LO12_S] =3D apply_r_riscv_pcrel_lo12_s_rela, > + [R_RISCV_HI20] =3D apply_r_riscv_hi20_rela, > + [R_RISCV_LO12_I] =3D apply_r_riscv_lo12_i_rela, > + [R_RISCV_LO12_S] =3D apply_r_riscv_lo12_s_rela, > + [R_RISCV_TPREL_HI20] =3D tls_not_supported, > + [R_RISCV_TPREL_LO12_I] =3D tls_not_supported, > + [R_RISCV_TPREL_LO12_S] =3D tls_not_supported, > + [R_RISCV_TPREL_ADD] =3D tls_not_supported, > + [R_RISCV_ADD8] =3D apply_r_riscv_add8_rela, > + [R_RISCV_ADD16] =3D apply_r_riscv_add16_rela, > + [R_RISCV_ADD32] =3D apply_r_riscv_add32_rela, > + [R_RISCV_ADD64] =3D apply_r_riscv_add64_rela, > + [R_RISCV_SUB8] =3D apply_r_riscv_sub8_rela, > + [R_RISCV_SUB16] =3D apply_r_riscv_sub16_rela, > + [R_RISCV_SUB32] =3D apply_r_riscv_sub32_rela, > + [R_RISCV_SUB64] =3D apply_r_riscv_sub64_rela, > + /* 41-42 reserved for future standard use */ > + [R_RISCV_ALIGN] =3D apply_r_riscv_align_rela, > + [R_RISCV_RVC_BRANCH] =3D apply_r_riscv_rvc_branch_rela, > + [R_RISCV_RVC_JUMP] =3D apply_r_riscv_rvc_jump_rela, > + /* 46-50 reserved for future standard use */ > + [R_RISCV_RELAX] =3D apply_r_riscv_relax_rela, > + [R_RISCV_SUB6] =3D apply_r_riscv_sub6_rela, > + [R_RISCV_SET6] =3D apply_r_riscv_set6_rela, > + [R_RISCV_SET8] =3D apply_r_riscv_set8_rela, > + [R_RISCV_SET16] =3D apply_r_riscv_set16_rela, > + [R_RISCV_SET32] =3D apply_r_riscv_set32_rela, > + [R_RISCV_32_PCREL] =3D apply_r_riscv_32_pcrel_rela, > + [R_RISCV_IRELATIVE] =3D dynamic_linking_not_supported, > + [R_RISCV_PLT32] =3D apply_r_riscv_plt32_rela, > + [R_RISCV_SET_ULEB128] =3D apply_r_riscv_set_uleb128, > + [R_RISCV_SUB_ULEB128] =3D apply_r_riscv_sub_uleb128, > + /* 62-191 reserved for future standard use */ > + /* 192-255 nonstandard ABI extensions */ > }; > =20 > int apply_relocate_add(Elf_Shdr *sechdrs, const char *strtab, > @@ -348,6 +479,10 @@ int apply_relocate_add(Elf_Shdr *sechdrs, const char= *strtab, > unsigned int i, type; > Elf_Addr v; > int res; > + bool uleb128_set_exists =3D false; > + u32 *uleb128_set_loc; > + unsigned long uleb128_set_sym_val; > + > =20 > pr_debug("Applying relocate section %u to %u\n", relsec, > sechdrs[relsec].sh_info); > @@ -425,6 +560,28 @@ int apply_relocate_add(Elf_Shdr *sechdrs, const char= *strtab, > me->name); > return -EINVAL; > } > + } else if (type =3D=3D R_RISCV_SET_ULEB128) { > + if (uleb128_set_exists) { > + pr_err("%s: riscv psABI requires the next ULEB128 relocation to come= after a R_RISCV_SET_ULEB128 is an R_RISCV_SUB_ULEB128, not another R_RISCV= _SET_ULEB128.\n", > + me->name); > + return -EINVAL; > + } > + uleb128_set_exists =3D true; > + uleb128_set_loc =3D location; > + uleb128_set_sym_val =3D > + ((Elf_Sym *)sechdrs[symindex].sh_addr + > + ELF_RISCV_R_SYM(rel[i].r_info)) > + ->st_value + > + rel[i].r_addend; > + } else if (type =3D=3D R_RISCV_SUB_ULEB128) { > + if (uleb128_set_exists && uleb128_set_loc =3D=3D location) { > + /* Calculate set and subtraction */ > + v =3D uleb128_set_sym_val - v; > + } else { > + pr_err("%s: R_RISCV_SUB_ULEB128 must always be paired with the first= R_RISCV_SET_ULEB128 that comes before it. PC =3D %p\n", > + me->name, location); > + return -EINVAL; > + } > } > =20 > res =3D handler(me, location, v); >=20 > --=20 > 2.42.0 >=20 --wrP/R5I4xDPUBiaw Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iHUEABYIAB0WIQRh246EGq/8RLhDjO14tDGHoIJi0gUCZS4y6gAKCRB4tDGHoIJi 0g/RAP4prTIEikwmfjarUNEQ6nHJtim9Tu3JCem9U9E9/JJXbQEArn/9WuTDuBoE eprdkrTp9Z5k07NPzsU3VKQnnsLyCg0= =wjaz -----END PGP SIGNATURE----- --wrP/R5I4xDPUBiaw--