Date: Mon, 29 Jan 2001 02:01:04 -0500 From: Garance A Drosihn <drosih@rpi.edu> To: Matt Dillon <dillon@earth.backplane.com>, Luigi Rizzo <rizzo@aciri.org> Cc: usebsd@free.fr (mouss), hackers@FreeBSD.ORG, wollman@khavrinen.lcs.mit.edu Subject: Re: [kernel patch] fcntl(...) to close many descriptors Message-ID: <p05010400b69ac2c32903@[128.113.24.47]> In-Reply-To: <200101290303.f0T33qg60603@earth.backplane.com> References: <200101281837.f0SIbGI24332@iguana.aciri.org> <200101290303.f0T33qg60603@earth.backplane.com>
next in thread | previous in thread | raw e-mail | index | archive | help
At 7:03 PM -0800 1/28/01, Matt Dillon wrote:
>Luigo wrote:
>: do we have (or could we design) a generic mechanism for
>: machine-specific syscalls which are not available on all OS ?
>:
>: basically i am thinking of something like
>:
>: generic_syscall("fdcloseall", ....);
>:
>: In this way it would be clear what the non-portable pieces of code
>: are, and the mechanism would be extensible with no changes to
>: libraries and syscalls. You could even have dynamically-loaded
>: modules implementing new "syscalls".
>:
>: cheers
>: luigi
>
> There is work going on for the AIX equivalent using fcntl().
> We should not create a syscall (it's unnecessary)... if you
> want a fdcloseall() function call, it should be in libc and
> use the fcntl.
Note that Luigi was asking for a generic syscall mechanism, and
was only using fdcloseall as an example of how that might be
used. [it was I who made the mistaken-assumption that any
closeallfds routine would be somewhere in the kernel. I have
no idea why I thought that...]
> I would support one or the other, but not both. I'd recommend
> the AIX fcntl API, since it's been around a whole lot longer.
>
> -Matt
Mouss <usebsd@free.fr> mentioned that NetBSD has a closeall
function in it's libc, and it sounded like he was going to
mimic that instead of the fcntl change. If I were going to
mimic something, I'd rather mimic netbsd than some feature
which exists only in AIX. And as I mentioned in my previous
message, I think the AIX strategy warps the definition of
the fcntl routine, so I was not too fond of it even if there
hadn't been any BSD-based alternative to follow.
--
Garance Alistair Drosehn = gad@eclipse.acs.rpi.edu
Senior Systems Programmer or gad@freebsd.org
Rensselaer Polytechnic Institute or drosih@rpi.edu
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-hackers" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?p05010400b69ac2c32903>
