linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: per.forlin@linaro.org (Per Forlin)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v8 05/12] mmc: mmc_test: add test for non-blocking transfers
Date: Fri, 1 Jul 2011 15:29:25 +0200	[thread overview]
Message-ID: <BANLkTi=-Nn0HjLgmTsCs9zoQt4By-6-KZw@mail.gmail.com> (raw)
In-Reply-To: <1309248717-14606-6-git-send-email-per.forlin@linaro.org>

On 28 June 2011 10:11, Per Forlin <per.forlin@linaro.org> wrote:
> Add four tests for read and write performance per
> different transfer size, 4k to 4M.
> ?* Read using blocking mmc request
> ?* Read using non-blocking mmc request
> ?* Write using blocking mmc request
> ?* Write using non-blocking mmc request
>
> The host dirver must support pre_req() and post_req()
> in order to run the non-blocking test cases.
>
> Signed-off-by: Per Forlin <per.forlin@linaro.org>
> ---
> ?drivers/mmc/card/mmc_test.c | ?311 +++++++++++++++++++++++++++++++++++++++++-
> ?1 files changed, 303 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/mmc/card/mmc_test.c b/drivers/mmc/card/mmc_test.c
> +static int mmc_test_nonblock_transfer(struct mmc_test_card *test,
> + ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? struct scatterlist *sg, unsigned sg_len,
> + ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? unsigned dev_addr, unsigned blocks,
> + ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? ? unsigned blksz, int write, int count)
> +{
> + ? ? ? struct mmc_request mrq1;
> + ? ? ? struct mmc_command cmd1;
> + ? ? ? struct mmc_command stop1;
> + ? ? ? struct mmc_data data1;
> +
> + ? ? ? struct mmc_request mrq2;
> + ? ? ? struct mmc_command cmd2;
> + ? ? ? struct mmc_command stop2;
> + ? ? ? struct mmc_data data2;
> +
> + ? ? ? struct mmc_test_async_req test_areq[2];
> + ? ? ? struct mmc_async_req *done_areq;
> + ? ? ? struct mmc_async_req *cur_areq = &test_areq[0].areq;
> + ? ? ? struct mmc_async_req *other_areq = &test_areq[1].areq;
> + ? ? ? int i;
> + ? ? ? int ret;
> +
> + ? ? ? test_areq[0].test = test;
> + ? ? ? test_areq[1].test = test;
> +
> + ? ? ? if (!test->card->host->ops->pre_req ||
> + ? ? ? ? ? ? ? !test->card->host->ops->post_req)
> + ? ? ? ? ? ? ? return -RESULT_UNSUP_HOST;
Remove this error check. It is fine to run this test without these
hooks, but there will be no performance gain compared to blocking
request.

...

> +/*
> + * Multiple blocking write 4k to 4 MB chunks
> + */
> +static int mmc_test_profile_mult_write_blocking_perf(struct mmc_test_card *test)
> +{
> + ? ? ? unsigned int bs[] = {1 << 12, 1 << 13, 1 << 14, 1 << 15, 1 << 16,
> + ? ? ? ? ? ? ? ? ? ? ? ? ? ?1 << 17, 1 << 18, 1 << 19, 1 << 20, 1 << 22};
> + ? ? ? struct mmc_test_multiple_rw test_data = {
> + ? ? ? ? ? ? ? .bs = bs,
> + ? ? ? ? ? ? ? .size = 128*1024*1024,
I got this comment from Linus W.
Use TEST_AREA_MAX_SIZE instead of hard coded 128*1024*1024. update all
relevant functions.

/Per

  reply	other threads:[~2011-07-01 13:29 UTC|newest]

Thread overview: 27+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-28  8:11 [PATCH v8 00/12] use nonblock mmc requests to minimize latency Per Forlin
2011-06-28  8:11 ` [PATCH v8 01/12] mmc: core: add non-blocking mmc request function Per Forlin
2011-06-28  8:11 ` [PATCH v8 02/12] omap_hsmmc: add support for pre_req and post_req Per Forlin
2011-06-28  8:11 ` [PATCH v8 03/12] mmci: implement pre_req() and post_req() Per Forlin
2011-06-28  8:11 ` [PATCH v8 04/12] mmc: mmc_test: add debugfs file to list all tests Per Forlin
2011-06-28  8:11 ` [PATCH v8 05/12] mmc: mmc_test: add test for non-blocking transfers Per Forlin
2011-07-01 13:29   ` Per Forlin [this message]
2011-06-28  8:11 ` [PATCH v8 06/12] mmc: mmc_test: test to measure how sg_len affect performance Per Forlin
2011-07-01 13:33   ` Per Forlin
2011-06-28  8:11 ` [PATCH v8 07/12] mmc: block: add member in mmc queue struct to hold request data Per Forlin
2011-06-28  8:11 ` [PATCH v8 08/12] mmc: block: add a block request prepare function Per Forlin
2011-06-28  8:11 ` [PATCH v8 09/12] mmc: block: move error code in issue_rw_rq to a separate function Per Forlin
2011-06-28  8:11 ` [PATCH v8 10/12] mmc: queue: add a second mmc queue request member Per Forlin
2011-06-28  8:11 ` [PATCH v8 11/12] mmc: core: add random fault injection Per Forlin
2011-06-28  8:11 ` [PATCH v8 12/12] mmc: block: add handling for two parallel block requests in issue_rw_rq Per Forlin
2011-06-28  9:39   ` Per Forlin
2011-06-28  9:54 ` [PATCH v8 00/12] use nonblock mmc requests to minimize latency Kyungmin Park
2011-06-30 12:36 ` Poddar, Sourav
2011-06-30 13:11   ` S, Venkatraman
2011-06-30 13:12 ` Arnd Bergmann
2011-06-30 13:30   ` Russell King - ARM Linux
2011-07-01 16:44     ` Arnd Bergmann
2011-07-02 12:29       ` Russell King - ARM Linux
2011-07-02 19:37         ` Arnd Bergmann
2011-07-03 20:53           ` Per Forlin
2011-07-04  1:07             ` Nicolas Pitre
2011-07-01 14:39 ` Linus Walleij

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='BANLkTi=-Nn0HjLgmTsCs9zoQt4By-6-KZw@mail.gmail.com' \
    --to=per.forlin@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    /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;
as well as URLs for NNTP newsgroup(s).