]> git.baikalelectronics.ru Git - kernel.git/commit
virtiofs: Fail dax mount if device does not support it
authorVivek Goyal <vgoyal@redhat.com>
Tue, 9 Feb 2021 22:47:54 +0000 (17:47 -0500)
committerMiklos Szeredi <mszeredi@redhat.com>
Fri, 5 Mar 2021 14:46:47 +0000 (15:46 +0100)
commit84a1ebf7bf74e5281e9635358265e9384aae247a
treeb67d0c363189165b968a1a5e73ff91f0205152cc
parent9a63d2ef36a590ca685e4e8910857f37765b2954
virtiofs: Fail dax mount if device does not support it

Right now "mount -t virtiofs -o dax myfs /mnt/virtiofs" succeeds even
if filesystem deivce does not have a cache window and hence DAX can't
be supported.

This gives a false sense to user that they are using DAX with virtiofs
but fact of the matter is that they are not.

Fix this by returning error if dax can't be supported and user has asked
for it.

Signed-off-by: Vivek Goyal <vgoyal@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
fs/fuse/virtio_fs.c