diff mbox

aarch64: Use PTR_REG macro to fix ILP32 bug and make code consistent

Message ID 1503422868.28672.28.camel@cavium.com
State New, archived
Headers show

Commit Message

Steve Ellcey Aug. 22, 2017, 5:27 p.m. UTC
This patch is a one line change to use the PTR_REG macro in a cmp instruction
in dl-tlsdesc.S.  It only causes a problem in ILP32 mode but I would like
to submit it and check it in now so that the source code is consistent in
its use of PTR_REG.  Tested in ILP32 and LP64 modes on aarch64.

I think this counts as an 'obvious' fix, so I will check it in later today
if there are no objections.

Steve Ellcey

2017-08-22  Szabolcs Nagy  <szabolcs.nagy@arm.com>
            Steve Ellcey  <sellcey@caviumnetworks.com>

        * sysdeps/aarch64/dl-tlsdesc.S (_dl_tlsdesc_dynamic):
        Use PTR_REG macro in cmp instruction.
diff mbox


diff --git a/sysdeps/aarch64/dl-tlsdesc.S b/sysdeps/aarch64/dl-tlsdesc.S
index a70cfd5..3b2da62 100644
--- a/sysdeps/aarch64/dl-tlsdesc.S
+++ b/sysdeps/aarch64/dl-tlsdesc.S
@@ -208,7 +208,7 @@  _dl_tlsdesc_dynamic:
 	ldr	PTR_REG (2), [x1,#TLSDESC_MODID]
 	add	PTR_REG (0), PTR_REG (0), PTR_REG (2), lsl #(PTR_LOG_SIZE + 1)
 	ldr	PTR_REG (0), [x0] /* Load val member of DTV entry.  */
 	b.eq	2f
 	ldr	PTR_REG (1), [x1,#TLSDESC_MODOFF]
 	add	PTR_REG (0), PTR_REG (0), PTR_REG (1)