From owner-freebsd-questions@FreeBSD.ORG Sat Sep 30 14:06:48 2006 Return-Path: X-Original-To: freebsd-questions@FreeBSD.org Delivered-To: freebsd-questions@FreeBSD.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id D201D16A47C for ; Sat, 30 Sep 2006 14:06:48 +0000 (UTC) (envelope-from cswiger@mac.com) Received: from pi.codefab.com (pi.codefab.com [199.103.21.227]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4B8BD43D5F for ; Sat, 30 Sep 2006 14:06:42 +0000 (GMT) (envelope-from cswiger@mac.com) Received: from localhost (localhost [127.0.0.1]) by pi.codefab.com (Postfix) with ESMTP id B39635F64; Sat, 30 Sep 2006 10:06:41 -0400 (EDT) X-Virus-Scanned: amavisd-new at codefab.com Received: from pi.codefab.com ([127.0.0.1]) by localhost (pi.codefab.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id J2H8MXnZ07gL; Sat, 30 Sep 2006 10:06:40 -0400 (EDT) Received: from [192.168.1.251] (pool-68-161-96-195.ny325.east.verizon.net [68.161.96.195]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by pi.codefab.com (Postfix) with ESMTP id B05B75D19; Sat, 30 Sep 2006 10:06:40 -0400 (EDT) Message-ID: <451E79EA.4090805@mac.com> Date: Sat, 30 Sep 2006 10:06:34 -0400 From: Chuck Swiger User-Agent: Thunderbird 1.5.0.7 (Windows/20060909) MIME-Version: 1.0 To: vpaces@chello.sk References: <20060930095650.NMHP18728.viefep17-int.chello.at@localhost> In-Reply-To: <20060930095650.NMHP18728.viefep17-int.chello.at@localhost> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: freebsd-questions@FreeBSD.org Subject: Re: Question:socket sources X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 30 Sep 2006 14:06:48 -0000 vpaces@chello.sk wrote: [ ... ] > For example: > int socket(int domain, int type, int protocol); > int bind(int s, const struct sockaddr *addr, socklen_t addrlen); > > Browsing through your WWW CVS repository I'm just finding sources for MAN pages in directory / src / lib / libc / sys: > access.2, connect.2 and so on. > But where are the C sources of these calls? Or are the sources of these system calls not available? C functions from section 2 of the manpages are "system calls", which means that a stub function is generated in libc via makesyscalls.sh, but most of the work in done in the kernel: http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/kern/uipc_syscalls.c?rev=1.221.2.4 http://www.freebsd.org/cgi/cvsweb.cgi/src/sys/kern/uipc_socket.c?rev=1.283 -- -Chuck