diff options
| author | Jason Evans <jasone@FreeBSD.org> | 1999-07-11 05:56:37 +0000 |
|---|---|---|
| committer | Jason Evans <jasone@FreeBSD.org> | 1999-07-11 05:56:37 +0000 |
| commit | 34582929f1839d86c2a9221901b2f44902683760 (patch) | |
| tree | d9a14829f5e57fa898f946bfa03c66a1043dc634 /lib/libpthread/thread/thr_init.c | |
| parent | 6f0b5cda2f7d345296f75448fc9b8383500409e9 (diff) | |
Notes
Diffstat (limited to 'lib/libpthread/thread/thr_init.c')
| -rw-r--r-- | lib/libpthread/thread/thr_init.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/lib/libpthread/thread/thr_init.c b/lib/libpthread/thread/thr_init.c index a5b7a828cfa4..f5e2c456d366 100644 --- a/lib/libpthread/thread/thr_init.c +++ b/lib/libpthread/thread/thr_init.c @@ -29,7 +29,7 @@ * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * - * $Id: uthread_init.c,v 1.13 1999/07/05 00:35:19 jasone Exp $ + * $Id: uthread_init.c,v 1.14 1999/07/06 00:25:38 jasone Exp $ */ /* Allocate space for global thread variables here: */ @@ -180,15 +180,17 @@ _thread_init(void) /* Initialize the scheduling switch hook routine: */ _sched_switch_hook = NULL; -#ifdef __i386__ /* Initialize the thread stack cache: */ SLIST_INIT(&_stackq); /* Create the red zone for the main stack. */ - if (MAP_FAILED == mmap((void *) PTHREAD_STACK_TOP - PTHREAD_STACK_INITIAL, PTHREAD_STACK_GUARD, 0, MAP_ANON, -1, 0)) { + if (mmap((void *) PTHREAD_STACK_TOP + - PTHREAD_STACK_INITIAL, + PTHREAD_STACK_GUARD, 0, MAP_ANON, + -1, 0) == MAP_FAILED) { PANIC("Cannot allocate red zone for initial thread"); } -#endif + /* * Write a magic value to the thread structure * to help identify valid ones: |
