Lines Matching refs:count

132 	int32_t lbmask, i, l2b, l2d, error = 0, count;
159 count = length >> l2b;
162 iext->ib_prn, block, count, &dummy);
164 ASSERT(dummy <= count);
187 #define BASE(count) ((count) & ~lbmask)
188 #define CEIL(count) (((count) + lbmask) & ~lbmask)
190 #define PBASE(count) ((count) & PAGEMASK)
191 #define PCEIL(count) (((count) + PAGEOFFSET) & PAGEMASK)
207 uint64_t end_req, end_ext, mext_sz, icb_offset, count;
274 count = end_req;
288 count = PAGESIZE;
291 icb_offset, &count)) {
301 count = PBASE(off) - PCEIL(ip->i_size);
303 alloc_only, icb_offset, &count);
309 count = end_req - PBASE(off);
315 count = end_req;
322 alloc_only, icb_offset, &count)) {
544 * previous extent count if the size
558 * previous extents count
563 * reduce the count of the
579 count -= CEIL(iext->ib_count);
604 int32_t ndesc, count, lbmask;
631 count = (((ip->i_ext_used + ndesc) / EXT_PER_MALLOC) + 1) *
633 addr = kmem_zalloc(count * sizeof (struct icb_ext), KM_SLEEP);
637 ip->i_ext_count = count;
790 uint64_t count;
822 count = PCEIL(end_count) - CEIL(end_count);
823 if (count >= lbsize) {
845 alloc_only, icb_offset, &count);
857 icb_offset, &count);
867 count = PBASE(off) - PCEIL(end_count);
874 * Just bump the extent count
877 0, alloc_only, icb_offset, &count);
887 NEW_EXT, alloc_only, icb_offset, &count);
896 * round up the count in the last extent
906 count = end_req - (iext->ib_offset + iext->ib_count);
917 ALLOC_SPACE | NEW_EXT, alloc_only, icb_offset, &count);
926 ALLOC_SPACE, alloc_only, icb_offset, &count);
935 * one at index ib_count "count" and
936 * the other at index+1 with ib_count = old_ib_count - count
940 int32_t index, uint32_t count)
949 ASSERT(count < iext->ib_count);
962 iext->ib_count = count;
963 next->ib_count -= count;
1093 int32_t alloc_only, uint64_t offset, uint64_t *count)
1101 if (*count == 0) {
1122 if (*count > mext_sz) {
1125 blkcount = CEIL(*count) >> l2b;
1138 if ((sz << l2b) > *count) {
1139 iext->ib_count = *count;
1140 *count = 0;
1143 *count -= iext->ib_count;
1149 if ((iext->ib_count + *count) > mext_sz) {
1152 blkcount = CEIL(*count) >> l2b;
1169 if (acount > *count) {
1170 acount = *count;
1171 *count = 0;
1173 *count -= acount;
1203 if (*count) {
1214 if (*count > mext_sz) {
1216 *count -= iext->ib_count;
1218 iext->ib_count = *count;
1219 *count = 0;
1226 if ((iext->ib_count + *count) > mext_sz) {
1229 *count -= acount;
1231 iext->ib_count += *count;
1232 *count = 0;
1235 if (*count != 0) {