Print this page
Revert exi_zone to exi_zoneid, and install exi_ne backpointer
NFS Auth per-zone needs better cleanup
curzone reality check and teardown changes to use the RIGHT zone

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/fs/nfs/nfs_auth.c
          +++ new/usr/src/uts/common/fs/nfs/nfs_auth.c
↓ open down ↓ 273 lines elided ↑ open up ↑
 274  274  nfsauth_zone_fini(nfs_globals_t *ng)
 275  275  {
 276  276          nfsauth_globals_t *nag = ng->nfs_auth;
 277  277  
 278  278          ng->nfs_auth = NULL;
 279  279  
 280  280          list_destroy(&nag->refreshq_queue);
 281  281          cv_destroy(&nag->refreshq_cv);
 282  282          mutex_destroy(&nag->refreshq_lock);
 283  283          mutex_destroy(&nag->mountd_lock);
      284 +        /* Extra cleanup. */
      285 +        if (nag->mountd_dh != NULL)
      286 +                door_ki_rele(nag->mountd_dh);
 284  287          kmem_free(nag, sizeof (*nag));
 285  288  }
 286  289  
 287  290  /*
 288  291   * Convert the address in a netbuf to
 289  292   * a hash index for the auth_cache table.
 290  293   */
 291  294  static int
 292  295  hash(struct netbuf *a)
 293  296  {
↓ open down ↓ 574 lines elided ↑ open up ↑
 868  871  
 869  872          uid_t                   tmpuid;
 870  873          gid_t                   tmpgid;
 871  874          uint_t                  tmpngids;
 872  875          gid_t                   *tmpgids;
 873  876  
 874  877          avl_index_t             where;  /* used for avl_find()/avl_insert() */
 875  878  
 876  879          ASSERT(cr != NULL);
 877  880  
      881 +        ASSERT3P(curzone->zone_id, ==, exi->exi_zoneid);
 878  882          nag = nfsauth_get_zg();
 879  883  
 880  884          /*
 881  885           * Now check whether this client already
 882  886           * has an entry for this flavor in the cache
 883  887           * for this export.
 884  888           * Get the caller's address, mask off the
 885  889           * parts of the address that do not identify
 886  890           * the host (port number, etc), and then hash
 887  891           * it to find the chain of cache entries.
↓ open down ↓ 709 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX