PERFORCE change 180842 for review
Edward Tomasz Napierala
trasz at FreeBSD.org
Mon Jul 12 18:47:53 UTC 2010
http://p4web.freebsd.org/@@180842?ac=10
Change 180842 by trasz at trasz_victim on 2010/07/12 18:47:26
Update comments and remove workaround for some long forgotten problem.
Affected files ...
.. //depot/projects/soc2009/trasz_limits/sys/kern/kern_hrl.c#86 edit
Differences ...
==== //depot/projects/soc2009/trasz_limits/sys/kern/kern_hrl.c#86 (text+ko) ====
@@ -214,7 +214,6 @@
case HRL_SUBJECT_TYPE_LOGINCLASS:
available = rule->hr_amount -
cred->cr_loginclass->lc_container.c_resources[resource];
- available = INT64_MAX; /* XXX */
break;
case HRL_SUBJECT_TYPE_JAIL:
available = rule->hr_amount -
@@ -275,18 +274,8 @@
mtx_lock(&hrl_lock);
/*
- * It seems we've hit a limit. Figure out what to do. There may
- * be more than one matching limit; go through all of them. Denial
- * should be done last, after logging and sending signals.
- *
- * Note that it is possible to get here, and still not trigger
- * any limit, because some of the resource got freed on another
- * CPU after computing contents of the 'available' array.
- */
- /*
- * XXX: We should sort the rules somewhat, so that 'log' and 'sig'
- * rules come before before 'deny', to spare iterations over
- * the p_container.c_rule_links.
+ * There may be more than one matching rule; go through all of them.
+ * Denial should be done last, after logging and sending signals.
*/
LIST_FOREACH(link, &p->p_container.c_rule_links, hrl_next) {
rule = link->hrl_rule;
More information about the p4-projects
mailing list