Print this page
5253 kmem_alloc/kmem_zalloc won't fail with KM_SLEEP
5254 getrbuf won't fail with KM_SLEEP

Split Close
Expand all
Collapse all
          --- old/usr/src/uts/common/io/comstar/lu/stmf_sbd/sbd.c
          +++ new/usr/src/uts/common/io/comstar/lu/stmf_sbd/sbd.c
↓ open down ↓ 3361 lines elided ↑ open up ↑
3362 3362   */
3363 3363  sbd_status_t
3364 3364  sbd_create_zfs_meta_object(sbd_lu_t *sl)
3365 3365  {
3366 3366          /*
3367 3367           * -allocate 1/2 the property size, the zfs property
3368 3368           *  is 8k in size and stored as ascii hex string, all
3369 3369           *  we needed is 4k buffer to store the binary data.
3370 3370           * -initialize reader/write lock
3371 3371           */
3372      -        if ((sl->sl_zfs_meta = kmem_zalloc(ZAP_MAXVALUELEN / 2, KM_SLEEP))
3373      -            == NULL)
3374      -                return (SBD_FAILURE);
     3372 +        sl->sl_zfs_meta = kmem_zalloc(ZAP_MAXVALUELEN / 2, KM_SLEEP);
3375 3373          rw_init(&sl->sl_zfs_meta_lock, NULL, RW_DRIVER, NULL);
3376 3374          return (SBD_SUCCESS);
3377 3375  }
3378 3376  
3379 3377  char
3380 3378  sbd_ctoi(char c)
3381 3379  {
3382 3380          if ((c >= '0') && (c <= '9'))
3383 3381                  c -= '0';
3384 3382          else if ((c >= 'A') && (c <= 'F'))
↓ open down ↓ 334 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX