Date: Thu, 25 Apr 2002 17:10:04 +0900 From: Seigo Tanimura <tanimura@r.dl.itc.u-tokyo.ac.jp> To: Bosko Milekic <bmilekic@unixdaemons.com> Cc: Seigo Tanimura <tanimura@r.dl.itc.u-tokyo.ac.jp>, current@FreeBSD.ORG, smp@FreeBSD.ORG Subject: Re: Locking down a socket, milestone 1 Message-ID: <200204250810.g3P8A50o010159@rina.r.dl.itc.u-tokyo.ac.jp> In-Reply-To: <20020424085741.A62067@unixdaemons.com> References: <200204241110.g3OB8u8t006194@bunko>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 24 Apr 2002 08:57:41 -0400, Bosko Milekic <bmilekic@unixdaemons.com> said: bmilekic> I've literally just had time to glance at this so far, but can you, if bmilekic> you don't mind, please just briefly explain what BSD/OS does with bmilekic> sockbuf locking (do they use the same lock, or...?) In BSD/OS, each of the sockbufs in a socket has a mutex. It protects the data in the sockbuf. In addition, the mutex of the receive sockbuf also protects the whole data of the socket as well. BSD/OS seems to have no global locks to protect the relation between sockets. One thing I am not sure is the lock requirement upon waking up a process tsleeping for socket operation. In BSD/OS, some parts wake up processes with a socket locked, while the other parts not. I am going to make all of the functions calling sowakeup() to lock a socket first. -- Seigo Tanimura <tanimura@r.dl.itc.u-tokyo.ac.jp> <tanimura@FreeBSD.org> To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200204250810.g3P8A50o010159>