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 -- To unsubscribe from this list: send the line "unsubscribe fio" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html