diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2022-11-19 22:39:08 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:09:48 -0400 |
commit | 78c0b75c34209c471616566b3978eac4c1c53e99 (patch) | |
tree | e5c64b4d5d643e6170f2acfff1f279333235b398 /fs/bcachefs/reflink.c | |
parent | 5f659376fc1b9ad23b00a35242179b8961e0bc2d (diff) |
bcachefs: More errcode cleanup
We shouldn't be overloading standard error codes now that we have
provisions for bcachefs-specific errorcodes: this patch converts super.c
and super-io.c to per error site errcodes, with a bit of cleanup.
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/reflink.c')
-rw-r--r-- | fs/bcachefs/reflink.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/fs/bcachefs/reflink.c b/fs/bcachefs/reflink.c index aebed671c43a..8c426d6440c9 100644 --- a/fs/bcachefs/reflink.c +++ b/fs/bcachefs/reflink.c @@ -85,7 +85,7 @@ int bch2_reflink_v_invalid(const struct bch_fs *c, struct bkey_s_c k, if (bkey_val_bytes(r.k) < sizeof(*r.v)) { prt_printf(err, "incorrect value size (%zu < %zu)", bkey_val_bytes(r.k), sizeof(*r.v)); - return -EINVAL; + return -BCH_ERR_invalid_bkey; } return bch2_bkey_ptrs_invalid(c, k, rw, err); @@ -136,7 +136,7 @@ int bch2_indirect_inline_data_invalid(const struct bch_fs *c, struct bkey_s_c k, if (bkey_val_bytes(k.k) < sizeof(struct bch_indirect_inline_data)) { prt_printf(err, "incorrect value size (%zu < %zu)", bkey_val_bytes(k.k), sizeof(struct bch_indirect_inline_data)); - return -EINVAL; + return -BCH_ERR_invalid_bkey; } return 0; |