Lines Matching refs:parent
145 if (!new_node->parent) { in hfs_brec_insert()
147 new_node->parent = tree->root; in hfs_brec_insert()
149 fd->bnode = hfs_bnode_find(tree, new_node->parent); in hfs_brec_insert()
180 struct hfs_bnode *node, *parent; in hfs_brec_remove() local
198 if (!node->parent) in hfs_brec_remove()
200 parent = hfs_bnode_find(tree, node->parent); in hfs_brec_remove()
201 if (IS_ERR(parent)) in hfs_brec_remove()
202 return PTR_ERR(parent); in hfs_brec_remove()
204 node = fd->bnode = parent; in hfs_brec_remove()
251 new_node->parent = node->parent; in hfs_bnode_split()
357 struct hfs_bnode *node, *new_node, *parent; in hfs_brec_update_parent() local
365 if (!node->parent) in hfs_brec_update_parent()
369 parent = hfs_bnode_find(tree, node->parent); in hfs_brec_update_parent()
370 if (IS_ERR(parent)) in hfs_brec_update_parent()
371 return PTR_ERR(parent); in hfs_brec_update_parent()
372 __hfs_brec_find(parent, fd, hfs_find_rec_by_key); in hfs_brec_update_parent()
375 hfs_bnode_dump(parent); in hfs_brec_update_parent()
388 end_rec_off = tree->node_size - (parent->num_recs + 1) * 2; in hfs_brec_update_parent()
393 end_off = hfs_bnode_read_u16(parent, end_rec_off); in hfs_brec_update_parent()
397 fd->bnode = parent; in hfs_brec_update_parent()
401 parent = fd->bnode; in hfs_brec_update_parent()
405 (parent->num_recs + 1) * 2; in hfs_brec_update_parent()
409 end_off = start_off = hfs_bnode_read_u16(parent, rec_off); in hfs_brec_update_parent()
410 hfs_bnode_write_u16(parent, rec_off, start_off + diff); in hfs_brec_update_parent()
415 end_off = hfs_bnode_read_u16(parent, rec_off); in hfs_brec_update_parent()
416 hfs_bnode_write_u16(parent, rec_off, end_off + diff); in hfs_brec_update_parent()
418 hfs_bnode_move(parent, start_off + diff, start_off, in hfs_brec_update_parent()
421 hfs_bnode_copy(parent, fd->keyoffset, node, 14, newkeylen); in hfs_brec_update_parent()
422 hfs_bnode_dump(parent); in hfs_brec_update_parent()
425 node = parent; in hfs_brec_update_parent()
430 fd->bnode = hfs_bnode_find(tree, new_node->parent); in hfs_brec_update_parent()
448 if (!rec && node->parent) in hfs_brec_update_parent()
483 new_node->parent = 0; in hfs_btree_inc_height()
501 node->parent = tree->root; in hfs_btree_inc_height()