Lines Matching refs:svcn

64 	CLST svcn = le64_to_cpu(attr->nres.svcn);  in attr_load_runs()  local
69 if (svcn >= evcn + 1 || run_is_mapped_full(run, svcn, evcn)) in attr_load_runs()
72 if (vcn && (evcn < *vcn || *vcn < svcn)) in attr_load_runs()
81 err = run_unpack_ex(run, ni->mi.sbi, ni->mi.rno, svcn, evcn, in attr_load_runs()
82 vcn ? *vcn : svcn, Add2Ptr(attr, run_off), in attr_load_runs()
416 CLST alen, vcn, lcn, new_alen, old_alen, svcn, evcn; in attr_set_size() local
472 svcn = le64_to_cpu(attr_b->nres.svcn); in attr_set_size()
475 if (svcn <= vcn && vcn <= evcn) { in attr_set_size()
492 svcn = le64_to_cpu(attr->nres.svcn); in attr_set_size()
595 err = mi_pack_runs(mi, attr, run, vcn - svcn); in attr_set_size()
679 svcn = le64_to_cpu(attr->nres.svcn); in attr_set_size()
704 vcn = max(svcn, new_alen); in attr_set_size()
707 if (vcn > svcn) { in attr_set_size()
708 err = mi_pack_runs(mi, attr, run, vcn - svcn); in attr_set_size()
770 vcn = svcn - 1; in attr_set_size()
775 evcn = svcn - 1; in attr_set_size()
776 svcn = 0; in attr_set_size()
842 if (le64_to_cpu(attr_b->nres.svcn) <= svcn && in attr_set_size()
843 svcn <= le64_to_cpu(attr_b->nres.evcn)) { in attr_set_size()
853 &svcn, &mi); in attr_set_size()
859 if (mi_pack_runs(mi, attr, run, evcn - svcn + 1)) in attr_set_size()
895 CLST hint, svcn, to_alloc, evcn1, next_svcn, asize, end, vcn0, alen; in attr_data_get_block() local
955 svcn = le64_to_cpu(attr_b->nres.svcn); in attr_data_get_block()
962 if (le_b && (vcn < svcn || evcn1 <= vcn)) { in attr_data_get_block()
969 svcn = le64_to_cpu(attr->nres.svcn); in attr_data_get_block()
1031 if (vcn < svcn || evcn1 <= vcn) { in attr_data_get_block()
1094 err = mi_pack_runs(mi, attr, run, max(end, evcn1) - svcn); in attr_data_get_block()
1148 svcn = evcn1; in attr_data_get_block()
1151 attr = ni_find_attr(ni, attr, &le, ATTR_DATA, NULL, 0, &svcn, &mi); in attr_data_get_block()
1189 svcn = le64_to_cpu(attr->nres.svcn); in attr_data_get_block()
1193 if (end < svcn) in attr_data_get_block()
1194 end = svcn; in attr_data_get_block()
1201 attr->nres.svcn = cpu_to_le64(next_svcn); in attr_data_get_block()
1238 mi_pack_runs(mi, attr, run, max(end, evcn1) - svcn)) { in attr_data_get_block()
1310 CLST svcn, evcn; in attr_load_runs_vcn() local
1324 svcn = le64_to_cpu(attr->nres.svcn); in attr_load_runs_vcn()
1327 if (evcn < vcn || vcn < svcn) { in attr_load_runs_vcn()
1337 err = run_unpack_ex(run, ni->mi.sbi, ni->mi.rno, svcn, evcn, svcn, in attr_load_runs_vcn()
1639 CLST svcn, evcn1, next_svcn, len; in attr_allocate_frame() local
1654 svcn = le64_to_cpu(attr_b->nres.svcn); in attr_allocate_frame()
1658 if (svcn <= vcn && vcn < evcn1) { in attr_allocate_frame()
1673 svcn = le64_to_cpu(attr->nres.svcn); in attr_allocate_frame()
1728 err = mi_pack_runs(mi, attr, run, max(end, evcn1) - svcn); in attr_allocate_frame()
1768 svcn = evcn1; in attr_allocate_frame()
1771 attr = ni_find_attr(ni, attr, &le, ATTR_DATA, NULL, 0, &svcn, &mi); in attr_allocate_frame()
1806 svcn = le64_to_cpu(attr->nres.svcn); in attr_allocate_frame()
1810 if (end < svcn) in attr_allocate_frame()
1811 end = svcn; in attr_allocate_frame()
1818 attr->nres.svcn = cpu_to_le64(next_svcn); in attr_allocate_frame()
1865 CLST svcn, evcn1, len, dealloc, alen; in attr_collapse_range() local
1929 svcn = le64_to_cpu(attr_b->nres.svcn); in attr_collapse_range()
1932 if (svcn <= vcn && vcn < evcn1) { in attr_collapse_range()
1948 svcn = le64_to_cpu(attr->nres.svcn); in attr_collapse_range()
1953 if (svcn >= end) { in attr_collapse_range()
1955 attr->nres.svcn = cpu_to_le64(svcn - len); in attr_collapse_range()
1958 le->vcn = attr->nres.svcn; in attr_collapse_range()
1962 } else if (svcn < vcn || end < evcn1) { in attr_collapse_range()
1966 err = attr_load_runs(attr, ni, run, &svcn); in attr_collapse_range()
1969 vcn1 = max(vcn, svcn); in attr_collapse_range()
1982 if (svcn >= vcn) { in attr_collapse_range()
1984 attr->nres.svcn = cpu_to_le64(vcn); in attr_collapse_range()
1986 le->vcn = attr->nres.svcn; in attr_collapse_range()
1991 err = mi_pack_runs(mi, attr, run, evcn1 - svcn - eat); in attr_collapse_range()
2019 run_unpack_ex(RUN_DEALLOCATE, sbi, ni->mi.rno, svcn, in attr_collapse_range()
2020 evcn1 - 1, svcn, Add2Ptr(attr, roff), in attr_collapse_range()
2037 if (!svcn) { in attr_collapse_range()
2066 svcn = le64_to_cpu(attr->nres.svcn); in attr_collapse_range()
2123 CLST svcn, evcn1, vcn, len, end, alen, hole, next_svcn; in attr_punch_hole() local
2191 svcn = le64_to_cpu(attr_b->nres.svcn); in attr_punch_hole()
2195 if (svcn <= vcn && vcn < evcn1) { in attr_punch_hole()
2211 svcn = le64_to_cpu(attr->nres.svcn); in attr_punch_hole()
2215 while (svcn < end) { in attr_punch_hole()
2218 err = attr_load_runs(attr, ni, run, &svcn); in attr_punch_hole()
2221 vcn1 = max(vcn, svcn); in attr_punch_hole()
2249 err = mi_pack_runs(mi, attr, run, evcn1 - svcn); in attr_punch_hole()
2283 svcn = le64_to_cpu(attr->nres.svcn); in attr_punch_hole()
2323 if (mi_pack_runs(mi, attr, &run2, evcn1 - svcn)) in attr_punch_hole()
2341 CLST vcn, svcn, evcn1, len, next_svcn; in attr_insert_range() local
2430 svcn = le64_to_cpu(attr_b->nres.svcn); in attr_insert_range()
2433 if (svcn <= vcn && vcn < evcn1) { in attr_insert_range()
2449 svcn = le64_to_cpu(attr->nres.svcn); in attr_insert_range()
2464 err = mi_pack_runs(mi, attr, run, evcn1 + len - svcn); in attr_insert_range()
2472 le64_add_cpu(&attr->nres.svcn, len); in attr_insert_range()
2475 le->vcn = attr->nres.svcn; in attr_insert_range()
2533 svcn = le64_to_cpu(attr_b->nres.svcn); in attr_insert_range()
2536 if (svcn <= vcn && vcn < evcn1) { in attr_insert_range()
2550 svcn = le64_to_cpu(attr->nres.svcn); in attr_insert_range()
2560 if (mi_pack_runs(mi, attr, run, evcn1 + len - svcn)) in attr_insert_range()
2565 le64_sub_cpu(&attr->nres.svcn, len); in attr_insert_range()
2568 le->vcn = attr->nres.svcn; in attr_insert_range()