On Thu, 2017-04-27 at 16:06 -0700, Dan Williams wrote:
On Thu, Apr 27, 2017 at 3:39 PM, Vishal Verma
<vishal.l.verma(a)intel.co
m> wrote:
> Runing an Address Range Scrub on a region with a BTT namespace would
> cause a kernel null pointer dereference. This tests we don't regress
> that.
>
> Cc: Toshi Kani <toshi.kani(a)hpe.com>
> Cc: Dan Williams <dan.j.williams(a)intel.com>
> Signed-off-by: Vishal Verma <vishal.l.verma(a)intel.com>
> ---
> test/Makefile.am | 3 +-
> test/btt-ars-panic.sh | 93
> +++++++++++++++++++++++++++++++++++++++++++++++++++
> 2 files changed, 95 insertions(+), 1 deletion(-)
> create mode 100755 test/btt-ars-panic.sh
>
[..]
> +test_pass()
> +{
> + # If the test failed, there would have been a kernel null
> pointer
> + # dereference, and a subsequent ndctl disable-region would
> hang
> + $ndctl disable-region all &
Test looks good. This line makes me think we need something like
"ndctl wait-scrub-bus".
Yes, perhaps also something to start a scrub..