Lines Matching refs:count
127 ASSERT(!to->count && !to->usedbytes); in xfs_attr3_leaf_firstused_from_disk()
181 to->count = be16_to_cpu(hdr3->count); in xfs_attr3_leaf_hdr_from_disk()
195 to->count = be16_to_cpu(from->hdr.count); in xfs_attr3_leaf_hdr_from_disk()
223 hdr3->count = cpu_to_be16(from->count); in xfs_attr3_leaf_hdr_to_disk()
238 to->hdr.count = cpu_to_be16(from->count); in xfs_attr3_leaf_hdr_to_disk()
276 if (ichdr.count == 0) in xfs_attr3_leaf_verify()
518 hdr->count = 0; in xfs_attr_shortform_create()
547 for (i = 0; i < sf->hdr.count; sfe = XFS_ATTR_SF_NEXTENTRY(sfe), i++) { in xfs_attr_shortform_add()
570 sf->hdr.count++; in xfs_attr_shortform_add()
615 end = sf->hdr.count; in xfs_attr_shortform_remove()
637 sf->hdr.count--; in xfs_attr_shortform_remove()
684 for (i = 0; i < sf->hdr.count; in xfs_attr_shortform_lookup()
711 for (i = 0; i < sf->hdr.count; in xfs_attr_shortform_getvalue()
802 for (i = 0; i < sf->hdr.count; i++) { in xfs_attr_shortform_to_leaf()
847 for (i = 0; i < leafhdr.count; entry++, i++) { in xfs_attr_shortform_allfit()
931 for (i = 0; i < ichdr.count; entry++, i++) { in xfs_attr3_leaf_to_shortform()
1011 btree[0].hashval = entries[icleafhdr.count - 1].hashval; in xfs_attr3_leaf_to_node()
1013 icnodehdr.count = 1; in xfs_attr3_leaf_to_node()
1158 ASSERT(args->index >= 0 && args->index <= ichdr.count); in xfs_attr3_leaf_add()
1165 tablesize = (ichdr.count + 1) * sizeof(xfs_attr_leaf_entry_t) in xfs_attr3_leaf_add()
1239 ASSERT(args->index >= 0 && args->index <= ichdr->count); in xfs_attr3_leaf_add_work()
1245 if (args->index < ichdr->count) { in xfs_attr3_leaf_add_work()
1246 tmp = ichdr->count - args->index; in xfs_attr3_leaf_add_work()
1252 ichdr->count++; in xfs_attr3_leaf_add_work()
1283 ASSERT((args->index == ichdr->count - 1) || in xfs_attr3_leaf_add_work()
1322 ASSERT(ichdr->firstused >= ichdr->count * sizeof(xfs_attr_leaf_entry_t) in xfs_attr3_leaf_add_work()
1324 tmp = (ichdr->count - 1) * sizeof(xfs_attr_leaf_entry_t) in xfs_attr3_leaf_add_work()
1371 ichdr_dst->count = 0; in xfs_attr3_leaf_compact()
1385 leaf_dst, ichdr_dst, 0, ichdr_src.count); in xfs_attr3_leaf_compact()
1411 if (leaf1hdr->count > 0 && leaf2hdr->count > 0 && in xfs_attr3_leaf_order()
1414 (be32_to_cpu(entries2[leaf2hdr->count - 1].hashval) < in xfs_attr3_leaf_order()
1415 be32_to_cpu(entries1[leaf1hdr->count - 1].hashval)))) { in xfs_attr3_leaf_order()
1460 int count; in xfs_attr3_leaf_rebalance() local
1475 ASSERT(ichdr2.count == 0); in xfs_attr3_leaf_rebalance()
1515 &count, &totallen); in xfs_attr3_leaf_rebalance()
1522 if (count < ichdr1.count) { in xfs_attr3_leaf_rebalance()
1527 count = ichdr1.count - count; in xfs_attr3_leaf_rebalance()
1529 space += count * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_rebalance()
1535 max -= ichdr2.count * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_rebalance()
1543 ichdr1.count - count, leaf2, &ichdr2, 0, count); in xfs_attr3_leaf_rebalance()
1545 } else if (count > ichdr1.count) { in xfs_attr3_leaf_rebalance()
1556 count -= ichdr1.count; in xfs_attr3_leaf_rebalance()
1558 space += count * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_rebalance()
1564 max -= ichdr1.count * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_rebalance()
1572 ichdr1.count, count); in xfs_attr3_leaf_rebalance()
1585 blk1->hashval = be32_to_cpu(entries1[ichdr1.count - 1].hashval); in xfs_attr3_leaf_rebalance()
1586 blk2->hashval = be32_to_cpu(entries2[ichdr2.count - 1].hashval); in xfs_attr3_leaf_rebalance()
1600 if (blk1->index > ichdr1.count) { in xfs_attr3_leaf_rebalance()
1602 blk2->index = blk1->index - ichdr1.count; in xfs_attr3_leaf_rebalance()
1605 } else if (blk1->index == ichdr1.count) { in xfs_attr3_leaf_rebalance()
1617 blk2->index = blk1->index - ichdr1.count; in xfs_attr3_leaf_rebalance()
1657 int count; in xfs_attr3_leaf_figure_balance() local
1670 max = ichdr1->count + ichdr2->count; in xfs_attr3_leaf_figure_balance()
1677 for (count = index = 0; count < max; entry++, index++, count++) { in xfs_attr3_leaf_figure_balance()
1683 if (count == blk1->index) { in xfs_attr3_leaf_figure_balance()
1696 if (count == ichdr1->count) { in xfs_attr3_leaf_figure_balance()
1718 totallen -= count * sizeof(*entry); in xfs_attr3_leaf_figure_balance()
1724 *countarg = count; in xfs_attr3_leaf_figure_balance()
1771 ichdr.count * sizeof(xfs_attr_leaf_entry_t) + in xfs_attr3_leaf_toosmall()
1784 if (ichdr.count == 0) { in xfs_attr3_leaf_toosmall()
1830 ((ichdr.count + ichdr2.count) * in xfs_attr3_leaf_toosmall()
1892 ASSERT(ichdr.count > 0 && ichdr.count < args->geo->blksize / 8); in xfs_attr3_leaf_remove()
1893 ASSERT(args->index >= 0 && args->index < ichdr.count); in xfs_attr3_leaf_remove()
1894 ASSERT(ichdr.firstused >= ichdr.count * sizeof(*entry) + in xfs_attr3_leaf_remove()
1908 tablesize = ichdr.count * sizeof(xfs_attr_leaf_entry_t) in xfs_attr3_leaf_remove()
1977 tmp = (ichdr.count - args->index) * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_remove()
1979 ichdr.count--; in xfs_attr3_leaf_remove()
1983 entry = &xfs_attr3_leaf_entryp(leaf)[ichdr.count]; in xfs_attr3_leaf_remove()
1995 for (i = ichdr.count - 1; i >= 0; entry++, i--) { in xfs_attr3_leaf_remove()
2017 ichdr.count * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_remove()
2048 drop_blk->hashval = be32_to_cpu(entry[drophdr.count - 1].hashval); in xfs_attr3_leaf_unbalance()
2065 drophdr.count); in xfs_attr3_leaf_unbalance()
2070 savehdr.count, drophdr.count); in xfs_attr3_leaf_unbalance()
2103 drophdr.count); in xfs_attr3_leaf_unbalance()
2106 tmp_leaf, &tmphdr, tmphdr.count, in xfs_attr3_leaf_unbalance()
2107 savehdr.count); in xfs_attr3_leaf_unbalance()
2112 savehdr.count); in xfs_attr3_leaf_unbalance()
2115 tmp_leaf, &tmphdr, tmphdr.count, in xfs_attr3_leaf_unbalance()
2116 drophdr.count); in xfs_attr3_leaf_unbalance()
2131 save_blk->hashval = be32_to_cpu(entry[savehdr.count - 1].hashval); in xfs_attr3_leaf_unbalance()
2171 ASSERT(ichdr.count < args->geo->blksize / 8); in xfs_attr3_leaf_lookup_int()
2177 probe = span = ichdr.count / 2; in xfs_attr3_leaf_lookup_int()
2187 ASSERT(probe >= 0 && (!ichdr.count || probe < ichdr.count)); in xfs_attr3_leaf_lookup_int()
2198 while (probe < ichdr.count && in xfs_attr3_leaf_lookup_int()
2203 if (probe == ichdr.count || be32_to_cpu(entry->hashval) != hashval) { in xfs_attr3_leaf_lookup_int()
2211 for (; probe < ichdr.count && (be32_to_cpu(entry->hashval) == hashval); in xfs_attr3_leaf_lookup_int()
2275 ASSERT(ichdr.count < args->geo->blksize / 8); in xfs_attr3_leaf_getvalue()
2276 ASSERT(args->index < ichdr.count); in xfs_attr3_leaf_getvalue()
2333 int count) in xfs_attr3_leaf_moveents() argument
2344 if (count == 0) in xfs_attr3_leaf_moveents()
2353 ASSERT(ichdr_s->count > 0 && ichdr_s->count < args->geo->blksize / 8); in xfs_attr3_leaf_moveents()
2354 ASSERT(ichdr_s->firstused >= (ichdr_s->count * sizeof(*entry_s)) in xfs_attr3_leaf_moveents()
2356 ASSERT(ichdr_d->count < args->geo->blksize / 8); in xfs_attr3_leaf_moveents()
2357 ASSERT(ichdr_d->firstused >= (ichdr_d->count * sizeof(*entry_d)) in xfs_attr3_leaf_moveents()
2360 ASSERT(start_s < ichdr_s->count); in xfs_attr3_leaf_moveents()
2361 ASSERT(start_d <= ichdr_d->count); in xfs_attr3_leaf_moveents()
2362 ASSERT(count <= ichdr_s->count); in xfs_attr3_leaf_moveents()
2368 if (start_d < ichdr_d->count) { in xfs_attr3_leaf_moveents()
2369 tmp = ichdr_d->count - start_d; in xfs_attr3_leaf_moveents()
2372 entry_d = &xfs_attr3_leaf_entryp(leaf_d)[start_d + count]; in xfs_attr3_leaf_moveents()
2383 for (i = 0; i < count; entry_s++, entry_d++, desti++, i++) { in xfs_attr3_leaf_moveents()
2395 ichdr_s->count -= 1; in xfs_attr3_leaf_moveents()
2416 ichdr_s->count -= 1; in xfs_attr3_leaf_moveents()
2417 ichdr_d->count += 1; in xfs_attr3_leaf_moveents()
2418 tmp = ichdr_d->count * sizeof(xfs_attr_leaf_entry_t) in xfs_attr3_leaf_moveents()
2429 if (start_s == ichdr_s->count) { in xfs_attr3_leaf_moveents()
2430 tmp = count * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_moveents()
2440 tmp = (ichdr_s->count - count) * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_moveents()
2441 entry_s = &xfs_attr3_leaf_entryp(leaf_s)[start_s + count]; in xfs_attr3_leaf_moveents()
2445 tmp = count * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_moveents()
2446 entry_s = &xfs_attr3_leaf_entryp(leaf_s)[ichdr_s->count]; in xfs_attr3_leaf_moveents()
2456 ichdr_d->freemap[0].base += ichdr_d->count * sizeof(xfs_attr_leaf_entry_t); in xfs_attr3_leaf_moveents()
2471 int *count) in xfs_attr_leaf_lasthash() argument
2479 if (count) in xfs_attr_leaf_lasthash()
2480 *count = ichdr.count; in xfs_attr_leaf_lasthash()
2481 if (!ichdr.count) in xfs_attr_leaf_lasthash()
2483 return be32_to_cpu(entries[ichdr.count - 1].hashval); in xfs_attr_leaf_lasthash()
2572 ASSERT(args->index < ichdr.count); in xfs_attr3_leaf_clearflag()
2636 ASSERT(args->index < ichdr.count); in xfs_attr3_leaf_setflag()
2715 ASSERT(args->index < ichdr1.count); in xfs_attr3_leaf_flipflags()
2719 ASSERT(args->index2 < ichdr2.count); in xfs_attr3_leaf_flipflags()