From 2f52fcf698fe3799b83faf1c56afd475c96519b7 Mon Sep 17 00:00:00 2001 From: Kinglong Mee Date: Sun, 5 Mar 2017 21:04:46 +0800 Subject: [PATCH] mkfs.f2fs: clearfiy the help message and manpages Add some missing options in manpages, also order those options. v3, add the missing update of SYNOPSIS Signed-off-by: Kinglong Mee Signed-off-by: Jaegeuk Kim --- man/mkfs.f2fs.8 | 67 ++++++++++++++++++++++++++++++++++++------------- mkfs/f2fs_format_main.c | 6 ++--- 2 files changed, 52 insertions(+), 21 deletions(-) diff --git a/man/mkfs.f2fs.8 b/man/mkfs.f2fs.8 index bdb9755..3ae9f3a 100644 --- a/man/mkfs.f2fs.8 +++ b/man/mkfs.f2fs.8 @@ -16,28 +16,42 @@ mkfs.f2fs \- create an F2FS file system .I device ] [ +.B \-d +.I debugging-level +] +[ +.B \-e +.I extension-list +] +[ .B \-l .I volume-label ] [ +.B \-m +] +[ .B \-o .I overprovision-ratio-percentage ] [ -.B \-s -.I #-of-segments-per-section +.B \-O +.I feature-list ] [ -.B \-z -.I #-of-sections-per-zone +.B \-q ] [ -.B \-e -.I extenstion-list +.B \-s +.I #-of-segments-per-section ] [ -.B \-d -.I debugging-level +.B \-t +.I nodiscard/discard +] +[ +.B \-z +.I #-of-sections-per-zone ] .I device .I [sectors] @@ -63,34 +77,51 @@ The default value is 1. Build f2fs with this device additionally, so that user can see all the devices as one big volume. .TP +.BI \-d " debug-level" +Specify the level of debugging options. +The default number is 0, which shows basic debugging messages. +.TP +.BI \-e " extension-list" +Specify a file extension list in order f2fs to treat them as cold files. +The data of files having those extensions will be stored to the cold log. +The default list includes most of multimedia file extensions such as jpg, gif, +mpeg, mkv, and so on. +.TP .BI \-l " volume-label" Specify the volume label to the partition mounted as F2FS. .TP +.BI \-m +Specify f2fs filesystem to supports the block zoned feature. +Without it, the filesystem isn't supports the feature. +.TP .BI \-o " overprovision-ratio-percentage" Specify the percentage over the volume size for overprovision area. This area is hidden to users, and utilized by F2FS cleaner. If not specified, the best number will be assigned automatically accoring to the partition size. .TP +.BI \-O " feature-list" +Specify a feature list in order f2fs filesystem will supports. +e.g "encrypt" and so on. +.TP +.BI \-q +Quiet mode. +With it, mkfs.f2fs does not show any messages include the basic messages. +.TP .BI \-s " #-of-segments-per-section" Specify the number of segments per section. A section consists of multiple consecutive segments, and is the unit of garbage collection. The default number is 1, which means one segment is assigned to a section. .TP +.BI \-t " nodiscard/discard" +Specify 1 or 0 to enable/disable discard policy. +If the value is equal to 1, discard policy is enabled, otherwise is disable. +The default value is 1. +.TP .BI \-z " #-of-sections-per-zone" Specify the number of sections per zone. A zone consists of multiple sections. F2FS allocates segments for active logs with separated zones as much as possible. The default number is 1, which means a zone consists of one section. .TP -.BI \-e " extension-list" -Specify a file extension list in order f2fs to treat them as cold files. -The data of files having those extensions will be stored to the cold log. -The default list includes most of multimedia file extensions such as jpg, gif, -mpeg, mkv, and so on. -.TP -.BI \-d " debug-level" -Specify the level of debugging options. -The default number is 0, which shows basic debugging messages. -.TP .SH AUTHOR This version of .B mkfs.f2fs diff --git a/mkfs/f2fs_format_main.c b/mkfs/f2fs_format_main.c index 5bb1faf..0ac87ed 100644 --- a/mkfs/f2fs_format_main.c +++ b/mkfs/f2fs_format_main.c @@ -32,13 +32,13 @@ static void mkfs_usage() MSG(0, " -d debug level [default:0]\n"); MSG(0, " -e [extension list] e.g. \"mp3,gif,mov\"\n"); MSG(0, " -l label\n"); + MSG(0, " -m support zoned block device [default:0]\n"); MSG(0, " -o overprovision ratio [default:5]\n"); - MSG(0, " -O set feature\n"); + MSG(0, " -O [feature list] e.g. \"encrypt\"\n"); MSG(0, " -q quiet mode\n"); MSG(0, " -s # of segments per section [default:1]\n"); - MSG(0, " -z # of sections per zone [default:1]\n"); MSG(0, " -t 0: nodiscard, 1: discard [default:1]\n"); - MSG(0, " -m support zoned block device [default:0]\n"); + MSG(0, " -z # of sections per zone [default:1]\n"); MSG(0, "sectors: number of sectors. [default: determined by device size]\n"); exit(1); } -- 2.7.4