diff options
author | Ian Lepore <ian@FreeBSD.org> | 2015-08-07 21:14:19 +0000 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2017-10-12 07:04:10 +0200 |
commit | ec349b58363a5936af9022c2b4847db633a45145 (patch) | |
tree | 2e79fd17c6e5a3c3d9d2469f32197c5f69c935f6 /cpukit/score/src | |
parent | timecounter: Merge FreeBSD change r285286 (diff) | |
download | rtems-ec349b58363a5936af9022c2b4847db633a45145.tar.bz2 |
timecounter: Merge FreeBSD change r286423
RFC 2783 requires a status of ETIMEDOUT, not EWOULDBLOCK, on a timeout.
Update #3175.
Diffstat (limited to 'cpukit/score/src')
-rw-r--r-- | cpukit/score/src/kern_tc.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/cpukit/score/src/kern_tc.c b/cpukit/score/src/kern_tc.c index 30880e89bd..a789107528 100644 --- a/cpukit/score/src/kern_tc.c +++ b/cpukit/score/src/kern_tc.c @@ -1740,8 +1740,12 @@ pps_fetch(struct pps_fetch_args *fapi, struct pps_state *pps) } else { err = tsleep(pps, PCATCH, "ppsfch", timo); } - if (err == EWOULDBLOCK && fapi->timeout.tv_sec == -1) { - continue; + if (err == EWOULDBLOCK) { + if (fapi->timeout.tv_sec == -1) { + continue; + } else { + return (ETIMEDOUT); + } } else if (err != 0) { return (err); } |