Lines Matching defs:error

258  * Returns: 0 on success, or an error code
831 int error, rgrps;
838 error = gfs2_internal_read(ip, buf, &pos,
840 if (error != sizeof(struct gfs2_rindex))
876 * Returns: 0 on success, > 0 on EOF, error code otherwise
884 int error;
890 error = gfs2_internal_read(ip, (char *)&buf, &pos,
893 if (error != sizeof(struct gfs2_rindex))
894 return (error == 0) ? 1 : error;
897 error = -ENOMEM;
899 return error;
909 error = gfs2_glock_get(sdp, rgd->rd_addr,
911 if (error)
914 error = compute_bitstructs(rgd);
915 if (error)
923 error = rgd_insert(rgd);
925 if (!error) {
930 error = 0; /* someone else read in the rgrp; free it and ignore it */
938 return error;
975 * Returns: 0 on successful update, error code otherwise
981 int error;
984 error = read_rindex_entry(ip);
985 } while (error == 0);
987 if (error < 0)
988 return error;
1014 * Returns: 0 on succeess, error code otherwise
1022 int error = 0;
1028 error = gfs2_glock_nq_init(gl, LM_ST_SHARED, 0, &ri_gh);
1029 if (error)
1030 return error;
1034 error = gfs2_ri_update(ip);
1039 return error;
1172 int error;
1179 error = gfs2_meta_read(gl, rgd->rd_addr + x, 0, 0, &bi->bi_bh);
1180 if (error)
1186 error = gfs2_meta_wait(sdp, bi->bi_bh);
1187 if (error)
1191 error = -EIO;
1213 error = -EIO;
1229 return error;
1348 fs_warn(sdp, "error %d on discard request, turning discards off for this filesystem\n", rv);
1358 * Returns: 0 on success, otherwise error code
1636 * Returns: 0 if no reservation, 1 if @rbm has changed, otherwise an error
1800 * Returns: 0 if no error
1810 int error;
1815 error = gfs2_rbm_find(&rbm, GFS2_BLKST_UNLINKED, NULL, NULL,
1817 if (error == -ENOSPC)
1819 if (WARN_ON_ONCE(error))
1831 error = gfs2_glock_get(sdp, block, &gfs2_iopen_glops, CREATE, &gl);
1832 if (error)
2012 int error = 0, rg_locked, flags = 0;
2051 error = gfs2_glock_nq_init(rs->rs_rbm.rgd->rd_gl,
2054 if (unlikely(error))
2055 return error;
2060 error = update_rgrp_lvb(rs->rs_rbm.rgd);
2061 if (unlikely(error)) {
2063 return error;
2120 error = gfs2_ri_update(ip);
2121 if (error)
2122 return error;
2255 fs_warn(sdp, "rgrp %llu has an error, marking it readonly until umount\n",
2257 fs_warn(sdp, "umount on all nodes and run fsck.gfs2 to fix the error\n");
2344 * Returns: 0 or error
2356 int error;
2359 error = gfs2_rbm_find(&rbm, GFS2_BLKST_FREE, &minext, ip, false);
2361 if (error == -ENOSPC) {
2363 error = gfs2_rbm_find(&rbm, GFS2_BLKST_FREE, &minext, NULL, false);
2367 if (error) {
2368 fs_warn(sdp, "inum=%llu error=%d, nblocks=%u, full=%d fail_pt=%d\n",
2369 (unsigned long long)ip->i_no_addr, error, *nblocks,
2386 error = gfs2_meta_inode_buffer(ip, &dibh);
2387 if (error == 0) {
2528 int error = -EINVAL;
2534 error = gfs2_glock_nq_init(rgd->rd_gl, LM_ST_SHARED, 0, &rgd_gh);
2535 if (error)
2539 error = gfs2_rbm_from_block(&rbm, no_addr);
2540 if (!WARN_ON_ONCE(error)) {
2542 error = -ESTALE;
2548 return error;