diff options
author | Jens Axboe <jens.axboe@oracle.com> | 2010-03-04 14:05:48 +0100 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2010-03-04 14:05:48 +0100 |
commit | e2de69dac799a1eecac1b52085f908729591ef5a (patch) | |
tree | 6f8d457a3be2ec791446e8612b59e4c00d1f25b0 /options.c | |
parent | 02c6aad501477833c7e017eec0bb14f8e6957b68 (diff) | |
download | fio-e2de69dac799a1eecac1b52085f908729591ef5a.tar.gz |
Add initial support for profile specific options
Not complete yet, we need to split option parsing for profiles a
bit.
Signed-off-by: Jens Axboe <jens.axboe@oracle.com>
Diffstat (limited to 'options.c')
-rw-r--r-- | options.c | 16 |
1 files changed, 15 insertions, 1 deletions
@@ -1959,7 +1959,7 @@ void fio_fill_default_options(struct thread_data *td) int fio_show_option_help(const char *opt) { - return show_cmd_help(options, opt); + return show_cmd_help(options, &ext_opt_list, opt); } static void __options_mem(struct thread_data *td, int alloc) @@ -2019,3 +2019,17 @@ void register_ext_option(struct ext_option *eopt) option_init(&eopt->o); flist_add_tail(&eopt->list, &ext_opt_list); } + +void prune_profile_options(const char *prof_name) +{ + struct ext_option *eo; + struct flist_head *n, *tmp; + + flist_for_each_safe(n, tmp, &ext_opt_list) { + eo = flist_entry(n, struct ext_option, list); + if (strcmp(eo->prof_name, prof_name)) + continue; + flist_del(&eo->list); + free(eo); + } +} |