diff options
author | Thomas Schwinge <thomas@schwinge.name> | 2011-09-07 18:40:56 +0200 |
---|---|---|
committer | Thomas Schwinge <thomas@schwinge.name> | 2011-09-07 18:40:56 +0200 |
commit | 494cf4879f4ad468ba7c5d02e756db20df8822c2 (patch) | |
tree | 495ac5b094691030654c2bb2259c9fe0f101cc7f /pthread/pt-yield.c | |
parent | c28241162c00127bb5c0d03bbbbfc835a15e8f68 (diff) | |
parent | c2a1b325b7b2ce0d3d16bd1e9430e1d7eddce71e (diff) |
Merge commit 'refs/top-bases/t/fix_inline' into t/fix_inline
Diffstat (limited to 'pthread/pt-yield.c')
-rw-r--r-- | pthread/pt-yield.c | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/pthread/pt-yield.c b/pthread/pt-yield.c new file mode 100644 index 0000000..27848bb --- /dev/null +++ b/pthread/pt-yield.c @@ -0,0 +1,26 @@ +/* Yield the processor to another thread or process. + Copyright (C) 2010 Free Software Foundation, Inc. + This file is part of the GNU C Library. + + The GNU C Library is free software; you can redistribute it and/or + modify it under the terms of the GNU Library General Public License as + published by the Free Software Foundation; either version 2 of the + License, or (at your option) any later version. + + The GNU C Library is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + Library General Public License for more details. + + You should have received a copy of the GNU Library General Public + License along with the GNU C Library; see the file COPYING.LIB. If not, + write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, + Boston, MA 02111-1307, USA. */ + +#include <pthread.h> +#include <sched.h> + +int pthread_yield(void) +{ + return sched_yield (); +} |