# Re: \[PATCH v2\] Makefile: fix GDB warning with CONFIG\_RELR

- From: Will Deacon \<will@kernel.org\>
- Date: 2021-05-26 17:09:13 
- List: linux-arm-kernel
- Page: https://ratatoskr.run/linux-arm-kernel/2021/05/1393023
- Thread: https://ratatoskr.run/linux-arm-kernel/2021/05/1388236/t.md

```text
On Fri, May 21, 2021 at 06:26:24PM -0700, Nick Desaulniers wrote:
> GDB produces the following warning when debugging kernels built with
> CONFIG_RELR:
> 
> BFD: /android0/linux-next/vmlinux: unknown type [0x13] section `.relr.dyn'
> 
> when loading a kernel built with CONFIG_RELR into GDB. It can also
> prevent debugging symbols using such relocations.
> 
> Peter sugguests:
>   [That flag] means that lld will use dynamic tags and section type
>   numbers in the OS-specific range rather than the generic range. The
>   kernel itself doesn't care about these numbers; it determines the
>   location of the RELR section using symbols defined by a linker script.
> 
> Link: https://github.com/ClangBuiltLinux/linux/issues/1057
> Suggested-by: Peter Collingbourne <redacted>
> Reviewed-by: Nathan Chancellor <nathan@kernel.org>
> Signed-off-by: Nick Desaulniers <ndesaulniers@google.com>
> ---
> Changes V1 -> V2:
> * rebase
> * pick up Nathan's reviewed by tag.
> 
>  Makefile                      | 2 +-
>  scripts/tools-support-relr.sh | 3 ++-
>  2 files changed, 3 insertions(+), 2 deletions(-)

Does lld support RELR relocations for any architectures other than arm64? If
so, is the "--use-android-relr-tags" option supported on all of those as
well?

Will

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
```
