Lines Matching defs:to_trunc
986 udf_bitmap_check_trunc_free(struct udf_bitmap *bitmap, uint32_t to_trunc)
992 DPRINTF(RESERVE, ("\ttrying to trunc %d bits from bitmap\n", to_trunc));
993 offset = bitmap->max_offset - to_trunc;
999 while (to_trunc > 0) {
1004 to_trunc--;
1469 uint64_t meta_free_lbs, data_free_lbs, to_trunc;
1501 to_trunc = meta_free_lbs/4; /* give out a quarter */
1502 to_trunc = MAX(to_trunc, num_lb);
1503 to_trunc = unit * ((to_trunc + unit-1) / unit); /* round up */
1506 if (to_trunc >= meta_free_lbs)
1511 to_trunc = udf_bitmap_check_trunc_free(bitmap, to_trunc);
1512 to_trunc = unit * (to_trunc / unit); /* round down again */
1513 if (to_trunc == 0)
1517 to_trunc));
1527 inf_len -= to_trunc/8;
1532 sbd->num_bits = udf_rw32(udf_rw32(sbd->num_bits) - to_trunc);
1533 sbd->num_bytes = udf_rw32(udf_rw32(sbd->num_bytes) - to_trunc/8);
1539 *freepos = udf_rw32(*freepos) - to_trunc;
1540 *sizepos = udf_rw32(*sizepos) - to_trunc;
1579 if (to_trunc > num_lb)
1581 return num_lb - to_trunc;