[BACK]Return to subr_pool.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / kern

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/kern/subr_pool.c between version 1.74 and 1.75

version 1.74, 2002/03/09 18:06:55 version 1.75, 2002/03/13 08:12:58
Line 1048  pool_prime(struct pool *pp, int n)
Line 1048  pool_prime(struct pool *pp, int n)
 {  {
         struct pool_item_header *ph;          struct pool_item_header *ph;
         caddr_t cp;          caddr_t cp;
         int newpages, error = 0;          int newpages;
   
         simple_lock(&pp->pr_slock);          simple_lock(&pp->pr_slock);
   
Line 1062  pool_prime(struct pool *pp, int n)
Line 1062  pool_prime(struct pool *pp, int n)
                 simple_lock(&pp->pr_slock);                  simple_lock(&pp->pr_slock);
   
                 if (__predict_false(cp == NULL || ph == NULL)) {                  if (__predict_false(cp == NULL || ph == NULL)) {
                         error = ENOMEM;  
                         if (cp != NULL)                          if (cp != NULL)
                                 pool_allocator_free(pp, cp);                                  pool_allocator_free(pp, cp);
                         break;                          break;
Line 1198  pool_catchup(struct pool *pp)
Line 1197  pool_catchup(struct pool *pp)
 void  void
 pool_setlowat(struct pool *pp, int n)  pool_setlowat(struct pool *pp, int n)
 {  {
         int error;  
   
         simple_lock(&pp->pr_slock);          simple_lock(&pp->pr_slock);
   
Line 1208  pool_setlowat(struct pool *pp, int n)
Line 1206  pool_setlowat(struct pool *pp, int n)
                 : roundup(n, pp->pr_itemsperpage) / pp->pr_itemsperpage;                  : roundup(n, pp->pr_itemsperpage) / pp->pr_itemsperpage;
   
         /* Make sure we're caught up with the newly-set low water mark. */          /* Make sure we're caught up with the newly-set low water mark. */
         if (POOL_NEEDS_CATCHUP(pp) && (error = pool_catchup(pp) != 0)) {          if (POOL_NEEDS_CATCHUP(pp) && pool_catchup(pp) != 0) {
                 /*                  /*
                  * XXX: Should we log a warning?  Should we set up a timeout                   * XXX: Should we log a warning?  Should we set up a timeout
                  * to try again in a second or so?  The latter could break                   * to try again in a second or so?  The latter could break

Legend:
Removed from v.1.74  
changed lines
  Added in v.1.75

CVSweb <webmaster@jp.NetBSD.org>