Lines Matching refs:dnode

290 		chfs_remove_and_obsolete(chmp, vc, td->node->nref, &vc->dnode);	  in chfs_kill_td()
724 chfs_remove_and_obsolete(chmp, vc, this->node->nref, &vc->dnode); in chfs_obsolete_node_frag()
792 struct chfs_flash_data_node *dnode; in chfs_get_data_nodes() local
798 dnode = kmem_alloc(len, KM_SLEEP); in chfs_get_data_nodes()
799 nref = chfs_first_valid_data_ref(ip->chvc->dnode); in chfs_get_data_nodes()
808 dnode = (struct chfs_flash_data_node*)buf; in chfs_get_data_nodes()
811 crc = crc32(0, (uint8_t *)dnode, CHFS_NODE_HDR_SIZE - 4); in chfs_get_data_nodes()
812 if (crc != le32toh(dnode->hdr_crc)) { in chfs_get_data_nodes()
813 chfs_err("CRC check failed. calc: 0x%x orig: 0x%x\n", crc, le32toh(dnode->hdr_crc)); in chfs_get_data_nodes()
818 if (le16toh(dnode->magic) != CHFS_FS_MAGIC_BITMASK) { in chfs_get_data_nodes()
824 crc = crc32(0, (uint8_t *)dnode, sizeof(*dnode) - 4); in chfs_get_data_nodes()
825 if (crc != le32toh(dnode->node_crc)) { in chfs_get_data_nodes()
826 chfs_err("Node CRC check failed. calc: 0x%x orig: 0x%x\n", crc, le32toh(dnode->node_crc)); in chfs_get_data_nodes()
847 td->version = le64toh(dnode->version); in chfs_get_data_nodes()
848 td->node->ofs = le64toh(dnode->offset); in chfs_get_data_nodes()
849 td->data_crc = le32toh(dnode->data_crc); in chfs_get_data_nodes()
851 td->node->size = le32toh(dnode->data_length); in chfs_get_data_nodes()
877 kmem_free(dnode, len); in chfs_get_data_nodes()
1109 struct chfs_flash_data_node *dnode; in chfs_read_data() local
1130 size = sizeof(*dnode) + frag->size; in chfs_read_data()
1148 dnode = (struct chfs_flash_data_node *)buf; in chfs_read_data()
1149 crc = crc32(0, (uint8_t *)dnode, CHFS_NODE_HDR_SIZE - 4); in chfs_read_data()
1150 if (crc != le32toh(dnode->hdr_crc)) { in chfs_read_data()
1151 chfs_err("CRC check failed. calc: 0x%x orig: 0x%x\n", crc, le32toh(dnode->hdr_crc)); in chfs_read_data()
1157 if (le16toh(dnode->magic) != CHFS_FS_MAGIC_BITMASK) { in chfs_read_data()
1164 crc = crc32(0, (uint8_t *)dnode, sizeof(*dnode) - 4); in chfs_read_data()
1165 if (crc != le32toh(dnode->node_crc)) { in chfs_read_data()
1166 chfs_err("Node CRC check failed. calc: 0x%x orig: 0x%x\n", crc, le32toh(dnode->node_crc)); in chfs_read_data()
1172 crc = crc32(0, (uint8_t *)dnode->data, dnode->data_length); in chfs_read_data()
1173 if (crc != le32toh(dnode->data_crc)) { in chfs_read_data()
1174 chfs_err("Data CRC check failed. calc: 0x%x orig: 0x%x\n", crc, le32toh(dnode->data_crc)); in chfs_read_data()
1179 memcpy(bp->b_data, dnode->data, dnode->data_length); in chfs_read_data()