linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mark Salyzyn <salyzyn@android.com>
To: Pavel Machek <pavel@ucw.cz>
Cc: linux-kernel@vger.kernel.org,
	Ulf Hansson <ulf.hansson@linaro.org>,
	Adrian Hunter <adrian.hunter@intel.com>,
	Andy Shevchenko <andriy.shevchenko@linux.intel.com>,
	Luca Porzio <lporzio@micron.com>,
	yalin wang <yalin.wang2010@gmail.com>,
	Shawn Lin <shawn.lin@rock-chips.com>,
	Jon Hunter <jonathanh@nvidia.com>,
	Grant Grundler <grundler@chromium.org>,
	Yunpeng Gao <yunpeng.gao@intel.com>,
	Chuanxiao Dong <chuanxiao.dong@intel.com>,
	linux-mmc@vger.kernel.org
Subject: Re: mmc: Add CONFIG_MMC_BLOCK_MAX_SPEED
Date: Mon, 22 Feb 2016 08:04:29 -0800	[thread overview]
Message-ID: <56CB318D.7070403@android.com> (raw)
In-Reply-To: <20160222064551.GA23884@amd>

On 02/21/2016 10:45 PM, Pavel Machek wrote:
> Hi!
>
> On Thu 2016-02-04 12:29:07, Mark Salyzyn wrote:
>> When CONFIG_MMC_BLOCK_MAX_SPEED is enabled, Expose max_read_speed,
>> max_write_speed and cache_size controls to simulate a slow eMMC device.
>> The boot default values for each respectively are
>> CONFIG_MMC_BLOCK_MAX_READ_SPEED, CONFIG_MMC_BLOCK_MAX_WRITE_SPEED and
>> CONFIG_MMC_BLOCK_CACHE_SIZE respectively; and if not defined are
>> 0 (off), 0, (off) and 4 MB also respectively.
> Extra , after 0.

Yes :-)
> Dunno. At minimum, I'd call the option something like
> "MMC_DEBUG_MAX_SPEED" and the speeds should be really controlled via
> /sys or something...

Are controlled by sys.  Concern over DEBUG_MAX_SPEED is the sys nodes 
changing name to debug_max_read_speed, etc, which would in turn result 
in a move to debugfs instead. Will have to think about all the side 
effects of such a move.

> ...and ... is there reason to limit it to mmc devices? Making
> harddrive slow would make it useful for testing, too...

The speed limit at this layer is not the same as in the block layer, the 
two methods would 'join' at the same value when one does sustained I/O 
most likely, but not at the random patterns we have experienced on the 
devices. We would like additional wiggle room to simulate eMMC stalls 
due to load leveling and other behaviors in the future. If we moved up a 
layer we would have to simulate head seek and rotational latency opening 
a can of worms we would feel best if left closed. View it as a political 
decision.
>
> ...and you have the /sys interface. Drop the config options?

I needed a start up default value for boot-time simulations. If just sys 
options, we would be applying the values far too late in the operation. 
I expect some other folks using this simulation would like to forgo an 
extended boot time, to have them set/reset under programmed control. I 
was covering two bases.
> Best regards,
> 									Pavel
Sincerely -- Mark Salyzyn

  reply	other threads:[~2016-02-22 16:04 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-04 20:29 mmc: Add CONFIG_MMC_BLOCK_MAX_SPEED Mark Salyzyn
2016-02-22  6:45 ` Pavel Machek
2016-02-22 16:04   ` Mark Salyzyn [this message]
2016-02-22 17:25     ` Mark Salyzyn
2016-02-24 10:56     ` Pavel Machek

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=56CB318D.7070403@android.com \
    --to=salyzyn@android.com \
    --cc=adrian.hunter@intel.com \
    --cc=andriy.shevchenko@linux.intel.com \
    --cc=chuanxiao.dong@intel.com \
    --cc=grundler@chromium.org \
    --cc=jonathanh@nvidia.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=lporzio@micron.com \
    --cc=pavel@ucw.cz \
    --cc=shawn.lin@rock-chips.com \
    --cc=ulf.hansson@linaro.org \
    --cc=yalin.wang2010@gmail.com \
    --cc=yunpeng.gao@intel.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;
as well as URLs for NNTP newsgroup(s).