Lines Matching refs:error
175 int error;
177 error = xfs_btree_get_rec(cur, &rec, stat);
178 if (error || !*stat)
179 return error;
193 * This either works (return 0) or gets an EFSCORRUPTED error.
202 int error;
212 error = xfs_btree_update(cur, &rec);
213 if (error)
215 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
216 return error;
222 * This either works (return 0) or gets an EFSCORRUPTED error.
230 int error;
239 error = xfs_btree_insert(cur, i);
240 if (error)
243 error = -EFSCORRUPTED;
248 if (error)
250 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
251 return error;
258 * This either works (return 0) or gets an EFSCORRUPTED error.
267 int error;
269 error = xfs_refcount_get_rec(cur, &irec, &found_rec);
270 if (error)
273 error = -EFSCORRUPTED;
277 error = xfs_btree_delete(cur, i);
279 error = -EFSCORRUPTED;
282 if (error)
284 error = xfs_refcount_lookup_ge(cur, irec.rc_domain, irec.rc_startblock,
287 if (error)
289 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
290 return error;
390 int error;
393 error = xfs_refcount_lookup_le(cur, domain, agbno, &found_rec);
394 if (error)
399 error = xfs_refcount_get_rec(cur, &rcext, &found_rec);
400 if (error)
403 error = -EFSCORRUPTED;
419 error = xfs_refcount_update(cur, &tmp);
420 if (error)
426 error = xfs_refcount_insert(cur, &tmp, &found_rec);
427 if (error)
430 error = -EFSCORRUPTED;
433 return error;
437 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
438 return error;
453 int error;
470 error = xfs_refcount_lookup_ge(cur, center->rc_domain,
472 if (error)
475 error = -EFSCORRUPTED;
479 error = xfs_refcount_delete(cur, &found_rec);
480 if (error)
483 error = -EFSCORRUPTED;
488 error = xfs_refcount_delete(cur, &found_rec);
489 if (error)
492 error = -EFSCORRUPTED;
498 error = xfs_refcount_lookup_le(cur, left->rc_domain,
500 if (error)
503 error = -EFSCORRUPTED;
508 error = xfs_refcount_update(cur, left);
509 if (error)
513 return error;
517 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
518 return error;
532 int error;
542 error = xfs_refcount_lookup_le(cur, cleft->rc_domain,
544 if (error)
547 error = -EFSCORRUPTED;
551 error = xfs_refcount_delete(cur, &found_rec);
552 if (error)
555 error = -EFSCORRUPTED;
561 error = xfs_refcount_lookup_le(cur, left->rc_domain,
563 if (error)
566 error = -EFSCORRUPTED;
571 error = xfs_refcount_update(cur, left);
572 if (error)
577 return error;
581 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
582 return error;
595 int error;
608 error = xfs_refcount_lookup_le(cur, cright->rc_domain,
610 if (error)
613 error = -EFSCORRUPTED;
617 error = xfs_refcount_delete(cur, &found_rec);
618 if (error)
621 error = -EFSCORRUPTED;
627 error = xfs_refcount_lookup_le(cur, right->rc_domain,
629 if (error)
632 error = -EFSCORRUPTED;
638 error = xfs_refcount_update(cur, right);
639 if (error)
643 return error;
647 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
648 return error;
665 int error;
669 error = xfs_refcount_lookup_le(cur, domain, agbno - 1, &found_rec);
670 if (error)
675 error = xfs_refcount_get_rec(cur, &tmp, &found_rec);
676 if (error)
679 error = -EFSCORRUPTED;
690 error = xfs_btree_increment(cur, 0, &found_rec);
691 if (error)
694 error = xfs_refcount_get_rec(cur, &tmp, &found_rec);
695 if (error)
698 error = -EFSCORRUPTED;
736 return error;
740 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
741 return error;
758 int error;
762 error = xfs_refcount_lookup_ge(cur, domain, agbno + aglen, &found_rec);
763 if (error)
768 error = xfs_refcount_get_rec(cur, &tmp, &found_rec);
769 if (error)
772 error = -EFSCORRUPTED;
783 error = xfs_btree_decrement(cur, 0, &found_rec);
784 if (error)
787 error = xfs_refcount_get_rec(cur, &tmp, &found_rec);
788 if (error)
791 error = -EFSCORRUPTED;
829 return error;
833 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
834 return error;
984 int error;
994 error = xfs_refcount_find_left_extents(cur, &left, &cleft, domain,
996 if (error)
997 return error;
998 error = xfs_refcount_find_right_extents(cur, &right, &cright, domain,
1000 if (error)
1001 return error;
1021 error = xfs_refcount_merge_left_extent(cur, &left, &cleft,
1023 if (error)
1024 return error;
1067 * refcount continue update "error" has been injected.
1096 int error;
1104 error = xfs_refcount_lookup_ge(cur, XFS_REFC_DOMAIN_SHARED, *agbno,
1106 if (error)
1110 error = xfs_refcount_get_rec(cur, &ext, &found_rec);
1111 if (error)
1141 error = xfs_refcount_insert(cur, &tmp,
1143 if (error)
1147 error = -EFSCORRUPTED;
1154 error = xfs_free_extent_later(cur->bc_tp, fsbno,
1157 if (error)
1169 error = xfs_refcount_lookup_ge(cur,
1172 if (error)
1185 error = -EFSCORRUPTED;
1200 error = xfs_refcount_update(cur, &ext);
1201 if (error)
1204 error = xfs_refcount_delete(cur, &found_rec);
1205 if (error)
1208 error = -EFSCORRUPTED;
1216 error = xfs_free_extent_later(cur->bc_tp, fsbno,
1219 if (error)
1224 error = xfs_btree_increment(cur, 0, &found_rec);
1225 if (error)
1233 return error;
1236 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
1237 return error;
1250 int error;
1262 error = xfs_refcount_split_extent(cur, XFS_REFC_DOMAIN_SHARED,
1264 if (error)
1269 error = xfs_refcount_split_extent(cur, XFS_REFC_DOMAIN_SHARED,
1271 if (error)
1279 error = xfs_refcount_merge_extents(cur, XFS_REFC_DOMAIN_SHARED,
1281 if (error)
1289 error = xfs_refcount_adjust_extents(cur, agbno, aglen, adj);
1290 if (error)
1297 error, _RET_IP_);
1298 return error;
1306 int error)
1313 xfs_btree_del_cursor(rcur, error);
1314 if (error)
1359 int error = 0;
1386 error = xfs_alloc_read_agf(ri->ri_pag, tp,
1388 if (error)
1389 return error;
1399 error = xfs_refcount_adjust(rcur, &bno, &ri->ri_blockcount,
1401 if (error)
1402 return error;
1404 error = xfs_refcount_continue_op(rcur, ri, bno);
1407 error = xfs_refcount_adjust(rcur, &bno, &ri->ri_blockcount,
1409 if (error)
1410 return error;
1412 error = xfs_refcount_continue_op(rcur, ri, bno);
1415 error = __xfs_refcount_cow_alloc(rcur, bno, ri->ri_blockcount);
1416 if (error)
1417 return error;
1421 error = __xfs_refcount_cow_free(rcur, bno, ri->ri_blockcount);
1422 if (error)
1423 return error;
1430 if (!error && ri->ri_blockcount > 0)
1433 return error;
1514 int error;
1524 error = xfs_refcount_lookup_le(cur, XFS_REFC_DOMAIN_SHARED, agbno,
1526 if (error)
1530 error = xfs_btree_increment(cur, 0, &have);
1531 if (error)
1536 error = xfs_refcount_get_rec(cur, &tmp, &i);
1537 if (error)
1540 error = -EFSCORRUPTED;
1548 error = xfs_btree_increment(cur, 0, &have);
1549 if (error)
1553 error = xfs_refcount_get_rec(cur, &tmp, &i);
1554 if (error)
1557 error = -EFSCORRUPTED;
1581 error = xfs_btree_increment(cur, 0, &have);
1582 if (error)
1586 error = xfs_refcount_get_rec(cur, &tmp, &i);
1587 if (error)
1590 error = -EFSCORRUPTED;
1605 if (error)
1607 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
1608 return error;
1671 int error;
1678 error = xfs_refcount_lookup_ge(cur, XFS_REFC_DOMAIN_COW, agbno,
1680 if (error)
1682 error = xfs_refcount_get_rec(cur, &ext, &found_rec);
1683 if (error)
1687 error = -EFSCORRUPTED;
1702 error = -EFSCORRUPTED;
1714 error = xfs_refcount_insert(cur, &tmp,
1716 if (error)
1719 error = -EFSCORRUPTED;
1726 error = -EFSCORRUPTED;
1730 error = -EFSCORRUPTED;
1734 error = -EFSCORRUPTED;
1741 error = xfs_refcount_delete(cur, &found_rec);
1742 if (error)
1745 error = -EFSCORRUPTED;
1753 return error;
1756 cur->bc_ag.pag->pag_agno, error, _RET_IP_);
1757 return error;
1771 int error;
1776 error = xfs_refcount_split_extent(cur, XFS_REFC_DOMAIN_COW,
1778 if (error)
1781 error = xfs_refcount_split_extent(cur, XFS_REFC_DOMAIN_COW,
1783 if (error)
1789 error = xfs_refcount_merge_extents(cur, XFS_REFC_DOMAIN_COW, &agbno,
1791 if (error)
1795 error = xfs_refcount_adjust_cow_extents(cur, agbno, aglen, adj);
1796 if (error)
1803 error, _RET_IP_);
1804 return error;
1932 int error;
1951 error = xfs_trans_alloc_empty(mp, &tp);
1952 if (error)
1953 return error;
1955 error = xfs_alloc_read_agf(pag, tp, 0, &agbp);
1956 if (error)
1961 error = xfs_btree_query_range(cur, &low, &high,
1963 xfs_btree_del_cursor(cur, error);
1966 if (error)
1972 error = xfs_trans_alloc(mp, &M_RES(mp)->tr_write, 0, 0, 0, &tp);
1973 if (error)
1986 error = xfs_free_extent_later(tp, fsb,
1989 if (error)
1992 error = xfs_trans_commit(tp);
1993 if (error)
2000 return error;
2009 return error;