From: Klaus Jensen <its@irrelevant.dk>
To: linux-block@vger.kernel.org
Cc: Omar Sandoval <osandov@fb.com>,
Klaus Jensen <k.jensen@samsung.com>,
Keith Busch <kbusch@kernel.org>,
Johannes Thumshirn <johannes.thumshirn@wdc.com>
Subject: Re: [PATCH blktests] block/011: remove and rescan for evicted device
Date: Wed, 23 Sep 2020 08:41:37 +0200 [thread overview]
Message-ID: <20200923064137.GA1473757@apples.localdomain> (raw)
In-Reply-To: <20200922080843.1249290-1-its@irrelevant.dk>
[-- Attachment #1: Type: text/plain, Size: 1406 bytes --]
On Sep 22 10:08, Klaus Jensen wrote:
> From: Klaus Jensen <k.jensen@samsung.com>
>
> Devices that actually honor the Bus Master Enable bit and considers the
> resulting failure to read/write a fatal error, often ends up getting
> disabled by the kernel when running block/011.
>
> Remove the device and rescan the pci bus after completing the test to
> make sure we bring the device back up if required.
>
> Cc: Keith Busch <kbusch@kernel.org>
> Cc: Johannes Thumshirn <johannes.thumshirn@wdc.com>
> Signed-off-by: Klaus Jensen <k.jensen@samsung.com>
> ---
> tests/block/011 | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/tests/block/011 b/tests/block/011
> index 4f331b4a7522..f1306ae3896f 100755
> --- a/tests/block/011
> +++ b/tests/block/011
> @@ -22,6 +22,7 @@ test_device() {
> echo "Running ${TEST_NAME}"
>
> pdev="$(_get_pci_dev_from_blkdev)"
> + sysfs="/sys/bus/pci/devices/${pdev}"
>
> if _test_dev_is_rotational; then
> size="32m"
> @@ -42,4 +43,8 @@ test_device() {
> done
>
> echo "Test complete"
> +
> + # bring the device back up if it was disabled by the kernel
> + echo 1 > "${sysfs}/remove"
> + echo 1 > /sys/bus/pci/rescan
> }
> --
> 2.28.0
>
Hmfh. Looks like this at least needs a wait for TEST_DEV being back or
something. Please disregard this patch for now as I try out some other
work arounds.
[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 488 bytes --]
prev parent reply other threads:[~2020-09-23 6:41 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-22 8:08 [PATCH blktests] block/011: remove and rescan for evicted device Klaus Jensen
2020-09-23 6:41 ` Klaus Jensen [this message]
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=20200923064137.GA1473757@apples.localdomain \
--to=its@irrelevant.dk \
--cc=johannes.thumshirn@wdc.com \
--cc=k.jensen@samsung.com \
--cc=kbusch@kernel.org \
--cc=linux-block@vger.kernel.org \
--cc=osandov@fb.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