[yocto] [PATCH 1/1] Fix AARCH64_TLSDESC relocation conflict

Mark Hatle mark.hatle at windriver.com
Tue Nov 3 13:10:29 PST 2015


On 11/3/15 5:44 AM, Manjeet Pawar wrote:
> This patch needs to be applied to 'cross_prelink_aarch64' branch.
> It fixes tls1, tls2, tls4, tls5, tls6 test cases of prelink testsuite.
> tls3 gets failed but this test case fails without prelink as well on AARCH64
> 
> Signed-off-by: Vaneet Narang <v.narang at samsung.com>
> Signed-off-by: Manjeet Pawar <manjeet.p at samsung.com>
> ---
>  src/arch-aarch64.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
> 
> diff --git a/src/arch-aarch64.c b/src/arch-aarch64.c
> index e04dd6e..6499c68 100644
> --- a/src/arch-aarch64.c
> +++ b/src/arch-aarch64.c
> @@ -375,7 +375,7 @@ aarch64_prelink_conflict_rela (DSO *dso, struct prelink_info *info,
>        break;
>      case R_AARCH64_TLSDESC:
>  	  tls = conflict ? conflict->lookup.tls : info->curtls;
> -	  ret->r_addend =  rela->r_addend + tls->offset;
> +	  ret->r_addend = value + rela->r_addend + tls->offset;
>       break;
>      default:
>        error (0, 0, "%s: Unknown AARCH64 relocation type %d", dso->filename,
> 

I'm still getting segfaults here.

The way I am testing is building a Yocto Project (jethro) system
core-image-base, and adding to it:
"packagegroup-core-buildessential,libelf,elfutils-dev,binutils-staticdev,glibc-staticdev"

The copying a checked out version of the prelink-cross repository with the
prelink_cross_aarch64 branch checked out.

On the target:

autoreconf -if
./configure
make
make -C testsuite check

Most tests still fail, and all of the TLS tests result in a segfault.

(I do have the 'aarch64/dl-machine.h: Fix load-address for prelink support'
applied to my glibc.  Are there any other patches that may need to be applied?)

--Mark



More information about the yocto mailing list