K 10 svn:author V 5 trasz K 8 svn:date V 27 2019-05-14T20:19:29.070964Z K 7 svn:log V 454 MFC r345547: Factor out resource limit enforcement code in the ELF loader. It makes the code slightly easier to follow, and might make it easier to fix the resouce accounting to also account for the interpreter. The PROC_UNLOCK() is moved earlier - I don't see anything it should protect; the lim_max() is a wrapper around lim_rlimit(), and that, differently from lim_rlimit_proc(), doesn't require the proc lock to be held. Sponsored by: DARPA, AFRL END