summaryrefslogtreecommitdiff
path: root/sys/arch/sh
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2009-02-14 18:38:20 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2009-02-14 18:38:20 +0000
commit57b7648a3a2457fea5679f8a1c22419ca4f53bff (patch)
tree44334edd8298109aea4991d1efa21a0c0bbe4c20 /sys/arch/sh
parent429780f3a931abd6d29e80616a6abb156e879e9d (diff)
Fix logic error in copyinstr() when deciding whether to return EFAULT
or ENAMETOOLONG.
Diffstat (limited to 'sys/arch/sh')
-rw-r--r--sys/arch/sh/sh/locore_subr.S10
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/arch/sh/sh/locore_subr.S b/sys/arch/sh/sh/locore_subr.S
index 5c5e4ea5b70..aa073de2fd7 100644
--- a/sys/arch/sh/sh/locore_subr.S
+++ b/sys/arch/sh/sh/locore_subr.S
@@ -1,4 +1,4 @@
-/* $OpenBSD: locore_subr.S,v 1.8 2008/06/26 05:42:13 ray Exp $ */
+/* $OpenBSD: locore_subr.S,v 1.9 2009/02/14 18:38:19 miod Exp $ */
/* $NetBSD: locore_subr.S,v 1.28 2006/01/23 22:52:09 uwe Exp $ */
/*
@@ -560,7 +560,7 @@ ENTRY(copyout)
cmp/hi r1, r2 /* bomb if uaddr isn't in user space */
bt 2f
- mov.l .L_copyout_curpcb, r1 /* set fault hander */
+ mov.l .L_copyout_curpcb, r1 /* set fault handler */
mov.l @r1, r2
mov.l .L_copyout_onfault, r1
mov.l r1, @(PCB_ONFAULT,r2)
@@ -616,7 +616,7 @@ ENTRY(copyin)
cmp/hi r1, r2 /* bomb if uaddr isn't in user space */
bt 2f
- mov.l .L_copyin_curpcb, r1 /* set fault hander */
+ mov.l .L_copyin_curpcb, r1 /* set fault handler */
mov.l @r1, r2
mov.l .L_copyin_onfault, r1
mov.l r1, @(PCB_ONFAULT,r2)
@@ -626,7 +626,7 @@ ENTRY(copyin)
mov #0, r0
1:
- mov.l .L_copyin_curpcb, r1 /* clear fault hander */
+ mov.l .L_copyin_curpcb, r1 /* clear fault handler */
mov.l @r1, r2
mov #0, r1
mov.l r1, @(PCB_ONFAULT,r2)
@@ -770,7 +770,7 @@ ENTRY(copyinstr)
cmp/eq #-1, r0
bf 1b
mov.l .L_copyinstr_VM_MAXUSER_ADDRESS, r1
- cmp/hs r1, r5
+ cmp/hs r1, r4
bt 3f
mov #ENAMETOOLONG, r3