diff options
author | Richard Henderson <rth@twiddle.net> | 2013-02-13 20:10:45 -0800 |
---|---|---|
committer | Richard Henderson <rth@twiddle.net> | 2013-03-06 07:46:38 -0800 |
commit | 5232b909bf31420497ec864e34f806a545017185 (patch) | |
tree | 83dda99ea71e22aab52f25e4be58d7d20bc9d848 /ports/sysdeps/unix/sysv/linux/arm/nptl/pt-vfork.S | |
parent | 3ae44082ab30918a6f5aa135620dda08e62593d5 (diff) | |
download | glibc-5232b909bf31420497ec864e34f806a545017185.tar.gz glibc-5232b909bf31420497ec864e34f806a545017185.tar.xz glibc-5232b909bf31420497ec864e34f806a545017185.zip |
arm: Introduce and use GET_TLS
Factor out the sequence needed to call kuser_get_tls, as we can't play subtract into pc games in thumb mode. Prepare for hard-tp, pulling the save of LR into the macro.
Diffstat (limited to 'ports/sysdeps/unix/sysv/linux/arm/nptl/pt-vfork.S')
-rw-r--r-- | ports/sysdeps/unix/sysv/linux/arm/nptl/pt-vfork.S | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/ports/sysdeps/unix/sysv/linux/arm/nptl/pt-vfork.S b/ports/sysdeps/unix/sysv/linux/arm/nptl/pt-vfork.S index f79bb66f2b..ca50457070 100644 --- a/ports/sysdeps/unix/sysv/linux/arm/nptl/pt-vfork.S +++ b/ports/sysdeps/unix/sysv/linux/arm/nptl/pt-vfork.S @@ -19,15 +19,7 @@ /* Save the PID value. */ #define SAVE_PID \ - str lr, [sp, #-4]!; /* Save LR. */ \ - cfi_adjust_cfa_offset (4); \ - cfi_rel_offset (lr, 0); \ - mov r0, #0xffff0fff; /* Point to the high page. */ \ - mov lr, pc; /* Save our return address. */ \ - sub pc, r0, #31; /* Jump to the TLS entry. */ \ - ldr lr, [sp], #4; /* Restore LR. */ \ - cfi_adjust_cfa_offset (-4); \ - cfi_restore (lr); \ + GET_TLS (r2); \ NEGOFF_ADJ_BASE2 (r2, r0, PID_OFFSET); /* Save the TLS addr in r2. */ \ ldr r3, NEGOFF_OFF1 (r2, PID_OFFSET); /* Load the saved PID. */ \ rsb r0, r3, #0; /* Negate it. */ \ |