From: Jan Stancek <jstancek@redhat.com>
To: ltp@lists.linux.it
Subject: [LTP] [RFC] [PATCH 02/15] lib: Add interface to list supported filesystems
Date: Thu, 7 Sep 2017 03:48:23 -0400 (EDT) [thread overview]
Message-ID: <493059632.10028491.1504770503631.JavaMail.zimbra@redhat.com> (raw)
In-Reply-To: <20170905160918.6477-2-chrubis@suse.cz>
----- Original Message -----
> A filesystem is supported if kernel can mount it (we do not get ENODEV
> when we attempt to mount it) and if there is mkfs installed so that we
> can format a test device.
>
> The function starts with a whitelist of filesystems to use and loops
> over them filtering out unsupported ones, then finally returns a list
> of filesystem that could be used for the testing.
>
> Signed-off-by: Cyril Hrubis <chrubis@suse.cz>
...
> diff --git a/lib/tst_supported_fs_types.c b/lib/tst_supported_fs_types.c
> new file mode 100644
> index 000000000..fabc39111
> --- /dev/null
> +++ b/lib/tst_supported_fs_types.c
> @@ -0,0 +1,120 @@
> +/*
> + * Copyright (c) 2017 Cyril Hrubis <chrubis@suse.cz>
> + *
> + * This program is free software: you can redistribute it and/or modify
> + * it under the terms of the GNU General Public License as published by
> + * the Free Software Foundation, either version 2 of the License, or
> + * (at your option) any later version.
> + *
> + * This program is distributed in the hope that it will be useful,
> + * but WITHOUT ANY WARRANTY; without even the implied warranty of
> + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
> + * GNU General Public License for more details.
> + *
> + * You should have received a copy of the GNU General Public License
> + * along with this program. If not, see <http://www.gnu.org/licenses/>.
> + */
> +
> +/*
> + */
> +
> +#include <stdio.h>
> +#include <errno.h>
> +#include <stdlib.h>
> +#include <sys/mount.h>
> +
> +#define TST_NO_DEFAULT_MAIN
> +#include "tst_test.h"
> +#include "tst_fs.h"
I'm running into:
ltp/lib/tst_supported_fs_types.c:54: undefined reference to `WEXITSTATUS'
on older distros, "#include <sys/wait.h>" fixes that.
Regards,
Jan
next prev parent reply other threads:[~2017-09-07 7:48 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-05 16:09 [LTP] [RFC] [PATCH 01/15] lib/tst_mkfs: Clear first 512k of the device Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 02/15] lib: Add interface to list supported filesystems Cyril Hrubis
2017-09-07 7:48 ` Jan Stancek [this message]
2017-09-07 8:25 ` Jan Stancek
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 03/15] SAFE_MOUNT: Handle FUSE mounts as well Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 04/15] lib/tst_test: Add .all_filesystems flag Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 05/15] lib/tst_fs: Add tst_fill_fs() Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 06/15] syscalls/fallocate05: New test Cyril Hrubis
2017-09-07 8:51 ` Jan Stancek
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 07/15] syscalls/msync04: Run test for all filesystems Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 08/15] syscalls/fallocate04: Convert to the new library Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 09/15] syscalls/fallocate04: Run test for all filesystems Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 10/15] syscalls/setxattr01: Convert to the new library Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 11/15] syscalls/setxattr01: Run test for all filesystems Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 12/15] syscallse/setxattr02: Convert to the new library Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 13/15] syscalls/fsync01: " Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 14/15] syscalls/fsync01: Run test for all filesystems Cyril Hrubis
2017-09-05 16:09 ` [LTP] [RFC] [PATCH 15/15] fs/fs_fill: Add a test to fill a FS in a few threads Cyril Hrubis
2017-09-07 9:13 ` Jan Stancek
2017-09-07 7:42 ` [LTP] [RFC] [PATCH 01/15] lib/tst_mkfs: Clear first 512k of the device Jan Stancek
2017-09-07 8:34 ` Cyril Hrubis
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=493059632.10028491.1504770503631.JavaMail.zimbra@redhat.com \
--to=jstancek@redhat.com \
--cc=ltp@lists.linux.it \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.