public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: SeongJae Park <sj@kernel.org>
To: Masahiro Yamada <masahiroy@kernel.org>
Cc: Richard Weinberger <richard@nod.at>,
	Anton Ivanov <anton.ivanov@cambridgegreys.com>,
	Johannes Berg <johannes@sipsolutions.net>,
	linux-um@lists.infradead.org, linux-kernel@vger.kernel.org,
	SeongJae Park <sj@kernel.org>,
	Palmer Dabbelt <palmer@rivosinc.com>
Subject: Re: [PATCH] UML: define RUNTIME_DISCARD_EXIT
Date: Tue,  7 Feb 2023 22:33:00 +0000	[thread overview]
Message-ID: <20230207223300.74593-1-sj@kernel.org> (raw)
In-Reply-To: <20230207164156.537378-1-masahiroy@kernel.org>

Hi Masahiro,

On Wed, 8 Feb 2023 01:41:56 +0900 Masahiro Yamada <masahiroy@kernel.org> wrote:

> With CONFIG_VIRTIO_UML=y, GNU ld < 2.36 fails to link UML vmlinux
> (w/wo CONFIG_LD_SCRIPT_STATIC).
> 
>   `.exit.text' referenced in section `.uml.exitcall.exit' of arch/um/drivers/virtio_uml.o: defined in discarded section `.exit.text' of arch/um/drivers/virtio_uml.o
>   collect2: error: ld returned 1 exit status
> 
> This fix is similar to the following commits:
> 
> - 4b9880dbf3bd ("powerpc/vmlinux.lds: Define RUNTIME_DISCARD_EXIT")
> - a494398bde27 ("s390: define RUNTIME_DISCARD_EXIT to fix link error
>   with GNU ld < 2.36")
> - c1c551bebf92 ("sh: define RUNTIME_DISCARD_EXIT")
> 
> Fixes: 99cb0d917ffa ("arch: fix broken BuildID for arm64 and riscv")
> Reported-by: SeongJae Park <sj@kernel.org>
> Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>

Tested-by: SeongJae Park <sj@kernel.org>


Thanks.
SJ

> ---
> 
>  arch/um/kernel/vmlinux.lds.S | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/arch/um/kernel/vmlinux.lds.S b/arch/um/kernel/vmlinux.lds.S
> index 16e49bfa2b42..53d719c04ba9 100644
> --- a/arch/um/kernel/vmlinux.lds.S
> +++ b/arch/um/kernel/vmlinux.lds.S
> @@ -1,4 +1,4 @@
> -
> +#define RUNTIME_DISCARD_EXIT
>  KERNEL_STACK_SIZE = 4096 * (1 << CONFIG_KERNEL_STACK_ORDER);
>  
>  #ifdef CONFIG_LD_SCRIPT_STATIC
> -- 
> 2.34.1
> 

      reply	other threads:[~2023-02-07 22:33 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-02-07 16:41 [PATCH] UML: define RUNTIME_DISCARD_EXIT Masahiro Yamada
2023-02-07 22:33 ` SeongJae Park [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20230207223300.74593-1-sj@kernel.org \
    --to=sj@kernel.org \
    --cc=anton.ivanov@cambridgegreys.com \
    --cc=johannes@sipsolutions.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-um@lists.infradead.org \
    --cc=masahiroy@kernel.org \
    --cc=palmer@rivosinc.com \
    --cc=richard@nod.at \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox