From: Vinod Koul <vkoul@kernel.org>
To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Cc: Dan Williams <dan.j.williams@intel.com>,
dmaengine@vger.kernel.org,
Nicolas Ferre <nicolas.ferre@microchip.com>
Subject: Re: [PATCH v1 1/6] dmaengine: dmatest: Fix iteration non-stop logic
Date: Mon, 27 Apr 2020 21:46:02 +0530 [thread overview]
Message-ID: <20200427161602.GK56386@vkoul-mobl.Dlink> (raw)
In-Reply-To: <20200424161147.16895-1-andriy.shevchenko@linux.intel.com>
On 24-04-20, 19:11, Andy Shevchenko wrote:
> Under some circumstances, i.e. when test is still running and about to
> time out and user runs, for example,
>
> grep -H . /sys/module/dmatest/parameters/*
>
> the iterations parameter is not respected and test is going on and on until
> user gives
>
> echo 0 > /sys/module/dmatest/parameters/run
>
> This is not what expected.
>
> The history of this bug is interesting. I though that the commit
> 2d88ce76eb98 ("dmatest: add a 'wait' parameter")
> is a culprit, but looking closer to the code I think it simple revealed the
> broken logic from the day one, i.e. in the commit
> 0a2ff57d6fba ("dmaengine: dmatest: add a maximum number of test iterations")
> which adds iterations parameter.
>
> So, to the point, the conditional of checking the thread to be stopped being
> first part of conjunction logic prevents to check iterations. Thus, we have to
> always check both conditions to be able to stop after given iterations.
>
> Since it wasn't visible before second commit appeared, I add a respective
> Fixes tag.
Applied, thanks
--
~Vinod
prev parent reply other threads:[~2020-04-27 16:16 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-24 16:11 [PATCH v1 1/6] dmaengine: dmatest: Fix iteration non-stop logic Andy Shevchenko
2020-04-24 16:11 ` [PATCH v1 2/6] dmaengine: dmatest: Fix process hang when reading 'wait' parameter Andy Shevchenko
2020-04-27 16:16 ` Vinod Koul
2020-04-24 16:11 ` [PATCH v1 3/6] Revert "dmaengine: dmatest: timeout value of -1 should specify infinite wait" Andy Shevchenko
2020-04-27 16:18 ` Vinod Koul
2020-04-24 16:11 ` [PATCH v1 4/6] dmaengine: dmatest: Allow negative timeout value to specify infinite wait Andy Shevchenko
2020-04-27 16:18 ` Vinod Koul
2020-04-24 16:11 ` [PATCH v1 5/6] dmaengine: dmatest: Describe members of struct dmatest_params Andy Shevchenko
2020-04-27 16:21 ` Vinod Koul
2020-04-24 16:11 ` [PATCH v1 6/6] dmaengine: dmatest: Describe members of struct dmatest_info Andy Shevchenko
2020-04-27 16:22 ` Vinod Koul
2020-04-27 8:09 ` [PATCH v1 1/6] dmaengine: dmatest: Fix iteration non-stop logic Nicolas Ferre
2020-04-27 16:16 ` Vinod Koul [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=20200427161602.GK56386@vkoul-mobl.Dlink \
--to=vkoul@kernel.org \
--cc=andriy.shevchenko@linux.intel.com \
--cc=dan.j.williams@intel.com \
--cc=dmaengine@vger.kernel.org \
--cc=nicolas.ferre@microchip.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