From: "Verma, Vishal L" <vishal.l.verma@intel.com>
To: "Schofield, Alison" <alison.schofield@intel.com>
Cc: "Williams, Dan J" <dan.j.williams@intel.com>,
"Jiang, Dave" <dave.jiang@intel.com>,
"linux-cxl@vger.kernel.org" <linux-cxl@vger.kernel.org>,
"nvdimm@lists.linux.dev" <nvdimm@lists.linux.dev>
Subject: Re: [PATCH ndctl 3/3] test/cxl-security.sh: avoid intermittent failures due to sasync probe
Date: Tue, 21 Feb 2023 18:13:16 +0000 [thread overview]
Message-ID: <427fbc8d0cf56b9cbdfb7f5bef31a96c4b40fe31.camel@intel.com> (raw)
In-Reply-To: <Y/T96khZVa7Oo6uU@aschofie-mobl2>
On Tue, 2023-02-21 at 09:22 -0800, Alison Schofield wrote:
> On Fri, Feb 17, 2023 at 05:40:24PM -0700, Vishal Verma wrote:
> > This test failed intermittently because the ndctl-list operation right
> > after a 'modprobe cxl_test' could race the actual nmem devices getting
> > loaded.
> >
> > Since CXL device probes are asynchronous, and cxl_acpi might've kicked
> > off a cxl_bus_rescan(), a cxl_flush() (via cxl_wait_probe()) can ensure
> > everything is loaded.
> >
> > Add a plain cxl-list right after the modprobe to allow for a flush/wait
> > cycle.
>
> Is this the preferred method to 'settle', instead of udevadm settle?
Generally, no. Usually cxl tests would use cxl-cli commands, which now
have the necessary waits via cxl_wait_probe(), so even a 'udevadm
settle' shouldn't be needed.
In this case, the first thing we run is ndctl list, which waits for
nvdimm things to 'settle', but we were racing with cxl_test coming up,
which it (ndctl) knows nothing about.
>
> >
> > Cc: Dave Jiang <dave.jiang@intel.com>
> > Suggested-by: Dan Williams <dan.j.williams@intel.com>
> > Signed-off-by: Vishal Verma <vishal.l.verma@intel.com>
> > ---
> > test/security.sh | 1 +
> > 1 file changed, 1 insertion(+)
> >
> > diff --git a/test/security.sh b/test/security.sh
> > index 04f630e..fb04aa6 100755
> > --- a/test/security.sh
> > +++ b/test/security.sh
> > @@ -225,6 +225,7 @@ if [ "$uid" -ne 0 ]; then
> > fi
> >
> > modprobe "$KMOD_TEST"
> > +cxl list
> > setup
> > check_prereq "keyctl"
> > rc=1
> >
> > --
> > 2.39.1
> >
> >
next prev parent reply other threads:[~2023-02-21 18:14 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-18 0:40 [PATCH ndctl 0/3] cxl/monitor: coverity and misc other fixes Vishal Verma
2023-02-18 0:40 ` [PATCH ndctl 1/3] cxl/event_trace: fix a resource leak in cxl_event_to_json() Vishal Verma
2023-02-21 16:44 ` Dave Jiang
2023-02-22 1:53 ` Ira Weiny
2023-02-18 0:40 ` [PATCH ndctl 2/3] cxl/monitor: retain error code in monitor_event() Vishal Verma
2023-02-21 16:45 ` Dave Jiang
2023-02-22 1:56 ` Ira Weiny
2023-02-22 6:33 ` Verma, Vishal L
2023-02-18 0:40 ` [PATCH ndctl 3/3] test/cxl-security.sh: avoid intermittent failures due to sasync probe Vishal Verma
2023-02-21 16:45 ` Dave Jiang
2023-02-21 17:22 ` Alison Schofield
2023-02-21 18:08 ` Dan Williams
2023-02-21 18:13 ` Verma, Vishal L [this message]
2023-02-21 18:34 ` Alison Schofield
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=427fbc8d0cf56b9cbdfb7f5bef31a96c4b40fe31.camel@intel.com \
--to=vishal.l.verma@intel.com \
--cc=alison.schofield@intel.com \
--cc=dan.j.williams@intel.com \
--cc=dave.jiang@intel.com \
--cc=linux-cxl@vger.kernel.org \
--cc=nvdimm@lists.linux.dev \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox