virtualization.lists.linux-foundation.org archive mirror
 help / color / mirror / Atom feed
* virtio-fs tests between host(x86) and dpu(arm64)
@ 2024-05-30  9:31 Lege Wang
  2024-06-03  8:01 ` Addressing architectural differences between FUSE driver and fs - " Peter-Jan Gootzen
  0 siblings, 1 reply; 18+ messages in thread
From: Lege Wang @ 2024-05-30  9:31 UTC (permalink / raw)
  To: pgootzen@nvidia.com, linux-fsdevel@vger.kernel.org,
	virtualization@lists.linux.dev
  Cc: Bin Yang, Lege Wang, Angus Chen

Hello,

I see that you have added multi-queue support for virtio-fs, thanks for this work.
From your patch's commit log, your host is x86-64, dpu is arm64, but there're
differences about O_DIRECT and O_DIRECTORY between these two architectures.

Test program:
#define _GNU_SOURCE

#include <stdio.h>
#include <fcntl.h>

int main(void)
{
        printf("O_DIRECT:%o\n", O_DIRECT);
        printf("O_DIRECTORY:%o\n", O_DIRECTORY);
        return 0;
}

In x86-64, this test program outputs:
O_DIRECT:40000
O_DIRECTORY:200000

But in arm64, it outpus:
O_DIRECT:200000
O_DIRECTORY:40000

In kernel fuse module, fuse_create_in->flags will used to hold open(2)'s flags, then
a O_DIRECT flag from host(x86) would be treated as O_DIRECTORY in dpu(arm64), which
seems a serious bug.

From your fio job, you use libaio engine, so it's assumed that direct-io is
enabled, so I wonder why you don't get errors. Could you please try below
command in your virtio-fs mount point:
  dd if=/dev/zero of=tst_file bs=4096 count=1 oflag=direct
to see whether it occurs any error.

Regards,
Xiaoguang Wang

^ permalink raw reply	[flat|nested] 18+ messages in thread

end of thread, other threads:[~2024-06-04 18:09 UTC | newest]

Thread overview: 18+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-05-30  9:31 virtio-fs tests between host(x86) and dpu(arm64) Lege Wang
2024-06-03  8:01 ` Addressing architectural differences between FUSE driver and fs - " Peter-Jan Gootzen
2024-06-03  8:24   ` Miklos Szeredi
2024-06-03  8:52     ` Peter-Jan Gootzen
2024-06-03  9:06       ` Miklos Szeredi
2024-06-03 13:44         ` Stefan Hajnoczi
2024-06-03 14:56           ` Miklos Szeredi
2024-06-03 15:28             ` Stefan Hajnoczi
2024-06-04  8:02               ` Miklos Szeredi
2024-06-04  8:28                 ` Peter-Jan Gootzen
2024-06-04  8:45                   ` Miklos Szeredi
2024-06-04  9:08                     ` Peter-Jan Gootzen
2024-06-04  9:18                       ` Miklos Szeredi
2024-06-04  9:31                         ` Peter-Jan Gootzen
2024-06-04 10:21                           ` Miklos Szeredi
2024-06-04  3:08           ` Lege Wang
2024-06-04  7:13             ` Idan Zach
2024-06-04 18:09           ` Daniel Verkamp

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).