Mark Wielaard bd144c
diff --git a/coregrind/m_redir.c b/coregrind/m_redir.c
Mark Wielaard bd144c
index b8cc022..d54cae7 100644
Mark Wielaard bd144c
--- a/coregrind/m_redir.c
Mark Wielaard bd144c
+++ b/coregrind/m_redir.c
Mark Wielaard bd144c
@@ -1485,6 +1485,17 @@ void VG_(redir_initialise) ( void )
Mark Wielaard bd144c
          (Addr)&VG_(arm_linux_REDIR_FOR_strcmp),
Mark Wielaard bd144c
          complain_about_stripped_glibc_ldso
Mark Wielaard bd144c
       );
Mark Wielaard bd144c
+      /* index */
Mark Wielaard bd144c
+      add_hardwired_spec(
Mark Wielaard bd144c
+         "ld-linux.so.3", "index",
Mark Wielaard bd144c
+         (Addr)&VG_(arm_linux_REDIR_FOR_index),
Mark Wielaard bd144c
+         complain_about_stripped_glibc_ldso
Mark Wielaard bd144c
+      );
Mark Wielaard bd144c
+      add_hardwired_spec(
Mark Wielaard bd144c
+         "ld-linux-armhf.so.3", "index",
Mark Wielaard bd144c
+         (Addr)&VG_(arm_linux_REDIR_FOR_index),
Mark Wielaard bd144c
+         complain_about_stripped_glibc_ldso
Mark Wielaard bd144c
+      );
Mark Wielaard bd144c
    }
Mark Wielaard bd144c
 
Mark Wielaard bd144c
 #  elif defined(VGP_arm64_linux)
Mark Wielaard bd144c
diff --git a/coregrind/m_trampoline.S b/coregrind/m_trampoline.S
Mark Wielaard bd144c
index a532071..0488b54 100644
Mark Wielaard bd144c
--- a/coregrind/m_trampoline.S
Mark Wielaard bd144c
+++ b/coregrind/m_trampoline.S
Mark Wielaard bd144c
@@ -625,26 +625,26 @@ VG_(arm_linux_REDIR_FOR_strlen):
Mark Wielaard bd144c
 	bx	lr
Mark Wielaard bd144c
 	UD2_4
Mark Wielaard bd144c
 
Mark Wielaard bd144c
-//.global VG_(arm_linux_REDIR_FOR_index)
Mark Wielaard bd144c
-//VG_(arm_linux_REDIR_FOR_index):
Mark Wielaard bd144c
-//	ldrb	r3, [r0, #0]	@ zero_extendqisi2
Mark Wielaard bd144c
-//	and	r1, r1, #255
Mark Wielaard bd144c
-//	cmp	r3, r1
Mark Wielaard bd144c
-//	@ lr needed for prologue
Mark Wielaard bd144c
-//	bne	.L9
Mark Wielaard bd144c
-//	bx	lr
Mark Wielaard bd144c
-//.L12:
Mark Wielaard bd144c
-//	ldrb	r3, [r0, #1]!	@ zero_extendqisi2
Mark Wielaard bd144c
-//	cmp	r3, r1
Mark Wielaard bd144c
-//	beq	.L11
Mark Wielaard bd144c
-//.L9:
Mark Wielaard bd144c
-//	cmp	r3, #0
Mark Wielaard bd144c
-//	bne	.L12
Mark Wielaard bd144c
-//	mov	r0, #0
Mark Wielaard bd144c
-//	bx	lr
Mark Wielaard bd144c
-//.L11:
Mark Wielaard bd144c
-//	bx	lr
Mark Wielaard bd144c
-//	UD2_4
Mark Wielaard bd144c
+.global VG_(arm_linux_REDIR_FOR_index)
Mark Wielaard bd144c
+VG_(arm_linux_REDIR_FOR_index):
Mark Wielaard bd144c
+	ldrb	r3, [r0, #0]	@ zero_extendqisi2
Mark Wielaard bd144c
+	and	r1, r1, #255
Mark Wielaard bd144c
+	cmp	r3, r1
Mark Wielaard bd144c
+	@ lr needed for prologue
Mark Wielaard bd144c
+	bne	.L9
Mark Wielaard bd144c
+	bx	lr
Mark Wielaard bd144c
+.L12:
Mark Wielaard bd144c
+	ldrb	r3, [r0, #1]!	@ zero_extendqisi2
Mark Wielaard bd144c
+	cmp	r3, r1
Mark Wielaard bd144c
+	beq	.L11
Mark Wielaard bd144c
+.L9:
Mark Wielaard bd144c
+	cmp	r3, #0
Mark Wielaard bd144c
+	bne	.L12
Mark Wielaard bd144c
+	mov	r0, #0
Mark Wielaard bd144c
+	bx	lr
Mark Wielaard bd144c
+.L11:
Mark Wielaard bd144c
+	bx	lr
Mark Wielaard bd144c
+	UD2_4
Mark Wielaard bd144c
 
Mark Wielaard bd144c
 .global VG_(arm_linux_REDIR_FOR_memcpy)
Mark Wielaard bd144c
 VG_(arm_linux_REDIR_FOR_memcpy):
Mark Wielaard bd144c
diff --git a/coregrind/pub_core_trampoline.h b/coregrind/pub_core_trampoline.h
Mark Wielaard bd144c
index 3a9bafe..e29427d 100644
Mark Wielaard bd144c
--- a/coregrind/pub_core_trampoline.h
Mark Wielaard bd144c
+++ b/coregrind/pub_core_trampoline.h
Mark Wielaard bd144c
@@ -100,7 +100,7 @@ extern Addr VG_(ppctoc_magic_redirect_return_stub);
Mark Wielaard bd144c
 extern Addr  VG_(arm_linux_SUBST_FOR_sigreturn);
Mark Wielaard bd144c
 extern Addr  VG_(arm_linux_SUBST_FOR_rt_sigreturn);
Mark Wielaard bd144c
 extern UInt  VG_(arm_linux_REDIR_FOR_strlen)( void* );
Mark Wielaard bd144c
-//extern void* VG_(arm_linux_REDIR_FOR_index) ( void*, Int );
Mark Wielaard bd144c
+extern void* VG_(arm_linux_REDIR_FOR_index) ( void*, Int );
Mark Wielaard bd144c
 extern void* VG_(arm_linux_REDIR_FOR_memcpy)( void*, void*, Int );
Mark Wielaard bd144c
 extern void* VG_(arm_linux_REDIR_FOR_strcmp)( void*, void* );
Mark Wielaard bd144c
 #endif