patch-2.3.40 linux/arch/arm/lib/strrchr.S

Next file: linux/arch/arm/lib/system.c
Previous file: linux/arch/arm/lib/string.S
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.3.39/linux/arch/arm/lib/strrchr.S linux/arch/arm/lib/strrchr.S
@@ -0,0 +1,25 @@
+/*
+ * linux/arch/arm/lib/strrchr.S
+ *
+ * Copyright (C) 1995-1999 Russell King
+ *
+ * ASM optimised string functions
+ *
+ */
+#include <linux/linkage.h>
+#include <asm/assembler.h>
+#include "constants.h"
+
+		.text
+ENTRY(strrchr)
+		stmfd	sp!, {lr}
+		mov	r3, #0
+1:		ldrb	r2, [r0], #1
+		teq	r2, r1
+		moveq	r3, r0
+		teq	r2, #0
+		bne	1b
+		mov	r0, r3
+		LOADREGS(fd, sp!, {pc})
+
+

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)