Print this page


Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/io/zfd.c
          +++ new/usr/src/uts/common/io/zfd.c
↓ open down ↓ 882 lines elided ↑ open up ↑
 883  883                          int instance;
 884  884                          zfd_state_t *prim_zfds;
 885  885  
 886  886                          if (iocbp->ioc_count != TRANSPARENT ||
 887  887                              mp->b_cont == NULL) {
 888  888                                  miocack(qp, mp, 0, EINVAL);
 889  889                                  return;
 890  890                          }
 891  891  
 892  892                          /* Get the primary slave minor device number */
      893 +                        ASSERT(IS_P2ALIGNED(mp->b_cont->b_rptr, 4));
      894 +                        /* LINTED - b_rptr will always be aligned. */
 893  895                          to = *(int *)mp->b_cont->b_rptr;
 894  896                          instance = ZFD_INSTANCE(to);
 895  897  
 896  898                          if ((prim_zfds = ddi_get_soft_state(zfd_soft_state,
 897  899                              instance)) == NULL) {
 898  900                                  miocack(qp, mp, 0, EINVAL);
 899  901                                  return;
 900  902                          }
 901  903  
 902  904                          /* Disallow changing primary/log once set. */
↓ open down ↓ 32 lines elided ↑ open up ↑
 935  937                                  return;
 936  938                          }
 937  939  
 938  940                          if (zfds->zfd_muxt != ZFD_LOG_STREAM) {
 939  941                                  miocack(qp, mp, 0, EINVAL);
 940  942                                  return;
 941  943                          }
 942  944                          prim_zfds = zfds->zfd_inst_pri;
 943  945  
 944  946                          /* Get the flow control setting */
      947 +                        ASSERT(IS_P2ALIGNED(mp->b_cont->b_rptr, 4));
      948 +                        /* LINTED - b_rptr will always be aligned. */
 945  949                          val = *(int *)mp->b_cont->b_rptr;
 946  950                          if (val != 0 && val != 1) {
 947  951                                  miocack(qp, mp, 0, EINVAL);
 948  952                                  return;
 949  953                          }
 950  954  
 951  955                          prim_zfds->zfd_allow_flowcon = (boolean_t)val;
 952  956                          if (!prim_zfds->zfd_allow_flowcon)
 953  957                                  prim_zfds->zfd_is_flowcon = B_FALSE;
 954  958  
↓ open down ↓ 200 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX