diff options
author | Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com> | 2016-03-09 15:18:57 +0900 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2016-03-11 17:12:35 +0100 |
commit | 3c1d84b71ebee2757b6c8691494a5716a7806bfa (patch) | |
tree | 2af24d0fb581fafd251319de820b6ad1a6af2d6a /fs/btrfs | |
parent | 6788f5ca6402020dc02eda1a5c8748e8c3c99bf4 (diff) | |
download | linux-3c1d84b71ebee2757b6c8691494a5716a7806bfa.tar.bz2 |
Btrfs: Show a warning message if one of objectid reaches its highest value
It's better to show a warning message for the exceptional case
that one of objectid (in most case, inode number) reaches its
highest value. For example, if inode cache is off and this event
happens, we can't create any file even if there are not so many files.
This message ease detecting such problem.
Signed-off-by: Satoru Takeuchi <takeuchi_satoru@jp.fujitsu.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs')
-rw-r--r-- | fs/btrfs/inode-map.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/btrfs/inode-map.c b/fs/btrfs/inode-map.c index e50316c4af15..1f0ec19b23f6 100644 --- a/fs/btrfs/inode-map.c +++ b/fs/btrfs/inode-map.c @@ -556,6 +556,9 @@ int btrfs_find_free_objectid(struct btrfs_root *root, u64 *objectid) mutex_lock(&root->objectid_mutex); if (unlikely(root->highest_objectid >= BTRFS_LAST_FREE_OBJECTID)) { + btrfs_warn(root->fs_info, + "the objectid of root %llu reaches its highest value", + root->root_key.objectid); ret = -ENOSPC; goto out; } |