diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2022-09-18 17:10:33 -0400 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2023-10-22 17:09:40 -0400 |
commit | 098ef98d5bff461c66c3798fbebca7b1c06fdf79 (patch) | |
tree | 02879fcbd6d74a5a05a46ad399a73dac4aafd33b /fs/bcachefs/buckets.c | |
parent | 5c1ef830f6786059f85bebe7501b63dffed0b633 (diff) | |
download | lwn-098ef98d5bff461c66c3798fbebca7b1c06fdf79.tar.gz lwn-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/buckets.c')
-rw-r--r-- | fs/bcachefs/buckets.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/bcachefs/buckets.c b/fs/bcachefs/buckets.c index 136e116981d7..f01b8171cb92 100644 --- a/fs/bcachefs/buckets.c +++ b/fs/bcachefs/buckets.c @@ -1991,7 +1991,7 @@ recalculate: ret = 0; } else { atomic64_set(&c->sectors_available, sectors_available); - ret = -ENOSPC; + ret = -BCH_ERR_ENOSPC_disk_reservation; } mutex_unlock(&c->sectors_available_lock); |