diff options
Diffstat (limited to 'e2fsprogs/tune2fs.c')
-rw-r--r-- | e2fsprogs/tune2fs.c | 43 |
1 files changed, 27 insertions, 16 deletions
diff --git a/e2fsprogs/tune2fs.c b/e2fsprogs/tune2fs.c index 46a745ee4..c9f88b39d 100644 --- a/e2fsprogs/tune2fs.c +++ b/e2fsprogs/tune2fs.c | |||
@@ -6,6 +6,33 @@ | |||
6 | * | 6 | * |
7 | * Licensed under GPLv2, see file LICENSE in this source tree. | 7 | * Licensed under GPLv2, see file LICENSE in this source tree. |
8 | */ | 8 | */ |
9 | //config:config TUNE2FS | ||
10 | //config: bool "tune2fs" | ||
11 | //config: default n # off: it is too limited compared to upstream version | ||
12 | //config: help | ||
13 | //config: tune2fs allows the system administrator to adjust various tunable | ||
14 | //config: filesystem parameters on Linux ext2/ext3 filesystems. | ||
15 | |||
16 | //applet:IF_TUNE2FS(APPLET(tune2fs, BB_DIR_SBIN, BB_SUID_DROP)) | ||
17 | |||
18 | //kbuild:lib-$(CONFIG_TUNE2FS) += tune2fs.o | ||
19 | |||
20 | //usage:#define tune2fs_trivial_usage | ||
21 | //usage: "[-c MAX_MOUNT_COUNT] " | ||
22 | ////usage: "[-e errors-behavior] [-g group] " | ||
23 | //usage: "[-i DAYS] " | ||
24 | ////usage: "[-j] [-J journal-options] [-l] [-s sparse-flag] " | ||
25 | ////usage: "[-m reserved-blocks-percent] [-o [^]mount-options[,...]] " | ||
26 | ////usage: "[-r reserved-blocks-count] [-u user] " | ||
27 | //usage: "[-C MOUNT_COUNT] " | ||
28 | //usage: "[-L LABEL] " | ||
29 | ////usage: "[-M last-mounted-dir] [-O [^]feature[,...]] " | ||
30 | ////usage: "[-T last-check-time] [-U UUID] " | ||
31 | //usage: "BLOCKDEV" | ||
32 | //usage: | ||
33 | //usage:#define tune2fs_full_usage "\n\n" | ||
34 | //usage: "Adjust filesystem options on ext[23] filesystems" | ||
35 | |||
9 | #include "libbb.h" | 36 | #include "libbb.h" |
10 | #include <linux/fs.h> | 37 | #include <linux/fs.h> |
11 | #include "bb_e2fs_defs.h" | 38 | #include "bb_e2fs_defs.h" |
@@ -27,22 +54,6 @@ do { \ | |||
27 | #define FETCH_LE32(field) \ | 54 | #define FETCH_LE32(field) \ |
28 | (sizeof(field) == 4 ? SWAP_LE32(field) : BUG_wrong_field_size()) | 55 | (sizeof(field) == 4 ? SWAP_LE32(field) : BUG_wrong_field_size()) |
29 | 56 | ||
30 | //usage:#define tune2fs_trivial_usage | ||
31 | //usage: "[-c MAX_MOUNT_COUNT] " | ||
32 | ////usage: "[-e errors-behavior] [-g group] " | ||
33 | //usage: "[-i DAYS] " | ||
34 | ////usage: "[-j] [-J journal-options] [-l] [-s sparse-flag] " | ||
35 | ////usage: "[-m reserved-blocks-percent] [-o [^]mount-options[,...]] " | ||
36 | ////usage: "[-r reserved-blocks-count] [-u user] " | ||
37 | //usage: "[-C MOUNT_COUNT] " | ||
38 | //usage: "[-L LABEL] " | ||
39 | ////usage: "[-M last-mounted-dir] [-O [^]feature[,...]] " | ||
40 | ////usage: "[-T last-check-time] [-U UUID] " | ||
41 | //usage: "BLOCKDEV" | ||
42 | //usage: | ||
43 | //usage:#define tune2fs_full_usage "\n\n" | ||
44 | //usage: "Adjust filesystem options on ext[23] filesystems" | ||
45 | |||
46 | enum { | 57 | enum { |
47 | OPT_L = 1 << 0, // label | 58 | OPT_L = 1 << 0, // label |
48 | OPT_c = 1 << 1, // max mount count | 59 | OPT_c = 1 << 1, // max mount count |