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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 969A4C433EF for ; Tue, 31 May 2022 05:59:03 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S244148AbiEaF7A (ORCPT ); Tue, 31 May 2022 01:59:00 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:49662 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S238225AbiEaF6z (ORCPT ); Tue, 31 May 2022 01:58:55 -0400 Received: from metis.ext.pengutronix.de (metis.ext.pengutronix.de [IPv6:2001:67c:670:201:290:27ff:fe1d:cc33]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 33FC36972E for ; Mon, 30 May 2022 22:58:53 -0700 (PDT) Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.ext.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nvutV-0000d1-Mm; Tue, 31 May 2022 07:58:17 +0200 Received: from [2a0a:edc0:0:900:1d::77] (helo=ptz.office.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtp (Exim 4.94.2) (envelope-from ) id 1nvutO-005aW1-EE; Tue, 31 May 2022 07:58:09 +0200 Received: from ukl by ptz.office.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1nvutL-00DF4g-Ha; Tue, 31 May 2022 07:58:07 +0200 Date: Tue, 31 May 2022 07:58:03 +0200 From: Uwe =?utf-8?Q?Kleine-K=C3=B6nig?= To: Palmer Dabbelt Cc: wangkefeng.wang@huawei.com, guoren@linux.alibaba.com, sunnanyong@huawei.com, jszhang@kernel.org, mick@ics.forth.gr, linux-riscv@lists.infradead.org, Stephen Rothwell , alex@ghiti.fr, christophe.leroy@csgroup.eu, naveen.n.rao@linux.vnet.ibm.com, lizhengyu3@huawei.com, aou@eecs.berkeley.edu, liaochang1@huawei.com, Paul Walmsley , Bjorn Topel , kexec@lists.infradead.org, linux-kernel@vger.kernel.org, penberg@kernel.org, ebiederm@xmission.com, kernel@pengutronix.de, akpm@linux-foundation.org, linuxppc-dev@lists.ozlabs.org Subject: Re: [PATCH] RISC-V: Prepare dropping week attribute from arch_kexec_apply_relocations[_add] Message-ID: <20220531055803.prq5fj6lajzqiiiu@pengutronix.de> References: <20220530194133.udwdjsb2l33hsiil@pengutronix.de> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="yslkboxts2p5evg7" Content-Disposition: inline In-Reply-To: X-SA-Exim-Connect-IP: 2a0a:edc0:0:c01:1d::a2 X-SA-Exim-Mail-From: ukl@pengutronix.de X-SA-Exim-Scanned: No (on metis.ext.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: linux-kernel@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --yslkboxts2p5evg7 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Mon, May 30, 2022 at 04:11:27PM -0700, Palmer Dabbelt wrote: > On Mon, 30 May 2022 12:41:33 PDT (-0700), u.kleine-koenig@pengutronix.de = wrote: > > Hello, > >=20 > > On Mon, May 30, 2022 at 11:58:16AM -0700, Palmer Dabbelt wrote: > > > On Mon, 30 May 2022 00:42:02 PDT (-0700), u.kleine-koenig@pengutronix= =2Ede wrote: > > > > Without this change arch/riscv/kernel/elf_kexec.c fails to compile = once > > > > commit 233c1e6c319c ("kexec_file: drop weak attribute from > > > > arch_kexec_apply_relocations[_add]") is also contained in the tree. > > > > This currently happens in next-20220527. > > > > > Prepare the RISC-V similar to the s390 adaption done in > > > 233c1e6c319c. > > > > This is safe to do on top of the riscv change even without the chan= ge to > > > > arch_kexec_apply_relocations. > > > > > Fixes: 838b3e28488f ("RISC-V: Load purgatory in kexec_file") > > > > Looks-good-to: liaochang (A) > > > > Signed-off-by: Uwe Kleine-K=F6nig > > > > --- > > > > > On Mon, May 30, 2022 at 09:43:26AM +0800, liaochang (A) wrote: > > > > > > I can confirm that doing > > > > > > > diff --git a/arch/riscv/include/asm/kexec.h > > > > > b/arch/riscv/include/asm/kexec.h > > > > > > index 206217b23301..eee260e8ab30 100644 > > > > > > --- a/arch/riscv/include/asm/kexec.h > > > > > > +++ b/arch/riscv/include/asm/kexec.h > > > > > > @@ -55,6 +55,13 @@ extern riscv_kexec_method riscv_kexec_norelo= cate; > > > > > > > #ifdef CONFIG_KEXEC_FILE > > > > > > extern const struct kexec_file_ops elf_kexec_ops; > > > > > > + > > > > > > +struct purgatory_info; > > > > > > +int arch_kexec_apply_relocations_add(struct purgatory_info *pi, > > > > > > + Elf_Shdr *section, > > > > > > + const Elf_Shdr *relsec, > > > > > > + const Elf_Shdr *symtab); > > > > > > +#define arch_kexec_apply_relocations_add arch_kexec_apply_relo= cations_add > > > > > > #endif > > > > > > > #endif > > > > > > > LGTM, you could send a fixup patch to riscv, thanks. > > > > > > > > > on top of 838b3e28488f results in a compilable tree. And > > > when > > > > > merging > > > > > > 233c1e6c319c into this, it is still building. > > > > > > > I'm not enough into kexec (and riscv) to judge if this is > > > > > sensible, or > > > > > > create a useful commit log but the obvious way forward is to ap= ply the > > > > > > above patch to the riscv tree before it hits Linus' tree. > > > > > Ok, here comes a patch with a generic commit log. > > > > > @riscv people: If you prefer, squash it into 838b3e28488f. > > >=20 > > > Sorry, just saw this after I sent my version of the fix. They're the= same, > > > but do you mind sending a full-on patch so I can merge it? > >=20 > > Sorry, I don't understand your request. I found > > https://lore.kernel.org/linux-riscv/20220530180408.16239-1-palmer@rivos= inc.com/ > >=20 > > but I don't know what a full-on patch is and what stops you merging my > > patch. > >=20 > > Is it that it's in reply to a patch series and b4 fails to fetch the > > right patch and you ask to send it in a new thread? >=20 > Ya, with the reply bits in there my mail merge (which unfortunately isn't > b4, I haven't gotten around to converting yet) got tripped up. It's kind= of > easy to for me to screw something up trying to pull bits out of replies a= nd > such, but I think this one was pretty simple (looks like maybe some PGP or > MIME thing was the issue). >=20 > I just put > on my staging branch, it looks OK to me but LMK if there's a problem. there is indeed a problem, but caused by me: If you are ready to rewrite it, please do s/week/weak/ in the subject line. Otherwise looks good to me. Best regards and thanks, Uwe --=20 Pengutronix e.K. | Uwe Kleine-K=F6nig | Industrial Linux Solutions | https://www.pengutronix.de/ | --yslkboxts2p5evg7 Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEfnIqFpAYrP8+dKQLwfwUeK3K7AkFAmKVrmgACgkQwfwUeK3K 7Almtgf/cMTh8gUXGvy16o7kg3cs7a7GFj0o1WI4oidOclFTc/fWRvKtowa8AzI/ 6zEA161snauy6f6RwV4kPudFteGkKV7AuNL93UYf5cLx1yEel9XMhht0KJU+HEPw 2eaZboB92XdTrvCfnxSanTst4F33A+LK6bD6Yz+B1QZF5gCHB7GqAoTNYTK8EguB oHEUMlx6qCWHeC1qBGj8ldLK4kvZqL8eC3yKHezMZVa94PJJsE6KbAKBQGB3D1KN GfSkmkRa3fENCxe+2/WOrhLU6qhEFJqwPfEwz7V5xmQgmzlml6xdM5oxccN6E3EC o3yYJzG+N0fIbD3b1gHR61LRNFn5rg== =23PP -----END PGP SIGNATURE----- --yslkboxts2p5evg7--