* [PATCH] SH: NPTL: Fixup sem_timedwait
@ 2004-10-29 9:51 Kaz Kojima
2004-10-29 21:11 ` Ulrich Drepper
0 siblings, 1 reply; 2+ messages in thread
From: Kaz Kojima @ 2004-10-29 9:51 UTC (permalink / raw)
To: libc-hacker
Hi,
The appended patch is to set errno correctly when sem_timedwait
is timeouted. It also gets rid of an assembler warning for a too
far offset for conditinal-branch.
Regards,
kaz
--
2004-10-29 Kaz Kojima <kkojima@rr.iij4u.or.jp>
* sysdeps/unix/sysv/linux/sh/sem_timedwait.S (sem_timedwait):
Set ETIMEDOUT to errno when time is up. Tweak to avoid
assembler warning.
--- ORIG/libc/nptl/sysdeps/unix/sysv/linux/sh/sem_timedwait.S Mon Jul 5 11:14:05 2004
+++ LOCAL/libc/nptl/sysdeps/unix/sysv/linux/sh/sem_timedwait.S Tue Oct 26 08:01:38 2004
@@ -42,8 +42,10 @@ sem_timedwait:
mov #0xf9, r1
and r1, r0
cmp/eq #8, r0
- bt 10f
-
+ bf 0f
+ bra 10f
+ stc gbr, r0
+0:
mov.l @r4, r0
2:
tst r0, r0
@@ -115,7 +117,8 @@ sem_timedwait:
add #-1, r2
5:
cmp/pz r2
- bf 6f /* Time is already up. */
+ bf/s 6f /* Time is already up. */
+ mov #ETIMEDOUT, r0
/* Store relative timeout. */
mov.l r2, @r15
@@ -196,7 +199,6 @@ sem_timedwait:
10:
/* Canceled. */
- stc gbr, r0
mov.w .Lresult, r1
mov #-1, r2
mov.l r2, @(r0,r1)
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] SH: NPTL: Fixup sem_timedwait
2004-10-29 9:51 [PATCH] SH: NPTL: Fixup sem_timedwait Kaz Kojima
@ 2004-10-29 21:11 ` Ulrich Drepper
0 siblings, 0 replies; 2+ messages in thread
From: Ulrich Drepper @ 2004-10-29 21:11 UTC (permalink / raw)
To: Kaz Kojima; +Cc: libc-hacker
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Applied.
- --
⧠Ulrich Drepper ⧠Red Hat, Inc. ⧠444 Castro St ⧠Mountain View, CA â
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.6 (GNU/Linux)
iD8DBQFBgrHj2ijCOnn/RHQRAi4DAJ9bvhNk8NkY3Gs2i8d/sNvx3zLirACfZlDG
h1x0nBr25Ekb7/iCoZ1DyQk=
=O0wq
-----END PGP SIGNATURE-----
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2004-10-29 21:11 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-10-29 9:51 [PATCH] SH: NPTL: Fixup sem_timedwait Kaz Kojima
2004-10-29 21:11 ` Ulrich Drepper
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).