diff --git a/Documentation/btrfs-check.rst b/Documentation/btrfs-check.rst index 41ab39fa..e6bd8eb0 100644 --- a/Documentation/btrfs-check.rst +++ b/Documentation/btrfs-check.rst @@ -101,13 +101,6 @@ SAFE OR ADVISORY OPTIONS This option is deprecated, please use `btrfs rescue clear-space-cache` instead, this option would be removed in the future eventually. ---clear-ino-cache - remove leftover items pertaining to the deprecated `inode cache` feature - - .. warning:: - This option is deprecated, please use `btrfs rescue clear-ino-cache` - instead, this option would be removed in the future eventually. - DANGEROUS OPTIONS ----------------- @@ -147,6 +140,16 @@ DANGEROUS OPTIONS This option also skips the delay and warning in the repair mode (see *--repair*). +DEPRECATED OR MOVED OPTIONS +--------------------------- + +--clear-ino-cache + (removed: 6.7) + + remove leftover items pertaining to the deprecated *inode cache* feature, + please use :ref:`btrfs rescue clear-ino-cache` + instead + EXIT STATUS ----------- diff --git a/Documentation/btrfs-rescue.rst b/Documentation/btrfs-rescue.rst index c0419ed4..a70f5b7e 100644 --- a/Documentation/btrfs-rescue.rst +++ b/Documentation/btrfs-rescue.rst @@ -50,6 +50,8 @@ fix-device-size WARNING: CPU: 3 PID: 439 at fs/btrfs/ctree.h:1559 btrfs_update_device+0x1c5/0x1d0 [btrfs] +.. _man-rescue-clear-ino-cache: + clear-ino-cache Remove leftover items pertaining to the deprecated `inode cache` feature. diff --git a/Documentation/ch-mount-options.rst b/Documentation/ch-mount-options.rst index 42005f75..e0f8d6b5 100644 --- a/Documentation/ch-mount-options.rst +++ b/Documentation/ch-mount-options.rst @@ -489,7 +489,8 @@ inode_cache, noinode_cache .. note:: The functionality has been removed in 5.11, any stale data created by - previous use of the *inode_cache* option can be removed by :command:`btrfs check --clear-ino-cache`. + previous use of the *inode_cache* option can be removed by + :ref:`btrfs rescue clear-ino-cache`. NOTES ON GENERIC MOUNT OPTIONS diff --git a/check/main.c b/check/main.c index 70b62275..10881868 100644 --- a/check/main.c +++ b/check/main.c @@ -9994,7 +9994,6 @@ static int cmd_check(const struct cmd_struct *cmd, int argc, char **argv) int init_csum_tree = 0; int readonly = 0; int clear_space_cache = 0; - int clear_ino_cache = 0; int qgroup_report = 0; int qgroups_repaired = 0; int qgroup_verify_ret; @@ -10118,8 +10117,8 @@ static int cmd_check(const struct cmd_struct *cmd, int argc, char **argv) ctree_flags |= OPEN_CTREE_WRITES; break; case GETOPT_VAL_CLEAR_INO_CACHE: - clear_ino_cache = 1; - ctree_flags |= OPEN_CTREE_WRITES; + error("--clear-ino-cache option is deprecated, please use \"btrfs rescue clear-ino-cache\" instead"); + exit(1); break; case GETOPT_VAL_FORCE: force = 1; @@ -10234,13 +10233,6 @@ static int cmd_check(const struct cmd_struct *cmd, int argc, char **argv) goto close_out; } - if (clear_ino_cache) { - warning("--clear-ino-cache option is deprecated, please use \"btrfs rescue clear-ino-cache\" instead"); - ret = clear_ino_cache_items(gfs_info); - err = ret; - goto close_out; - } - /* * repair mode will force us to commit transaction which * will make us fail to load log tree when mounting. diff --git a/tests/fsck-tests/046-ino-cache-clean/ino-cache-enabled.raw.xz b/tests/misc-tests/060-ino-cache-clean/ino-cache-enabled.raw.xz similarity index 100% rename from tests/fsck-tests/046-ino-cache-clean/ino-cache-enabled.raw.xz rename to tests/misc-tests/060-ino-cache-clean/ino-cache-enabled.raw.xz diff --git a/tests/fsck-tests/046-ino-cache-clean/test.sh b/tests/misc-tests/060-ino-cache-clean/test.sh similarity index 97% rename from tests/fsck-tests/046-ino-cache-clean/test.sh rename to tests/misc-tests/060-ino-cache-clean/test.sh index cfbadf25..10b75cc5 100755 --- a/tests/fsck-tests/046-ino-cache-clean/test.sh +++ b/tests/misc-tests/060-ino-cache-clean/test.sh @@ -9,7 +9,7 @@ setup_root_helper image=$(extract_image "./ino-cache-enabled.raw.xz") -run_check "$TOP/btrfs" check --clear-ino-cache "$image" +run_check "$TOP/btrfs" rescue clear-ino-cache "$image" run_check "$TOP/btrfs" check "$image" # Check for FREE_INO items for toplevel subvol