Lines Matching refs:dnp
628 dnode_phys_t *dnp = dn->dn_phys; in dnode_sync() local
635 ASSERT(dnp->dn_type != DMU_OT_NONE || dn->dn_allocated_txg); in dnode_sync()
636 ASSERT(dnp->dn_type != DMU_OT_NONE || in dnode_sync()
637 bcmp(dnp, &zerodn, DNODE_MIN_SIZE) == 0); in dnode_sync()
674 if (dnp->dn_type == DMU_OT_NONE) { in dnode_sync()
676 dnp->dn_nlevels = 1; in dnode_sync()
677 dnp->dn_nblkptr = dn->dn_nblkptr; in dnode_sync()
680 dnp->dn_type = dn->dn_type; in dnode_sync()
681 dnp->dn_bonustype = dn->dn_bonustype; in dnode_sync()
682 dnp->dn_bonuslen = dn->dn_bonuslen; in dnode_sync()
685 dnp->dn_extra_slots = dn->dn_num_slots - 1; in dnode_sync()
687 ASSERT(dnp->dn_nlevels > 1 || in dnode_sync()
688 BP_IS_HOLE(&dnp->dn_blkptr[0]) || in dnode_sync()
689 BP_IS_EMBEDDED(&dnp->dn_blkptr[0]) || in dnode_sync()
690 BP_GET_LSIZE(&dnp->dn_blkptr[0]) == in dnode_sync()
691 dnp->dn_datablkszsec << SPA_MINBLOCKSHIFT); in dnode_sync()
692 ASSERT(dnp->dn_nlevels < 2 || in dnode_sync()
693 BP_IS_HOLE(&dnp->dn_blkptr[0]) || in dnode_sync()
694 BP_GET_LSIZE(&dnp->dn_blkptr[0]) == 1 << dnp->dn_indblkshift); in dnode_sync()
697 dnp->dn_type = dn->dn_type; in dnode_sync()
704 ASSERT(BP_IS_HOLE(&dnp->dn_blkptr[0]) || in dnode_sync()
707 dnp->dn_datablkszsec || in dnode_sync()
709 dnp->dn_datablkszsec = in dnode_sync()
716 dnp->dn_bonuslen = 0; in dnode_sync()
718 dnp->dn_bonuslen = dn->dn_next_bonuslen[txgoff]; in dnode_sync()
719 ASSERT(dnp->dn_bonuslen <= in dnode_sync()
720 DN_SLOTS_TO_BONUSLEN(dnp->dn_extra_slots + 1)); in dnode_sync()
726 dnp->dn_bonustype = dn->dn_next_bonustype[txgoff]; in dnode_sync()
738 if (dnp->dn_flags & DNODE_FLAG_SPILL_BLKPTR) in dnode_sync()
744 ASSERT(dnp->dn_nlevels == 1); in dnode_sync()
745 dnp->dn_indblkshift = dn->dn_next_indblkshift[txgoff]; in dnode_sync()
754 dnp->dn_checksum = dn->dn_checksum; in dnode_sync()
755 dnp->dn_compress = dn->dn_compress; in dnode_sync()
762 dnp->dn_flags &= ~DNODE_FLAG_SPILL_BLKPTR; in dnode_sync()
819 dnp->dn_maxblkid = in dnode_sync()
828 if (dn->dn_next_nblkptr[txgoff] > dnp->dn_nblkptr) { in dnode_sync()
830 bzero(dnp->dn_blkptr + dnp->dn_nblkptr, in dnode_sync()
832 (dn->dn_next_nblkptr[txgoff] - dnp->dn_nblkptr)); in dnode_sync()
836 ASSERT(dn->dn_next_nblkptr[txgoff] < dnp->dn_nblkptr); in dnode_sync()
838 for (i = 0; i < dnp->dn_nblkptr; i++) { in dnode_sync()
840 ASSERT(BP_IS_HOLE(&dnp->dn_blkptr[i])); in dnode_sync()
845 dnp->dn_nblkptr = dn->dn_next_nblkptr[txgoff]; in dnode_sync()
857 ASSERT3U(dnp->dn_bonuslen, <=, DN_MAX_BONUS_LEN(dnp)); in dnode_sync()