Lines Matching refs:bestsp
379 __be16 *bestsp; /* leaf's bestsp entries */ in xfs_dir2_block_to_leaf() local
469 bestsp = xfs_dir2_leaf_bests_p(ltp); in xfs_dir2_block_to_leaf()
470 bestsp[0] = bf[0].length; in xfs_dir2_block_to_leaf()
610 __be16 *bestsp; /* freespace table in leaf */ in xfs_dir2_leaf_addname() local
660 bestsp = xfs_dir2_leaf_bests_p(ltp); in xfs_dir2_leaf_addname()
676 ASSERT(bestsp[i] != cpu_to_be16(NULLDATAOFF)); in xfs_dir2_leaf_addname()
677 if (be16_to_cpu(bestsp[i]) >= length) { in xfs_dir2_leaf_addname()
690 if (bestsp[i] == cpu_to_be16(NULLDATAOFF) && in xfs_dir2_leaf_addname()
693 else if (be16_to_cpu(bestsp[i]) >= length) { in xfs_dir2_leaf_addname()
712 if (use_block != -1 && bestsp[use_block] == cpu_to_be16(NULLDATAOFF)) in xfs_dir2_leaf_addname()
718 if ((char *)bestsp - (char *)&ents[leafhdr.count] < needbytes && in xfs_dir2_leaf_addname()
726 else if ((char *)bestsp - (char *)&ents[leafhdr.count] < needbytes) { in xfs_dir2_leaf_addname()
810 bestsp--; in xfs_dir2_leaf_addname()
811 memmove(&bestsp[0], &bestsp[1], in xfs_dir2_leaf_addname()
812 be32_to_cpu(ltp->bestcount) * sizeof(bestsp[0])); in xfs_dir2_leaf_addname()
825 bestsp[use_block] = bf[0].length; in xfs_dir2_leaf_addname()
881 if (be16_to_cpu(bestsp[use_block]) != be16_to_cpu(bf[0].length)) { in xfs_dir2_leaf_addname()
882 bestsp[use_block] = bf[0].length; in xfs_dir2_leaf_addname()
1345 __be16 *bestsp; /* leaf block best freespace */ in xfs_dir2_leaf_removename() local
1390 bestsp = xfs_dir2_leaf_bests_p(ltp); in xfs_dir2_leaf_removename()
1391 ASSERT(be16_to_cpu(bestsp[db]) == oldbest); in xfs_dir2_leaf_removename()
1421 bestsp[db] = bf[0].length; in xfs_dir2_leaf_removename()
1453 if (bestsp[i] != cpu_to_be16(NULLDATAOFF)) in xfs_dir2_leaf_removename()
1460 memmove(&bestsp[db - i], bestsp, in xfs_dir2_leaf_removename()
1461 (be32_to_cpu(ltp->bestcount) - (db - i)) * sizeof(*bestsp)); in xfs_dir2_leaf_removename()
1467 bestsp[db] = cpu_to_be16(NULLDATAOFF); in xfs_dir2_leaf_removename()
1599 __be16 *bestsp; /* leaf bests table */ in xfs_dir2_leaf_trim_data() local
1644 bestsp = xfs_dir2_leaf_bests_p(ltp); in xfs_dir2_leaf_trim_data()
1646 memmove(&bestsp[1], &bestsp[0], be32_to_cpu(ltp->bestcount) * sizeof(*bestsp)); in xfs_dir2_leaf_trim_data()