Received: by 2002:a05:6602:18e:0:0:0:0 with SMTP id m14csp5766615ioo; Wed, 1 Jun 2022 12:07:24 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyKy3+3T/sMwA/A9qeh6LA6ian6mY3Rg5tgugQsCKJDlUUWEBpN2WtZgEbRomBxhU0m1xF8 X-Received: by 2002:a63:5c56:0:b0:3fc:824d:fc57 with SMTP id n22-20020a635c56000000b003fc824dfc57mr714340pgm.561.1654110444236; Wed, 01 Jun 2022 12:07:24 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1654110444; cv=none; d=google.com; s=arc-20160816; b=oDFbSTWMbErWxNfBm29KQAQkZrHVp7LHUpkwyyuc4sx2CHIBzygW+uISF+xWBm4iWj ovIHC+24ix/KGOkK/qBUdMKuxqI0AXkt0ojF/b6q/j1dj6OpmleJ1q5MjxBUvY2a0yPP piHWSQVF7WT6kOhGc1mTc+c8J8dm3uQgnoLFR80f4vqa1nb1Z+mn8w3Rm/PiYIEn6B03 W6RWDoCl5rve0lgbCrD+s1R/SY2gwYDnLsDWxD46nDSYmpqXIgIdSgdNIOd7Via1/Uz9 qGiIA6+r3PVjt7SxltuQgsWGKs15y5y2Ly4N9NkGmERZAO0O9Ld5cok0Ry0RCa9fJ4jz Qw4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:from :references:cc:to:content-language:subject:user-agent:mime-version :date:message-id:dkim-signature; bh=Y4MMjPUMJE17uRA1W8JeqNIa3gV1RDtW27U/YpItROE=; b=ef603KeNmEObrlC3LNz1FfOIG6TC/PQi8f+KGyyGrAUu16mOkuXn88PYPDZ1kpNwoJ zMXG9zH+LlW+WfTiyh9BBMAVrlLVlF1QiqqDpbQolHxrgQdOKgkT5+lbavqaGEyXLNWh 9cSN52rXroJRlC35b+E2kMlcbA9dFs74gaD5CdMODAv7xe1xK7gW3Qej5ImcjS67cD4G 0dBz065VCDCEclIlTEs1U9bQggv0pGJ4YzGe2yZH/iWr0AnvnQjhSczDFdffvwxAl/mV Bk1JQ/MD17vzJV+/G7dguVry+avC36Gg5oC2Oj8HH1oAi8h/KLyQtUVOkr8C95LRrjNL GU4Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=PNPjea3B; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id u16-20020a631410000000b003fb92eb8e97si3216617pgl.119.2022.06.01.12.07.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 01 Jun 2022 12:07:24 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@infradead.org header.s=desiato.20200630 header.b=PNPjea3B; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 0AB231116D3; Wed, 1 Jun 2022 11:48:21 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1352412AbiFAQAQ (ORCPT + 99 others); Wed, 1 Jun 2022 12:00:16 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47086 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1355989AbiFAQAO (ORCPT ); Wed, 1 Jun 2022 12:00:14 -0400 Received: from desiato.infradead.org (desiato.infradead.org [IPv6:2001:8b0:10b:1:d65d:64ff:fe57:4e05]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6DAB05DBEE; Wed, 1 Jun 2022 09:00:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=desiato.20200630; h=Content-Transfer-Encoding:Content-Type :In-Reply-To:From:References:Cc:To:Subject:MIME-Version:Date:Message-ID: Sender:Reply-To:Content-ID:Content-Description; bh=Y4MMjPUMJE17uRA1W8JeqNIa3gV1RDtW27U/YpItROE=; b=PNPjea3Bdl437M1+0zPKZ4cwLN hFYNzny9457JNo5FUnAC5pAYinngm5Tzi532WmplRYl6mclmGlkBTPQV3EWbzjL1lJsdCgFHoFuKE xkLOTIBC7a3cNimiGIlT1XQgleDQ8LF8XeG1gAtwaqa4Iib1MdVEEyvODkxXbwqgTlo6BYnm50u2f T4VZjAUy88+ZiooYd85oj0NRQS8ZrJWdoH3QHSQWCpMEohMg0rVlF13Rh0cfgNc+F58qRHyEGWpcy jNiQZA2jP0hH7K9WKcTKhXLA7jvLD8Jvrqc783shML119GeiVR3I97cMu2AHW7pekIpxw5XCaxa82 yN+8YoxA==; Received: from [2601:1c0:6280:3f0::aa0b] by desiato.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1nwQlH-003pGW-Rj; Wed, 01 Jun 2022 15:59:57 +0000 Message-ID: <86c1aaa4-df2e-d541-e24e-2d1cc9537500@infradead.org> Date: Wed, 1 Jun 2022 08:59:51 -0700 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.1 Subject: Re: [PATCH] RISCV: kexec: Fix build error without CONFIG_MODULES Content-Language: en-US To: Li Zhengyu , palmer@rivosinc.com Cc: paul.walmsley@sifive.com, aou@eecs.berkeley.edu, liaochang1@huawei.com, linux-riscv@lists.infradead.org, linux-kernel@vger.kernel.org, ebiederm@xmission.com, kexec@lists.infradead.org, linux-next@vger.kernel.org References: <20220601063924.13037-1-lizhengyu3@huawei.com> From: Randy Dunlap In-Reply-To: <20220601063924.13037-1-lizhengyu3@huawei.com> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Spam-Status: No, score=-3.2 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,NICE_REPLY_A,RDNS_NONE,SPF_HELO_NONE, T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 5/31/22 23:39, Li Zhengyu wrote: > When CONFIG_MODULES is not set/enabled: > > ../arch/riscv/kernel/elf_kexec.c:353:9: error: unknown type name 'Elf_Rela'; did you mean 'Elf64_Rela'? > 353 | Elf_Rela *relas; > | ^~~~~~~~ > | Elf64_Rela > > Replace Elf_Rela by Elf64_Rela to avoid relying on CONFIG_MODULES. > > Signed-off-by: Li Zhengyu Reported-by: Randy Dunlap Tested-by: Randy Dunlap Acked-by: Randy Dunlap thanks. > --- > arch/riscv/kernel/elf_kexec.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/arch/riscv/kernel/elf_kexec.c b/arch/riscv/kernel/elf_kexec.c > index 9cb85095fd45..0cb94992c15b 100644 > --- a/arch/riscv/kernel/elf_kexec.c > +++ b/arch/riscv/kernel/elf_kexec.c > @@ -349,7 +349,7 @@ int arch_kexec_apply_relocations_add(struct purgatory_info *pi, > { > const char *strtab, *name, *shstrtab; > const Elf_Shdr *sechdrs; > - Elf_Rela *relas; > + Elf64_Rela *relas; > int i, r_type; > > /* String & section header string table */ -- ~Randy