From: Jens Axboe <axboe@kernel.dk>
To: Tomohiro Kusumi <kusumi.tomohiro@gmail.com>
Cc: fio@vger.kernel.org
Subject: Re: [PATCH 04/15] Add FIO_HAVE_BLKDEV_INVALIDATE_CACHE to selectively support pagecache invalidation
Date: Wed, 27 Jul 2016 08:25:37 -0600 [thread overview]
Message-ID: <20160727142537.GA26856@kernel.dk> (raw)
In-Reply-To: <1469626640-13335-4-git-send-email-kusumi.tomohiro@gmail.com>
On Wed, Jul 27 2016, Tomohiro Kusumi wrote:
> Most kernels either don't provide a way to invalidate the cache
> or don't need to provide one as "block device" no longer exist
> as a file type after being replaced by character device.
> Linux (incl Android) is the only supported OS that actually does
> something via ioctl.
>
> This commit adds FIO_HAVE_BLKDEV_INVALIDATE_CACHE. If this macro
> is undefined, cache invalidation for block device isn't supported.
> Only Linux supports it as mentioned above. It's better to do this
> like other OS specific features, because having blockdev_invalidate_cache()
> implementation which only pretends as if it has invalidated cache
> (by returning either 0 or EINVAL) could be misleading for users.
>
> The drawback is this commit requires users to fix config files
> (remove invalidate=) in order to use them on other platforms
> that were portable till then.
This seems to equate invalidate with only working on a block device,
which is not true. And for files, it'll work fine on non-linux as well,
using the fadvise functions.
--
Jens Axboe
next prev parent reply other threads:[~2016-07-27 14:25 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-07-27 13:37 [PATCH 01/15] Make return value type of fio_getaffinity() consistent Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 02/15] Fix typos in log_err() message Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 03/15] Use default CPU_COUNT() function in DragonFlyBSD Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 04/15] Add FIO_HAVE_BLKDEV_INVALIDATE_CACHE to selectively support pagecache invalidation Tomohiro Kusumi
2016-07-27 14:25 ` Jens Axboe [this message]
2016-07-27 14:44 ` Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 05/15] Use sizeof(char*) instead of sizeof(void*) Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 06/15] Mention default values for readwrite=/ioengine=/mem= in documentation Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 07/15] Mention cpuio never finishes without real I/O " Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 08/15] Ignore exit_io_done= option if no I/O threads are configured Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 09/15] Use correct I/O engine name "cpuio" instead of "cpu" Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 10/15] Add missing --cmdhelp type string for FIO_OPT_UNSUPPORTED Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 11/15] Don't malloc/memcpy ioengine_ops on td initialization Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 12/15] Fix stat(2) related bugs introduced by changes made for Windows Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 13/15] Rename exists_and_not_file() to exists_and_not_regfile() Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 14/15] Add missing archs in fio_arch_strings[] Tomohiro Kusumi
2016-07-27 13:37 ` [PATCH 15/15] Change arch_i386 to arch_x86 Tomohiro Kusumi
2016-07-27 14:30 ` [PATCH 01/15] Make return value type of fio_getaffinity() consistent Jens Axboe
2016-07-27 14:44 ` Tomohiro Kusumi
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=20160727142537.GA26856@kernel.dk \
--to=axboe@kernel.dk \
--cc=fio@vger.kernel.org \
--cc=kusumi.tomohiro@gmail.com \
/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.