Linux CXL
 help / color / mirror / Atom feed
From: Alison Schofield <alison.schofield@intel.com>
To: "Xingtao Yao (Fujitsu)" <yaoxt.fnst@fujitsu.com>
Cc: Davidlohr Bueso <dave@stgolabs.net>,
	Jonathan Cameron <Jonathan.Cameron@huawei.com>,
	Dave Jiang <dave.jiang@intel.com>,
	Vishal Verma <vishal.l.verma@intel.com>,
	Ira Weiny <ira.weiny@intel.com>,
	Dan Williams <dan.j.williams@intel.com>,
	"linux-cxl@vger.kernel.org" <linux-cxl@vger.kernel.org>
Subject: Re: [PATCH 2/2] cxl/test: Replace ENXIO with EBUSY for inject poison limit reached
Date: Sat, 6 Jul 2024 18:48:27 -0700	[thread overview]
Message-ID: <Zonz67MFZMzBryoa@aschofie-mobl2> (raw)
In-Reply-To: <TYCPR01MB6464AD7628D9B17C13BDE1598DDF2@TYCPR01MB6464.jpnprd01.prod.outlook.com>

On Fri, Jul 05, 2024 at 06:15:24AM +0000, Xingtao Yao (Fujitsu) wrote:
> > -----Original Message-----
> > From: alison.schofield@intel.com <alison.schofield@intel.com>

snip

> > 
> > -static bool mock_poison_add(struct cxl_dev_state *cxlds, u64 dpa)
> > +static int mock_poison_add(struct cxl_dev_state *cxlds, u64 dpa)
> >  {
> > +	/* Return EBUSY to match the CXL driver handling */
> >  	if (mock_poison_dev_max_injected(cxlds)) {
> >  		dev_dbg(cxlds->dev,
> >  			"Device poison injection limit has been reached: %d\n",
> >  			MOCK_INJECT_DEV_MAX);
> There is a tiny issue here, we'd better replace MOCK_INJECT_DEV_MAX with 
> poison_inject_dev_max, as this value can be configured through 
> /sys/bus/platform/drivers/cxl_mock_mem/poison_inject_max
> 
> like:
> # echo 128 > /sys/bus/platform/drivers/cxl_mock_mem/poison_inject_max
> 
> after injecting 129 poisons, the “Device or resource busy” occurred, but the debug message
> still output:
> [ 7664.280587] cxl_mock_mem cxl_mem.0: Device poison injection limit has been reached: 8
> [ 7664.280591] cxl_mock_mem cxl_mem.0: opcode: 0x4301 sz_in: 8 sz_out: 0 rc: -16
> 
> 
> Tested-by: Xingtao Yao <yaoxt.fnst@fujitsu.com>
> 

Thanks for testing and thanks for finding this issue.

I've folded this fixup into v2 of this patch. Since it's cxl-test, and
it's a dev_dbg() message, and it's directly adjacent to what this patch
touches, I expect that will be OK. (as opposed to a seperate fixup)

--Alison


  reply	other threads:[~2024-07-07  1:48 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-04  0:38 [PATCH 0/2] Return EBUSY on inject poison limit reached alison.schofield
2024-07-04  0:38 ` [PATCH 1/2] cxl/memdev: Replace ENXIO with EBUSY for " alison.schofield
2024-07-05  6:59   ` Xingtao Yao (Fujitsu)
2024-07-04  0:38 ` [PATCH 2/2] cxl/test: " alison.schofield
2024-07-05  6:15   ` Xingtao Yao (Fujitsu)
2024-07-07  1:48     ` Alison Schofield [this message]
2024-07-04  1:00 ` [PATCH 0/2] Return EBUSY on " Dan Williams
2024-07-06  2:05 ` Davidlohr Bueso

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=Zonz67MFZMzBryoa@aschofie-mobl2 \
    --to=alison.schofield@intel.com \
    --cc=Jonathan.Cameron@huawei.com \
    --cc=dan.j.williams@intel.com \
    --cc=dave.jiang@intel.com \
    --cc=dave@stgolabs.net \
    --cc=ira.weiny@intel.com \
    --cc=linux-cxl@vger.kernel.org \
    --cc=vishal.l.verma@intel.com \
    --cc=yaoxt.fnst@fujitsu.com \
    /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