Lines Matching refs:lr

296 	_lr_create_t *lr = &lracl->lr_create;  in zfs_replay_create_acl()  local
312 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lracl)); in zfs_replay_create_acl()
314 txtype = (lr->lr_common.lrc_txtype & ~TX_CI); in zfs_replay_create_acl()
335 if ((error = zfs_zget(zfsvfs, lr->lr_doid, &dzp)) != 0) in zfs_replay_create_acl()
338 objid = LR_FOID_GET_OBJ(lr->lr_foid); in zfs_replay_create_acl()
339 dnodesize = LR_FOID_GET_SLOTS(lr->lr_foid) << DNODE_SHIFT; in zfs_replay_create_acl()
343 lr->lr_mode, lr->lr_uid, lr->lr_gid, lr->lr_rdev, objid); in zfs_replay_create_acl()
353 ZFS_TIME_DECODE(&xva.xva_vattr.va_ctime, lr->lr_crtime); in zfs_replay_create_acl()
354 xva.xva_vattr.va_nblocks = lr->lr_gen; in zfs_replay_create_acl()
361 if (lr->lr_common.lrc_txtype & TX_CI) in zfs_replay_create_acl()
369 lr->lr_uid, lr->lr_gid); in zfs_replay_create_acl()
389 lr->lr_uid, lr->lr_gid); in zfs_replay_create_acl()
405 lr->lr_uid, lr->lr_gid); in zfs_replay_create_acl()
424 lr->lr_uid, lr->lr_gid); in zfs_replay_create_acl()
459 _lr_create_t *lr = &lrc->lr_create; in zfs_replay_create() local
474 ASSERT3U(lr->lr_common.lrc_reclen, >, sizeof (*lr)); in zfs_replay_create()
476 txtype = (lr->lr_common.lrc_txtype & ~TX_CI); in zfs_replay_create()
484 if ((error = zfs_zget(zfsvfs, lr->lr_doid, &dzp)) != 0) in zfs_replay_create()
487 objid = LR_FOID_GET_OBJ(lr->lr_foid); in zfs_replay_create()
488 dnodesize = LR_FOID_GET_SLOTS(lr->lr_foid) << DNODE_SHIFT; in zfs_replay_create()
492 lr->lr_mode, lr->lr_uid, lr->lr_gid, lr->lr_rdev, objid); in zfs_replay_create()
502 ZFS_TIME_DECODE(&xva.xva_vattr.va_ctime, lr->lr_crtime); in zfs_replay_create()
503 xva.xva_vattr.va_nblocks = lr->lr_gen; in zfs_replay_create()
510 if (lr->lr_common.lrc_txtype & TX_CI) in zfs_replay_create()
525 lr->lr_uid, lr->lr_gid); in zfs_replay_create()
536 lr->lr_uid, lr->lr_gid); in zfs_replay_create()
559 lr->lr_uid, lr->lr_gid); in zfs_replay_create()
613 lr_remove_t *lr = arg2; in zfs_replay_remove() local
614 char *name = (char *)&lr->lr_data[0]; /* name follows lr_remove_t */ in zfs_replay_remove()
619 ASSERT3U(lr->lr_common.lrc_reclen, >, sizeof (*lr)); in zfs_replay_remove()
622 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_remove()
624 if ((error = zfs_zget(zfsvfs, lr->lr_doid, &dzp)) != 0) in zfs_replay_remove()
627 if (lr->lr_common.lrc_txtype & TX_CI) in zfs_replay_remove()
630 switch ((int)lr->lr_common.lrc_txtype) { in zfs_replay_remove()
650 lr_link_t *lr = arg2; in zfs_replay_link() local
651 char *name = &lr->lr_data[0]; /* name follows lr_link_t */ in zfs_replay_link()
656 ASSERT3U(lr->lr_common.lrc_reclen, >, sizeof (*lr)); in zfs_replay_link()
659 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_link()
661 if ((error = zfs_zget(zfsvfs, lr->lr_doid, &dzp)) != 0) in zfs_replay_link()
664 if ((error = zfs_zget(zfsvfs, lr->lr_link_obj, &zp)) != 0) { in zfs_replay_link()
669 if (lr->lr_common.lrc_txtype & TX_CI) in zfs_replay_link()
680 do_zfs_replay_rename(zfsvfs_t *zfsvfs, _lr_rename_t *lr, char *sname, in do_zfs_replay_rename() argument
696 if ((error = zfs_zget(zfsvfs, lr->lr_sdoid, &sdzp)) != 0) in do_zfs_replay_rename()
699 if ((error = zfs_zget(zfsvfs, lr->lr_tdoid, &tdzp)) != 0) { in do_zfs_replay_rename()
704 if (lr->lr_common.lrc_txtype & TX_CI) in do_zfs_replay_rename()
725 _lr_rename_t *lr = &lrr->lr_rename; in zfs_replay_rename() local
727 ASSERT3U(lr->lr_common.lrc_reclen, >, sizeof (*lr)); in zfs_replay_rename()
735 return (do_zfs_replay_rename(zfsvfs, lr, sname, tname, 0, NULL)); in zfs_replay_rename()
744 _lr_rename_t *lr = &lrr->lr_rename; in zfs_replay_rename_exchange() local
746 ASSERT3U(lr->lr_common.lrc_reclen, >, sizeof (*lr)); in zfs_replay_rename_exchange()
754 return (do_zfs_replay_rename(zfsvfs, lr, sname, tname, RENAME_EXCHANGE, in zfs_replay_rename_exchange()
767 _lr_rename_t *lr = &lrrw->lr_rename; in zfs_replay_rename_whiteout() local
774 ASSERT3U(lr->lr_common.lrc_reclen, >, sizeof (*lr)); in zfs_replay_rename_whiteout()
805 return (do_zfs_replay_rename(zfsvfs, lr, sname, tname, in zfs_replay_rename_whiteout()
816 lr_write_t *lr = arg2; in zfs_replay_write() local
817 char *data = &lr->lr_data[0]; /* data follows lr_write_t */ in zfs_replay_write()
822 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr)); in zfs_replay_write()
825 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_write()
827 if ((error = zfs_zget(zfsvfs, lr->lr_foid, &zp)) != 0) { in zfs_replay_write()
838 offset = lr->lr_offset; in zfs_replay_write()
839 length = lr->lr_length; in zfs_replay_write()
856 if (lr->lr_common.lrc_reclen == sizeof (lr_write_t)) { in zfs_replay_write()
857 uint64_t blocksize = BP_GET_LSIZE(&lr->lr_blkptr); in zfs_replay_write()
882 lr_write_t *lr = arg2; in zfs_replay_write2() local
887 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr)); in zfs_replay_write2()
890 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_write2()
892 if ((error = zfs_zget(zfsvfs, lr->lr_foid, &zp)) != 0) in zfs_replay_write2()
896 end = lr->lr_offset + lr->lr_length; in zfs_replay_write2()
931 lr_truncate_t *lr = arg2; in zfs_replay_truncate() local
936 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr)); in zfs_replay_truncate()
939 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_truncate()
941 if ((error = zfs_zget(zfsvfs, lr->lr_foid, &zp)) != 0) in zfs_replay_truncate()
946 fl.l_start = lr->lr_offset; in zfs_replay_truncate()
947 fl.l_len = lr->lr_length; in zfs_replay_truncate()
950 lr->lr_offset, kcred); in zfs_replay_truncate()
961 lr_setattr_t *lr = arg2; in zfs_replay_setattr() local
968 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr)); in zfs_replay_setattr()
972 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_setattr()
974 if ((lr->lr_mask & ATTR_XVATTR) && in zfs_replay_setattr()
976 zfs_replay_swap_attrs((lr_attr_t *)&lr->lr_data[0]); in zfs_replay_setattr()
979 if ((error = zfs_zget(zfsvfs, lr->lr_foid, &zp)) != 0) in zfs_replay_setattr()
982 zfs_init_vattr(vap, lr->lr_mask, lr->lr_mode, in zfs_replay_setattr()
983 lr->lr_uid, lr->lr_gid, 0, lr->lr_foid); in zfs_replay_setattr()
985 vap->va_size = lr->lr_size; in zfs_replay_setattr()
986 ZFS_TIME_DECODE(&vap->va_atime, lr->lr_atime); in zfs_replay_setattr()
987 ZFS_TIME_DECODE(&vap->va_mtime, lr->lr_mtime); in zfs_replay_setattr()
995 start = (void *)&lr->lr_data[0]; in zfs_replay_setattr()
998 start = &lr->lr_data[ in zfs_replay_setattr()
1004 lr->lr_uid, lr->lr_gid); in zfs_replay_setattr()
1023 lr_setsaxattr_t *lr = arg2; in zfs_replay_setsaxattr() local
1032 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr)); in zfs_replay_setsaxattr()
1033 ASSERT3U(lr->lr_common.lrc_reclen, >, sizeof (*lr) + lr->lr_size); in zfs_replay_setsaxattr()
1038 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_setsaxattr()
1040 if ((error = zfs_zget(zfsvfs, lr->lr_foid, &zp)) != 0) in zfs_replay_setsaxattr()
1056 size = lr->lr_size; in zfs_replay_setsaxattr()
1057 name = (char *)&lr->lr_data[0]; in zfs_replay_setsaxattr()
1062 value = &lr->lr_data[strlen(name) + 1]; in zfs_replay_setsaxattr()
1106 lr_acl_v0_t *lr = arg2; in zfs_replay_acl_v0() local
1107 ace_t *ace = (ace_t *)&lr->lr_data[0]; in zfs_replay_acl_v0()
1112 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr)); in zfs_replay_acl_v0()
1113 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr) + in zfs_replay_acl_v0()
1114 sizeof (ace_t) * lr->lr_aclcnt); in zfs_replay_acl_v0()
1117 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_acl_v0()
1118 zfs_oldace_byteswap(ace, lr->lr_aclcnt); in zfs_replay_acl_v0()
1121 if ((error = zfs_zget(zfsvfs, lr->lr_foid, &zp)) != 0) in zfs_replay_acl_v0()
1125 vsa.vsa_aclcnt = lr->lr_aclcnt; in zfs_replay_acl_v0()
1155 lr_acl_t *lr = arg2; in zfs_replay_acl() local
1156 ace_t *ace = (ace_t *)&lr->lr_data[0]; in zfs_replay_acl()
1161 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr)); in zfs_replay_acl()
1162 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr) + lr->lr_acl_bytes); in zfs_replay_acl()
1165 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_acl()
1166 zfs_ace_byteswap(ace, lr->lr_acl_bytes, B_FALSE); in zfs_replay_acl()
1167 if (lr->lr_fuidcnt) { in zfs_replay_acl()
1168 byteswap_uint64_array(&lr->lr_data[ in zfs_replay_acl()
1169 ZIL_ACE_LENGTH(lr->lr_acl_bytes)], in zfs_replay_acl()
1170 lr->lr_fuidcnt * sizeof (uint64_t)); in zfs_replay_acl()
1174 if ((error = zfs_zget(zfsvfs, lr->lr_foid, &zp)) != 0) in zfs_replay_acl()
1178 vsa.vsa_aclcnt = lr->lr_aclcnt; in zfs_replay_acl()
1180 vsa.vsa_aclentsz = lr->lr_acl_bytes; in zfs_replay_acl()
1181 vsa.vsa_aclflags = lr->lr_acl_flags; in zfs_replay_acl()
1183 if (lr->lr_fuidcnt) { in zfs_replay_acl()
1184 void *fuidstart = &lr->lr_data[ in zfs_replay_acl()
1185 ZIL_ACE_LENGTH(lr->lr_acl_bytes)]; in zfs_replay_acl()
1189 lr->lr_fuidcnt, lr->lr_domcnt, 0, 0); in zfs_replay_acl()
1207 lr_clone_range_t *lr = arg2; in zfs_replay_clone_range() local
1211 ASSERT3U(lr->lr_common.lrc_reclen, >=, sizeof (*lr)); in zfs_replay_clone_range()
1212 ASSERT3U(lr->lr_common.lrc_reclen, >=, offsetof(lr_clone_range_t, in zfs_replay_clone_range()
1213 lr_bps[lr->lr_nbps])); in zfs_replay_clone_range()
1216 byteswap_uint64_array(lr, sizeof (*lr)); in zfs_replay_clone_range()
1218 if ((error = zfs_zget(zfsvfs, lr->lr_foid, &zp)) != 0) { in zfs_replay_clone_range()
1228 error = zfs_clone_range_replay(zp, lr->lr_offset, lr->lr_length, in zfs_replay_clone_range()
1229 lr->lr_blksz, lr->lr_bps, lr->lr_nbps); in zfs_replay_clone_range()