Re: Please revert git commit 1ad3dcc0
- From: Linus Torvalds <torvalds@xxxxxxxx>
- Date: Tue, 16 May 2006 07:54:11 -0700 (PDT)
On Tue, 16 May 2006, Bernd Schmidt wrote:
It's not the get_file that's the problem, it's the get_unused_fd and
fd_install. These files are now open while the process lives and consume file
descriptors.
Side note: this would be a valid argument, except it's not always true.
I'm not sure why Luke wanted the fd in the first place, though, and
whether we want it.
Some loaders may actually want the fd value, see for example themisc
loader and MISC_FMT_OPEN_BINARY, and the ELF loader _does_ actually do it
for the (interpreter_type == INTERPRETER_AOUT) case.
So it's certainly not a new concept, and other loaders do the exact same
thing.
Whether the flat loader should do it (or under what circumstances it
should do it), I just can't make any judgement. More information needed.
Before the change, we didn't allocate or install a file descriptor, hence
there wasn't any reason to return EMFILE. The spec at
http://www.opengroup.org/onlinepubs/009695399/functions/exec.html
doesn't list EMFILE as a possible error.
Totally irrelevant.
A lot of system calls will return errors other than the ones listed. The
text says "shall fail if", which just means that those errors are
_required_ to happen under the circumstances listed (and you can't use
other errors _for_those_particular_circumstances_).
See
http://www.opengroup.org/onlinepubs/009695399/functions/xsh_chap02_03.html#tag_02_03
"Implementations may support additional errors not included in this
list, may generate errors included in this list under circumstances
other than those described here, or may contain extensions or
limitations that prevent some errors from occurring. The ERRORS section
on each reference page specifies whether an error shall be returned, or
whether it may be returned. Implementations shall not generate a
different error number from the ones described here for error
conditions described in this volume of IEEE Std 1003.1-2001, but may
generate additional errors unless explicitly disallowed for a
particular function."
for more.
Linus
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
- Follow-Ups:
- Re: Please revert git commit 1ad3dcc0
- From: Bernd Schmidt
- Re: Please revert git commit 1ad3dcc0
- References:
- Please revert git commit 1ad3dcc0
- From: Bernd Schmidt
- Re: Please revert git commit 1ad3dcc0
- From: Andrew Morton
- Re: Please revert git commit 1ad3dcc0
- From: Bernd Schmidt
- Please revert git commit 1ad3dcc0
- Prev by Date: Re: [PATCH] Register sysfs file for hotpluged new node
- Next by Date: broadcom 5752 in HP dc7600U works on 2.6.13 but does not working on 2.6.16
- Previous by thread: Re: Please revert git commit 1ad3dcc0
- Next by thread: Re: Please revert git commit 1ad3dcc0
- Index(es):