Lines Matching refs:nhdr
3157 arc_buf_hdr_t *nhdr; in arc_hdr_realloc() local
3173 nhdr = kmem_cache_alloc(new, KM_PUSHPAGE); in arc_hdr_realloc()
3178 bcopy(hdr, nhdr, HDR_L2ONLY_SIZE); in arc_hdr_realloc()
3181 arc_hdr_set_flags(nhdr, ARC_FLAG_HAS_L1HDR); in arc_hdr_realloc()
3187 nhdr->b_l1hdr.b_state = arc_l2c_only; in arc_hdr_realloc()
3190 ASSERT3P(nhdr->b_l1hdr.b_pabd, ==, NULL); in arc_hdr_realloc()
3223 arc_hdr_clear_flags(nhdr, ARC_FLAG_HAS_L1HDR); in arc_hdr_realloc()
3229 (void) buf_hash_insert(nhdr, NULL); in arc_hdr_realloc()
3241 list_insert_after(&dev->l2ad_buflist, hdr, nhdr); in arc_hdr_realloc()
3256 (void) zfs_refcount_add_many(&dev->l2ad_alloc, arc_hdr_size(nhdr), in arc_hdr_realloc()
3257 nhdr); in arc_hdr_realloc()
3262 return (nhdr); in arc_hdr_realloc()
3273 arc_buf_hdr_t *nhdr; in arc_hdr_realloc_crypt() local
3298 nhdr = kmem_cache_alloc(ncache, KM_PUSHPAGE); in arc_hdr_realloc_crypt()
3305 nhdr->b_dva = hdr->b_dva; in arc_hdr_realloc_crypt()
3306 nhdr->b_birth = hdr->b_birth; in arc_hdr_realloc_crypt()
3307 nhdr->b_type = hdr->b_type; in arc_hdr_realloc_crypt()
3308 nhdr->b_flags = hdr->b_flags; in arc_hdr_realloc_crypt()
3309 nhdr->b_psize = hdr->b_psize; in arc_hdr_realloc_crypt()
3310 nhdr->b_lsize = hdr->b_lsize; in arc_hdr_realloc_crypt()
3311 nhdr->b_spa = hdr->b_spa; in arc_hdr_realloc_crypt()
3312 nhdr->b_l2hdr.b_dev = hdr->b_l2hdr.b_dev; in arc_hdr_realloc_crypt()
3313 nhdr->b_l2hdr.b_daddr = hdr->b_l2hdr.b_daddr; in arc_hdr_realloc_crypt()
3314 nhdr->b_l1hdr.b_freeze_cksum = hdr->b_l1hdr.b_freeze_cksum; in arc_hdr_realloc_crypt()
3315 nhdr->b_l1hdr.b_bufcnt = hdr->b_l1hdr.b_bufcnt; in arc_hdr_realloc_crypt()
3316 nhdr->b_l1hdr.b_byteswap = hdr->b_l1hdr.b_byteswap; in arc_hdr_realloc_crypt()
3317 nhdr->b_l1hdr.b_state = hdr->b_l1hdr.b_state; in arc_hdr_realloc_crypt()
3318 nhdr->b_l1hdr.b_arc_access = hdr->b_l1hdr.b_arc_access; in arc_hdr_realloc_crypt()
3319 nhdr->b_l1hdr.b_acb = hdr->b_l1hdr.b_acb; in arc_hdr_realloc_crypt()
3320 nhdr->b_l1hdr.b_pabd = hdr->b_l1hdr.b_pabd; in arc_hdr_realloc_crypt()
3323 nhdr->b_l1hdr.b_thawed = hdr->b_l1hdr.b_thawed; in arc_hdr_realloc_crypt()
3333 (void) zfs_refcount_add(&nhdr->b_l1hdr.b_refcnt, FTAG); in arc_hdr_realloc_crypt()
3334 nhdr->b_l1hdr.b_buf = hdr->b_l1hdr.b_buf; in arc_hdr_realloc_crypt()
3335 for (buf = nhdr->b_l1hdr.b_buf; buf != NULL; buf = buf->b_next) { in arc_hdr_realloc_crypt()
3337 buf->b_hdr = nhdr; in arc_hdr_realloc_crypt()
3340 zfs_refcount_transfer(&nhdr->b_l1hdr.b_refcnt, &hdr->b_l1hdr.b_refcnt); in arc_hdr_realloc_crypt()
3341 (void) zfs_refcount_remove(&nhdr->b_l1hdr.b_refcnt, FTAG); in arc_hdr_realloc_crypt()
3353 hdr, nhdr); in arc_hdr_realloc_crypt()
3357 arc_hdr_set_flags(nhdr, ARC_FLAG_PROTECTED); in arc_hdr_realloc_crypt()
3359 arc_hdr_clear_flags(nhdr, ARC_FLAG_PROTECTED); in arc_hdr_realloc_crypt()
3394 return (nhdr); in arc_hdr_realloc_crypt()
6247 arc_buf_hdr_t *nhdr; in arc_release() local
6343 nhdr = arc_hdr_alloc(spa, psize, lsize, protected, in arc_release()
6345 ASSERT3P(nhdr->b_l1hdr.b_buf, ==, NULL); in arc_release()
6346 ASSERT0(nhdr->b_l1hdr.b_bufcnt); in arc_release()
6347 ASSERT0(zfs_refcount_count(&nhdr->b_l1hdr.b_refcnt)); in arc_release()
6348 VERIFY3U(nhdr->b_type, ==, type); in arc_release()
6349 ASSERT(!HDR_SHARED_DATA(nhdr)); in arc_release()
6351 nhdr->b_l1hdr.b_buf = buf; in arc_release()
6352 nhdr->b_l1hdr.b_bufcnt = 1; in arc_release()
6354 nhdr->b_crypt_hdr.b_ebufcnt = 1; in arc_release()
6355 (void) zfs_refcount_add(&nhdr->b_l1hdr.b_refcnt, tag); in arc_release()
6356 buf->b_hdr = nhdr; in arc_release()