Lines Matching full:error

46 	int			error;  in xfs_rmap_lookup_le()  local
54 error = xfs_btree_lookup(cur, XFS_LOOKUP_LE, stat); in xfs_rmap_lookup_le()
55 if (error || !(*stat) || !irec) in xfs_rmap_lookup_le()
56 return error; in xfs_rmap_lookup_le()
58 error = xfs_rmap_get_rec(cur, irec, &get_stat); in xfs_rmap_lookup_le()
59 if (error) in xfs_rmap_lookup_le()
60 return error; in xfs_rmap_lookup_le()
94 * This either works (return 0) or gets an EFSCORRUPTED error.
102 int error; in xfs_rmap_update() local
112 error = xfs_btree_update(cur, &rec); in xfs_rmap_update()
113 if (error) in xfs_rmap_update()
114 trace_xfs_rmap_update_error(cur, error, _RET_IP_); in xfs_rmap_update()
115 return error; in xfs_rmap_update()
128 int error; in xfs_rmap_insert() local
132 error = xfs_rmap_lookup_eq(rcur, agbno, len, owner, offset, flags, &i); in xfs_rmap_insert()
133 if (error) in xfs_rmap_insert()
137 error = -EFSCORRUPTED; in xfs_rmap_insert()
146 error = xfs_btree_insert(rcur, &i); in xfs_rmap_insert()
147 if (error) in xfs_rmap_insert()
151 error = -EFSCORRUPTED; in xfs_rmap_insert()
155 if (error) in xfs_rmap_insert()
156 trace_xfs_rmap_insert_error(rcur, error, _RET_IP_); in xfs_rmap_insert()
157 return error; in xfs_rmap_insert()
170 int error; in xfs_rmap_delete() local
174 error = xfs_rmap_lookup_eq(rcur, agbno, len, owner, offset, flags, &i); in xfs_rmap_delete()
175 if (error) in xfs_rmap_delete()
179 error = -EFSCORRUPTED; in xfs_rmap_delete()
183 error = xfs_btree_delete(rcur, &i); in xfs_rmap_delete()
184 if (error) in xfs_rmap_delete()
188 error = -EFSCORRUPTED; in xfs_rmap_delete()
192 if (error) in xfs_rmap_delete()
193 trace_xfs_rmap_delete_error(rcur, error, _RET_IP_); in xfs_rmap_delete()
194 return error; in xfs_rmap_delete()
311 int error; in xfs_rmap_get_rec() local
313 error = xfs_btree_get_rec(cur, &rec, stat); in xfs_rmap_get_rec()
314 if (error || !*stat) in xfs_rmap_get_rec()
315 return error; in xfs_rmap_get_rec()
372 int error; in xfs_rmap_find_left_neighbor() local
409 error = xfs_rmap_lookup_le(cur, bno, owner, offset, flags, irec, in xfs_rmap_find_left_neighbor()
411 if (error) in xfs_rmap_find_left_neighbor()
412 return error; in xfs_rmap_find_left_neighbor()
414 error = xfs_rmap_find_left_neighbor_helper(cur, irec, &info); in xfs_rmap_find_left_neighbor()
415 if (!error) in xfs_rmap_find_left_neighbor()
416 error = xfs_rmap_query_range(cur, &info.high, &info.high, in xfs_rmap_find_left_neighbor()
418 if (error != -ECANCELED) in xfs_rmap_find_left_neighbor()
419 return error; in xfs_rmap_find_left_neighbor()
471 int error; in xfs_rmap_lookup_le_range() local
502 error = xfs_rmap_lookup_le(cur, bno, owner, offset, flags, irec, in xfs_rmap_lookup_le_range()
504 if (error) in xfs_rmap_lookup_le_range()
505 return error; in xfs_rmap_lookup_le_range()
507 error = xfs_rmap_lookup_le_range_helper(cur, irec, &info); in xfs_rmap_lookup_le_range()
508 if (!error) in xfs_rmap_lookup_le_range()
509 error = xfs_rmap_query_range(cur, &info.high, &info.high, in xfs_rmap_lookup_le_range()
511 if (error != -ECANCELED) in xfs_rmap_lookup_le_range()
512 return error; in xfs_rmap_lookup_le_range()
536 int error = 0; in xfs_rmap_free_check_owner() local
546 error = -EFSCORRUPTED; in xfs_rmap_free_check_owner()
553 error = -EFSCORRUPTED; in xfs_rmap_free_check_owner()
565 error = -EFSCORRUPTED; in xfs_rmap_free_check_owner()
571 error = -EFSCORRUPTED; in xfs_rmap_free_check_owner()
577 error = -EFSCORRUPTED; in xfs_rmap_free_check_owner()
583 return error; in xfs_rmap_free_check_owner()
615 int error = 0; in xfs_rmap_unmap() local
634 error = xfs_rmap_lookup_le(cur, bno, owner, offset, flags, &ltrec, &i); in xfs_rmap_unmap()
635 if (error) in xfs_rmap_unmap()
639 error = -EFSCORRUPTED; in xfs_rmap_unmap()
660 error = -EFSCORRUPTED; in xfs_rmap_unmap()
677 error = xfs_btree_increment(cur, 0, &i); in xfs_rmap_unmap()
678 if (error) in xfs_rmap_unmap()
682 error = xfs_rmap_get_rec(cur, &rtrec, &i); in xfs_rmap_unmap()
683 if (error) in xfs_rmap_unmap()
687 error = -EFSCORRUPTED; in xfs_rmap_unmap()
700 error = -EFSCORRUPTED; in xfs_rmap_unmap()
705 error = xfs_rmap_free_check_owner(cur, ltoff, &ltrec, len, owner, in xfs_rmap_unmap()
707 if (error) in xfs_rmap_unmap()
715 error = xfs_btree_delete(cur, &i); in xfs_rmap_unmap()
716 if (error) in xfs_rmap_unmap()
720 error = -EFSCORRUPTED; in xfs_rmap_unmap()
738 error = xfs_rmap_update(cur, &ltrec); in xfs_rmap_unmap()
739 if (error) in xfs_rmap_unmap()
753 error = xfs_rmap_update(cur, &ltrec); in xfs_rmap_unmap()
754 if (error) in xfs_rmap_unmap()
773 error = xfs_rmap_update(cur, &ltrec); in xfs_rmap_unmap()
774 if (error) in xfs_rmap_unmap()
777 error = xfs_btree_increment(cur, 0, &i); in xfs_rmap_unmap()
778 if (error) in xfs_rmap_unmap()
795 error = xfs_btree_insert(cur, &i); in xfs_rmap_unmap()
796 if (error) in xfs_rmap_unmap()
803 if (error) in xfs_rmap_unmap()
804 trace_xfs_rmap_unmap_error(cur, error, _RET_IP_); in xfs_rmap_unmap()
805 return error; in xfs_rmap_unmap()
902 int error; in xfs_rmap_free() local
909 error = xfs_rmap_unmap(cur, bno, len, false, oinfo); in xfs_rmap_free()
911 xfs_btree_del_cursor(cur, error); in xfs_rmap_free()
912 return error; in xfs_rmap_free()
961 int error = 0; in xfs_rmap_map() local
982 error = xfs_rmap_lookup_le(cur, bno, owner, offset, flags, &ltrec, in xfs_rmap_map()
984 if (error) in xfs_rmap_map()
999 error = -EFSCORRUPTED; in xfs_rmap_map()
1008 error = xfs_btree_increment(cur, 0, &have_gt); in xfs_rmap_map()
1009 if (error) in xfs_rmap_map()
1012 error = xfs_rmap_get_rec(cur, &gtrec, &have_gt); in xfs_rmap_map()
1013 if (error) in xfs_rmap_map()
1017 error = -EFSCORRUPTED; in xfs_rmap_map()
1022 error = -EFSCORRUPTED; in xfs_rmap_map()
1068 error = xfs_btree_delete(cur, &i); in xfs_rmap_map()
1069 if (error) in xfs_rmap_map()
1073 error = -EFSCORRUPTED; in xfs_rmap_map()
1079 error = xfs_btree_decrement(cur, 0, &have_gt); in xfs_rmap_map()
1080 if (error) in xfs_rmap_map()
1082 error = xfs_rmap_update(cur, &ltrec); in xfs_rmap_map()
1083 if (error) in xfs_rmap_map()
1101 error = xfs_rmap_update(cur, &gtrec); in xfs_rmap_map()
1102 if (error) in xfs_rmap_map()
1115 error = xfs_btree_insert(cur, &i); in xfs_rmap_map()
1116 if (error) in xfs_rmap_map()
1120 error = -EFSCORRUPTED; in xfs_rmap_map()
1127 if (error) in xfs_rmap_map()
1128 trace_xfs_rmap_map_error(cur, error, _RET_IP_); in xfs_rmap_map()
1129 return error; in xfs_rmap_map()
1146 int error; in xfs_rmap_alloc() local
1153 error = xfs_rmap_map(cur, bno, len, false, oinfo); in xfs_rmap_alloc()
1155 xfs_btree_del_cursor(cur, error); in xfs_rmap_alloc()
1156 return error; in xfs_rmap_alloc()
1195 int error; in xfs_rmap_convert() local
1209 error = xfs_rmap_lookup_le(cur, bno, owner, offset, oldext, &PREV, &i); in xfs_rmap_convert()
1210 if (error) in xfs_rmap_convert()
1214 error = -EFSCORRUPTED; in xfs_rmap_convert()
1241 error = xfs_btree_decrement(cur, 0, &i); in xfs_rmap_convert()
1242 if (error) in xfs_rmap_convert()
1246 error = xfs_rmap_get_rec(cur, &LEFT, &i); in xfs_rmap_convert()
1247 if (error) in xfs_rmap_convert()
1251 error = -EFSCORRUPTED; in xfs_rmap_convert()
1258 error = -EFSCORRUPTED; in xfs_rmap_convert()
1275 error = xfs_btree_increment(cur, 0, &i); in xfs_rmap_convert()
1276 if (error) in xfs_rmap_convert()
1280 error = -EFSCORRUPTED; in xfs_rmap_convert()
1283 error = xfs_btree_increment(cur, 0, &i); in xfs_rmap_convert()
1284 if (error) in xfs_rmap_convert()
1288 error = xfs_rmap_get_rec(cur, &RIGHT, &i); in xfs_rmap_convert()
1289 if (error) in xfs_rmap_convert()
1293 error = -EFSCORRUPTED; in xfs_rmap_convert()
1298 error = -EFSCORRUPTED; in xfs_rmap_convert()
1323 error = xfs_rmap_lookup_le(cur, bno, owner, offset, oldext, NULL, &i); in xfs_rmap_convert()
1324 if (error) in xfs_rmap_convert()
1328 error = -EFSCORRUPTED; in xfs_rmap_convert()
1343 error = xfs_btree_increment(cur, 0, &i); in xfs_rmap_convert()
1344 if (error) in xfs_rmap_convert()
1348 error = -EFSCORRUPTED; in xfs_rmap_convert()
1354 error = xfs_btree_delete(cur, &i); in xfs_rmap_convert()
1355 if (error) in xfs_rmap_convert()
1359 error = -EFSCORRUPTED; in xfs_rmap_convert()
1362 error = xfs_btree_decrement(cur, 0, &i); in xfs_rmap_convert()
1363 if (error) in xfs_rmap_convert()
1367 error = -EFSCORRUPTED; in xfs_rmap_convert()
1373 error = xfs_btree_delete(cur, &i); in xfs_rmap_convert()
1374 if (error) in xfs_rmap_convert()
1378 error = -EFSCORRUPTED; in xfs_rmap_convert()
1381 error = xfs_btree_decrement(cur, 0, &i); in xfs_rmap_convert()
1382 if (error) in xfs_rmap_convert()
1386 error = -EFSCORRUPTED; in xfs_rmap_convert()
1391 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1392 if (error) in xfs_rmap_convert()
1404 error = xfs_btree_delete(cur, &i); in xfs_rmap_convert()
1405 if (error) in xfs_rmap_convert()
1409 error = -EFSCORRUPTED; in xfs_rmap_convert()
1412 error = xfs_btree_decrement(cur, 0, &i); in xfs_rmap_convert()
1413 if (error) in xfs_rmap_convert()
1417 error = -EFSCORRUPTED; in xfs_rmap_convert()
1422 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1423 if (error) in xfs_rmap_convert()
1432 error = xfs_btree_increment(cur, 0, &i); in xfs_rmap_convert()
1433 if (error) in xfs_rmap_convert()
1437 error = -EFSCORRUPTED; in xfs_rmap_convert()
1443 error = xfs_btree_delete(cur, &i); in xfs_rmap_convert()
1444 if (error) in xfs_rmap_convert()
1448 error = -EFSCORRUPTED; in xfs_rmap_convert()
1451 error = xfs_btree_decrement(cur, 0, &i); in xfs_rmap_convert()
1452 if (error) in xfs_rmap_convert()
1456 error = -EFSCORRUPTED; in xfs_rmap_convert()
1462 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1463 if (error) in xfs_rmap_convert()
1475 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1476 if (error) in xfs_rmap_convert()
1489 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1490 if (error) in xfs_rmap_convert()
1492 error = xfs_btree_decrement(cur, 0, &i); in xfs_rmap_convert()
1493 if (error) in xfs_rmap_convert()
1497 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1498 if (error) in xfs_rmap_convert()
1511 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1512 if (error) in xfs_rmap_convert()
1521 error = xfs_btree_insert(cur, &i); in xfs_rmap_convert()
1522 if (error) in xfs_rmap_convert()
1526 error = -EFSCORRUPTED; in xfs_rmap_convert()
1538 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1539 if (error) in xfs_rmap_convert()
1541 error = xfs_btree_increment(cur, 0, &i); in xfs_rmap_convert()
1542 if (error) in xfs_rmap_convert()
1548 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1549 if (error) in xfs_rmap_convert()
1560 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1561 if (error) in xfs_rmap_convert()
1563 error = xfs_rmap_lookup_eq(cur, bno, len, owner, offset, in xfs_rmap_convert()
1565 if (error) in xfs_rmap_convert()
1569 error = -EFSCORRUPTED; in xfs_rmap_convert()
1579 error = xfs_btree_insert(cur, &i); in xfs_rmap_convert()
1580 if (error) in xfs_rmap_convert()
1584 error = -EFSCORRUPTED; in xfs_rmap_convert()
1602 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert()
1603 if (error) in xfs_rmap_convert()
1612 error = xfs_btree_insert(cur, &i); in xfs_rmap_convert()
1613 if (error) in xfs_rmap_convert()
1617 error = -EFSCORRUPTED; in xfs_rmap_convert()
1625 error = xfs_rmap_lookup_eq(cur, bno, len, owner, offset, in xfs_rmap_convert()
1627 if (error) in xfs_rmap_convert()
1631 error = -EFSCORRUPTED; in xfs_rmap_convert()
1638 error = xfs_btree_insert(cur, &i); in xfs_rmap_convert()
1639 if (error) in xfs_rmap_convert()
1643 error = -EFSCORRUPTED; in xfs_rmap_convert()
1663 if (error) in xfs_rmap_convert()
1664 trace_xfs_rmap_convert_error(cur, error, _RET_IP_); in xfs_rmap_convert()
1665 return error; in xfs_rmap_convert()
1693 int error; in xfs_rmap_convert_shared() local
1707 error = xfs_rmap_lookup_le_range(cur, bno, owner, offset, oldext, in xfs_rmap_convert_shared()
1709 if (error) in xfs_rmap_convert_shared()
1713 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1732 error = xfs_rmap_find_left_neighbor(cur, bno, owner, offset, newext, in xfs_rmap_convert_shared()
1734 if (error) in xfs_rmap_convert_shared()
1742 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1750 error = xfs_rmap_lookup_eq(cur, bno + len, len, owner, offset + len, in xfs_rmap_convert_shared()
1752 if (error) in xfs_rmap_convert_shared()
1756 error = xfs_rmap_get_rec(cur, &RIGHT, &i); in xfs_rmap_convert_shared()
1757 if (error) in xfs_rmap_convert_shared()
1761 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1766 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1798 error = xfs_rmap_delete(cur, RIGHT.rm_startblock, in xfs_rmap_convert_shared()
1801 if (error) in xfs_rmap_convert_shared()
1803 error = xfs_rmap_delete(cur, PREV.rm_startblock, in xfs_rmap_convert_shared()
1806 if (error) in xfs_rmap_convert_shared()
1809 error = xfs_rmap_lookup_eq(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1812 if (error) in xfs_rmap_convert_shared()
1816 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1820 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert_shared()
1821 if (error) in xfs_rmap_convert_shared()
1830 error = xfs_rmap_delete(cur, PREV.rm_startblock, in xfs_rmap_convert_shared()
1833 if (error) in xfs_rmap_convert_shared()
1836 error = xfs_rmap_lookup_eq(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1839 if (error) in xfs_rmap_convert_shared()
1843 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1847 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert_shared()
1848 if (error) in xfs_rmap_convert_shared()
1857 error = xfs_rmap_delete(cur, RIGHT.rm_startblock, in xfs_rmap_convert_shared()
1860 if (error) in xfs_rmap_convert_shared()
1863 error = xfs_rmap_lookup_eq(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1866 if (error) in xfs_rmap_convert_shared()
1870 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1875 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert_shared()
1876 if (error) in xfs_rmap_convert_shared()
1887 error = xfs_rmap_lookup_eq(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1890 if (error) in xfs_rmap_convert_shared()
1894 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1898 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert_shared()
1899 if (error) in xfs_rmap_convert_shared()
1909 error = xfs_rmap_delete(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1912 if (error) in xfs_rmap_convert_shared()
1917 error = xfs_rmap_insert(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1920 if (error) in xfs_rmap_convert_shared()
1923 error = xfs_rmap_lookup_eq(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1926 if (error) in xfs_rmap_convert_shared()
1930 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1934 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert_shared()
1935 if (error) in xfs_rmap_convert_shared()
1945 error = xfs_rmap_delete(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1948 if (error) in xfs_rmap_convert_shared()
1953 error = xfs_rmap_insert(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1956 if (error) in xfs_rmap_convert_shared()
1958 error = xfs_rmap_insert(cur, bno, len, owner, offset, newext); in xfs_rmap_convert_shared()
1959 if (error) in xfs_rmap_convert_shared()
1969 error = xfs_rmap_lookup_eq(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1972 if (error) in xfs_rmap_convert_shared()
1976 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
1980 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert_shared()
1981 if (error) in xfs_rmap_convert_shared()
1984 error = xfs_rmap_delete(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1987 if (error) in xfs_rmap_convert_shared()
1992 error = xfs_rmap_insert(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
1995 if (error) in xfs_rmap_convert_shared()
2005 error = xfs_rmap_lookup_eq(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
2008 if (error) in xfs_rmap_convert_shared()
2012 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
2016 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert_shared()
2017 if (error) in xfs_rmap_convert_shared()
2019 error = xfs_rmap_insert(cur, bno, len, owner, offset, newext); in xfs_rmap_convert_shared()
2020 if (error) in xfs_rmap_convert_shared()
2037 error = xfs_rmap_insert(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
2040 if (error) in xfs_rmap_convert_shared()
2044 error = xfs_rmap_lookup_eq(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
2047 if (error) in xfs_rmap_convert_shared()
2051 error = -EFSCORRUPTED; in xfs_rmap_convert_shared()
2055 error = xfs_rmap_update(cur, &NEW); in xfs_rmap_convert_shared()
2056 if (error) in xfs_rmap_convert_shared()
2064 error = xfs_rmap_insert(cur, NEW.rm_startblock, in xfs_rmap_convert_shared()
2067 if (error) in xfs_rmap_convert_shared()
2086 if (error) in xfs_rmap_convert_shared()
2087 trace_xfs_rmap_convert_error(cur, error, _RET_IP_); in xfs_rmap_convert_shared()
2088 return error; in xfs_rmap_convert_shared()
2116 int error = 0; in xfs_rmap_unmap_shared() local
2132 error = xfs_rmap_lookup_le_range(cur, bno, owner, offset, flags, in xfs_rmap_unmap_shared()
2134 if (error) in xfs_rmap_unmap_shared()
2138 error = -EFSCORRUPTED; in xfs_rmap_unmap_shared()
2149 error = -EFSCORRUPTED; in xfs_rmap_unmap_shared()
2156 error = -EFSCORRUPTED; in xfs_rmap_unmap_shared()
2165 error = -EFSCORRUPTED; in xfs_rmap_unmap_shared()
2172 error = -EFSCORRUPTED; in xfs_rmap_unmap_shared()
2177 error = -EFSCORRUPTED; in xfs_rmap_unmap_shared()
2183 error = xfs_rmap_delete(cur, ltrec.rm_startblock, in xfs_rmap_unmap_shared()
2186 if (error) in xfs_rmap_unmap_shared()
2201 error = xfs_rmap_delete(cur, ltrec.rm_startblock, in xfs_rmap_unmap_shared()
2204 if (error) in xfs_rmap_unmap_shared()
2211 error = xfs_rmap_insert(cur, ltrec.rm_startblock, in xfs_rmap_unmap_shared()
2214 if (error) in xfs_rmap_unmap_shared()
2227 error = xfs_rmap_lookup_eq(cur, ltrec.rm_startblock, in xfs_rmap_unmap_shared()
2230 if (error) in xfs_rmap_unmap_shared()
2234 error = -EFSCORRUPTED; in xfs_rmap_unmap_shared()
2238 error = xfs_rmap_update(cur, &ltrec); in xfs_rmap_unmap_shared()
2239 if (error) in xfs_rmap_unmap_shared()
2257 error = xfs_rmap_lookup_eq(cur, ltrec.rm_startblock, in xfs_rmap_unmap_shared()
2260 if (error) in xfs_rmap_unmap_shared()
2264 error = -EFSCORRUPTED; in xfs_rmap_unmap_shared()
2268 error = xfs_rmap_update(cur, &ltrec); in xfs_rmap_unmap_shared()
2269 if (error) in xfs_rmap_unmap_shared()
2273 error = xfs_rmap_insert(cur, bno + len, in xfs_rmap_unmap_shared()
2277 if (error) in xfs_rmap_unmap_shared()
2283 if (error) in xfs_rmap_unmap_shared()
2284 trace_xfs_rmap_unmap_error(cur, error, _RET_IP_); in xfs_rmap_unmap_shared()
2285 return error; in xfs_rmap_unmap_shared()
2310 int error = 0; in xfs_rmap_map_shared() local
2322 error = xfs_rmap_find_left_neighbor(cur, bno, owner, offset, flags, in xfs_rmap_map_shared()
2324 if (error) in xfs_rmap_map_shared()
2331 error = xfs_rmap_lookup_eq(cur, bno + len, len, owner, offset + len, in xfs_rmap_map_shared()
2333 if (error) in xfs_rmap_map_shared()
2336 error = xfs_rmap_get_rec(cur, &gtrec, &have_gt); in xfs_rmap_map_shared()
2337 if (error) in xfs_rmap_map_shared()
2341 error = -EFSCORRUPTED; in xfs_rmap_map_shared()
2379 error = xfs_rmap_delete(cur, gtrec.rm_startblock, in xfs_rmap_map_shared()
2382 if (error) in xfs_rmap_map_shared()
2387 error = xfs_rmap_lookup_eq(cur, ltrec.rm_startblock, in xfs_rmap_map_shared()
2390 if (error) in xfs_rmap_map_shared()
2394 error = -EFSCORRUPTED; in xfs_rmap_map_shared()
2398 error = xfs_rmap_update(cur, &ltrec); in xfs_rmap_map_shared()
2399 if (error) in xfs_rmap_map_shared()
2414 error = xfs_rmap_delete(cur, gtrec.rm_startblock, in xfs_rmap_map_shared()
2417 if (error) in xfs_rmap_map_shared()
2424 error = xfs_rmap_insert(cur, gtrec.rm_startblock, in xfs_rmap_map_shared()
2427 if (error) in xfs_rmap_map_shared()
2434 error = xfs_rmap_insert(cur, bno, len, owner, offset, flags); in xfs_rmap_map_shared()
2435 if (error) in xfs_rmap_map_shared()
2441 if (error) in xfs_rmap_map_shared()
2442 trace_xfs_rmap_map_error(cur, error, _RET_IP_); in xfs_rmap_map_shared()
2443 return error; in xfs_rmap_map_shared()
2578 int error = 0; in xfs_rmap_finish_one() local
2600 error = xfs_free_extent_fix_freelist(tp, ri->ri_pag, &agbp); in xfs_rmap_finish_one()
2601 if (error) { in xfs_rmap_finish_one()
2603 return error; in xfs_rmap_finish_one()
2618 error = __xfs_rmap_finish_intent(rcur, ri->ri_type, bno, in xfs_rmap_finish_one()
2620 if (error) in xfs_rmap_finish_one()
2621 return error; in xfs_rmap_finish_one()
2943 int error; in xfs_rmap_count_owners() local
2946 error = xfs_rmap_query_range(cur, &roc.low, &roc.high, in xfs_rmap_count_owners()
2948 if (error) in xfs_rmap_count_owners()
2949 return error; in xfs_rmap_count_owners()
2975 int error; in xfs_rmap_has_other_keys() local
2980 error = xfs_rmap_query_range(cur, &roc.low, &roc.high, in xfs_rmap_has_other_keys()
2982 if (error == -ECANCELED) { in xfs_rmap_has_other_keys()
2986 if (error) in xfs_rmap_has_other_keys()
2987 return error; in xfs_rmap_has_other_keys()