Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Jul 2010 17:46:58 GMT
From:      Edward Tomasz Napierala <trasz@FreeBSD.org>
To:        Perforce Change Reviews <perforce@freebsd.org>
Subject:   PERFORCE change 181009 for review
Message-ID:  <201007151746.o6FHkwQC083449@repoman.freebsd.org>

next in thread | raw e-mail | index | archive | help
http://p4web.freebsd.org/@@181009?ac=10

Change 181009 by trasz@trasz_victim on 2010/07/15 17:46:17

	Remove resource accounting from compat_svr4 version of poll(2);
	it's not needed there.

Affected files ...

.. //depot/projects/soc2009/trasz_limits/sys/compat/svr4/svr4_filio.c#8 edit

Differences ...

==== //depot/projects/soc2009/trasz_limits/sys/compat/svr4/svr4_filio.c#8 (text+ko) ====

@@ -37,7 +37,6 @@
 #include <sys/lock.h>
 #include <sys/signal.h>
 #include <sys/filedesc.h>
-#include <sys/container.h>
 #include <sys/poll.h>
 #include <sys/malloc.h>
 #include <sys/mutex.h>
@@ -67,9 +66,6 @@
      int idx = 0, cerr;
      u_long siz;
 
-     /*
-      * XXX: What is this for?
-      */
      PROC_LOCK(td->td_proc);
      if (uap->nfds > lim_cur(td->td_proc, RLIMIT_NOFILE) &&
        uap->nfds > FD_SETSIZE) {
@@ -78,9 +74,6 @@
      }
      PROC_UNLOCK(td->td_proc);
 
-#ifdef CONTAINERS
-     rusage_add(td->td_proc, RUSAGE_FILEDESCRIPTORS, uap->nfds);
-#endif
      pa.fds = uap->fds;
      pa.nfds = uap->nfds;
      pa.timeout = uap->timeout;
@@ -106,9 +99,6 @@
 		       forget to update it if I add more code */
      }
 done:
-#ifdef CONTAINERS
-     rusage_sub(td->td_proc, RUSAGE_FILEDESCRIPTORS, uap->nfds);
-#endif
      free(pfd, M_TEMP);
      return error;
 }



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201007151746.o6FHkwQC083449>