All of lore.kernel.org
 help / color / mirror / Atom feed
From: Zorro Lang <zlang@kernel.org>
To: fstests@vger.kernel.org
Cc: io-uring@vger.kernel.org
Subject: [PATCH 0/3] fstests: fix io_uring testing
Date: Wed,  6 Mar 2024 17:19:32 +0800	[thread overview]
Message-ID: <20240306091935.4090399-1-zlang@kernel.org> (raw)

According to the manual of io_uring_queue_init, it doesn't set errno
but return the -errno on failure. So we should check the return value
of io_uring_queue_init, to make sure if the io_uring is supported by
kernel. We've left this problem in xfstests/ltp/fsstress.c long time.
(Refer to PATCH 1/3)

And besides kernel build without CONFIG_IO_URING, a system can disable
the io_uring supporting manually, by set sysctl kernel.io_uring_disabled=2.
The former cause io_uring_queue_init return ENOSYS, but the latter will
return EPERM. So I let fsstress to deal with both situations.
(Refer to PATCH 2/3)

A question is if we should do "sysctl -w kernel.io_uring_disabled=0 &> /dev/null"
at the beginning of each test case (e.g. do that in common/config ?), or leave
this decision to the testers (in their test wrapper). Now I only do that
in _require_io_uring(). If anyone has any opinions, feel free to reply.
(Refer to PATCH 3/3)

Thanks,
Zorro


             reply	other threads:[~2024-03-06  9:19 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-03-06  9:19 Zorro Lang [this message]
2024-03-06  9:19 ` [PATCH 1/3] fsstress: check io_uring_queue_init errno properly Zorro Lang
2024-03-06 15:53   ` Darrick J. Wong
2024-03-06 19:34     ` Zorro Lang
2024-03-06 15:56   ` Jeff Moyer
2024-03-06  9:19 ` [PATCH 2/3] fsstress: bypass io_uring testing if io_uring_queue_init returns EPERM Zorro Lang
2024-03-06 15:55   ` Darrick J. Wong
2024-03-06 19:36     ` Zorro Lang
2024-03-06 15:57   ` Jeff Moyer
2024-03-06 19:38     ` Zorro Lang
2024-03-06  9:19 ` [PATCH 3/3] common/rc: force enable io_uring in _require_io_uring Zorro Lang
2024-03-06 15:43   ` Darrick J. Wong
2024-03-06 15:59     ` Jeff Moyer
2024-03-06 19:56       ` Zorro Lang
2024-03-06 19:51     ` Zorro Lang

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=20240306091935.4090399-1-zlang@kernel.org \
    --to=zlang@kernel.org \
    --cc=fstests@vger.kernel.org \
    --cc=io-uring@vger.kernel.org \
    /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.