Print this page
5045 use atomic_{inc,dec}_* instead of atomic_add_*

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/rpc/clnt_clts.c
          +++ new/usr/src/uts/common/rpc/clnt_clts.c
↓ open down ↓ 235 lines elided ↑ open up ↑
 236  236          { "badverfs",   KSTAT_DATA_UINT64 },
 237  237          { "timers",     KSTAT_DATA_UINT64 },
 238  238          { "nomem",      KSTAT_DATA_UINT64 },
 239  239          { "cantsend",   KSTAT_DATA_UINT64 },
 240  240  };
 241  241  
 242  242  static uint_t clts_rcstat_ndata =
 243  243          sizeof (clts_rcstat_tmpl) / sizeof (kstat_named_t);
 244  244  
 245  245  #define RCSTAT_INCR(s, x)                       \
 246      -        atomic_add_64(&(s)->x.value.ui64, 1)
      246 +        atomic_inc_64(&(s)->x.value.ui64)
 247  247  
 248  248  #define ptoh(p)         (&((p)->cku_client))
 249  249  #define htop(h)         ((struct cku_private *)((h)->cl_private))
 250  250  
 251  251  /*
 252  252   * Times to retry
 253  253   */
 254  254  #define SNDTRIES        4
 255  255  #define REFRESHES       2       /* authentication refreshes */
 256  256  
↓ open down ↓ 2020 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX