summaryrefslogtreecommitdiffstats
path: root/fs/bcachefs/disk_groups.c
diff options
context:
space:
mode:
authorKent Overstreet <kent.overstreet@linux.dev>2022-09-18 17:10:33 -0400
committerKent Overstreet <kent.overstreet@linux.dev>2023-10-22 17:09:40 -0400
commit098ef98d5bff461c66c3798fbebca7b1c06fdf79 (patch)
tree02879fcbd6d74a5a05a46ad399a73dac4aafd33b /fs/bcachefs/disk_groups.c
parent5c1ef830f6786059f85bebe7501b63dffed0b633 (diff)
downloadlinux-098ef98d5bff461c66c3798fbebca7b1c06fdf79.tar.gz
linux-098ef98d5bff461c66c3798fbebca7b1c06fdf79.tar.bz2
linux-098ef98d5bff461c66c3798fbebca7b1c06fdf79.zip
bcachefs: Add private error codes for ENOSPC
Continuing the saga of introducing private dedicated error codes for each error path, this patch converts ENOSPC to error codes that are subtypes of ENOSPC. We've recently had a test failure where we got -ENOSPC where we shouldn't have, and didn't have enough information to tell where it came from, so this patch will solve that problem. Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/disk_groups.c')
-rw-r--r--fs/bcachefs/disk_groups.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/bcachefs/disk_groups.c b/fs/bcachefs/disk_groups.c
index 5f405d38b3de..6b81f35861ac 100644
--- a/fs/bcachefs/disk_groups.c
+++ b/fs/bcachefs/disk_groups.c
@@ -276,7 +276,7 @@ static int __bch2_disk_group_add(struct bch_sb_handle *sb, unsigned parent,
groups = bch2_sb_resize_disk_groups(sb, u64s);
if (!groups)
- return -ENOSPC;
+ return -BCH_ERR_ENOSPC_disk_label_add;
nr_groups = disk_groups_nr(groups);
}