Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 05 Mar 2005 13:54:41 +0300
From:      Vsevolod Stakhov <vsevolod@highsecure.ru>
To:        FreeBSD-gnats-submit@FreeBSD.org
Subject:   docs/78440: POSIX semaphores don't work by default in 5.3-STABLE
Message-ID:  <E1D7Wvh-000BOn-83@spray.anyhost.ru>
Resent-Message-ID: <200503051100.j25B0aSJ014911@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help

>Number:         78440
>Category:       docs
>Synopsis:       POSIX semaphores don't work by default in 5.3-STABLE
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-doc
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          change-request
>Submitter-Id:   current-users
>Arrival-Date:   Sat Mar 05 11:00:36 GMT 2005
>Closed-Date:
>Last-Modified:
>Originator:     Vsevolod Stakhov
>Release:        FreeBSD 5.3-STABLE i386
>Organization:
>Environment:
System: FreeBSD nemezida.highsecure.ru 5.3-STABLE FreeBSD 5.3-STABLE #2: Fri Jan 28 02:15:40 MSK 2005 root@nemezida.highsecure.ru:/mnt/data/usr/obj/mnt/data/usr/src/sys/NK i386

>Description:
On 5.3-STABLE POSIX semaphores in kernel are not turned on by default as it
is in 5.2.1. But there is nowhere mention about it. Also there is no any
mention, that POSIX semaphores always work, when program is linked with
pthreads. I think, that kernel option P1003_1B_SEMAPHORES and threads
specific should be mentioned in sem_init (3).
>How-To-Repeat:
#include <semaphore.h>

int main()
{
	static sem_t sem;
	sem_init(&sem, 0, 1);

	return 0;
}

ksem_init(0xbfbfe788,0x1)            ERR#78 'Function not implemented'

And while linking with pthread all works fine.
>Fix:
Note about it in man pages.
>Release-Note:
>Audit-Trail:
>Unformatted:


Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?E1D7Wvh-000BOn-83>