socket on AF_UNIX

Forum thread started by admin on Thu, 2005-09-29 19:58

In order to have sockets on UNIX domain, do you think this could help ?

http://lxr.linux.no/source/net/unix/sock.c?v=1.0.9#L669

(i tried to reach the mailing list, but the sign-up link doesn't work)

Comments

Re: socket on AF_UNIX

Quote:
In order to have sockets on UNIX domain, do you think this could help ?
http://lxr.linux.no/source/net/unix/sock.c?v=1.0.9#L669

Well, I'm not fluent in Linux UNIX domain sockets implementation, but basicly their approch seems to have for each AF_UNIX socket a buffer that they shared all AF_UNIX domain sockets. When a socket write, the data are just append/written to the AF_UNIX socket peer's buffer.

That's a way to do it, indeed.
I just find it "bloaty".

xBSD implementation use the VFS inode own buffers to do it, though, which sounds even more complex and bloated to me.

I did search a little but failed to find a quick & easy implementation using for example named pipes. We do have a working pipefs in Haiku, I can't see why we should reimplement buffering but, well, dunno.

Quote:
(i tried to reach the mailing list, but the sign-up link doesn't work)

Try subscribing from this page then:
http://www.freelists.org/list/openbeosnetteam

I'll fix the broken link from team page, thanks for reporting...

AF_UNIX and mkfifo

Why not creating a named pipe by mkfifo for a socket on a file ?
It seems it could be an interesting trade-off to test some things, and maybe just keep this kind of implementation.

If not, i would be interesting on your point of view :)