public inbox for linux-mmc@vger.kernel.org
 help / color / mirror / Atom feed
From: Tanya Brokhman <tlinder@codeaurora.org>
To: Tejun Heo <tj@kernel.org>
Cc: Jens Axboe <axboe@kernel.dk>,
	linux-mmc@vger.kernel.org, merez@codeaurora.org,
	kdorfman@codeaurora.org
Subject: Re: FLUSH mechanism implementation in block layer
Date: Mon, 08 Apr 2013 07:19:19 +0300	[thread overview]
Message-ID: <51624547.6000500@codeaurora.org> (raw)
In-Reply-To: <20130407163345.GC12038@htj.dyndns.org>

Hi Tejun,

Thank you for the prompt response.
>
> Which version of kernel are you looking at?  The barrier / flush
> implementation went through several iterations and in the current
> iteration ordering of requests around the flush request is the
> responsibility of higher layer - ie. filesystems are required to wait
> for completions of commands which should come before flush before
> issuing it.
>
> Thanks.
>


That is the conclusion I came to as well. I was looking at kernel3.4 but 
if I'm not mistaken it's the same at kernel3.7 as well.
Could you please tell me why it was designed this way? It seems to me 
that if the application is issuing async requests it shouldn't be the 
applications responsibility to wait for their completion if the 
execution order is important. I mean, it feels like the FLUSH should be 
implemented by the lower layers (block, device driver, card) and in the 
current situation, you may say that FLUSH is partially implemented by 
the application.
At first I didn't understand why in case of FLUSH the elevator is not 
drained. Later I understood that it's not efficient since there might be 
requests from other tasks as well there that can be completed after the 
FLUSH. But perhaps there is a correct way to move the implementation of 
"ordering around the flush" to the block layer? Not that it would work 
better, it just feels that logically - block layer is the place to do it 
at.
What do you think?

Best Regards,
Tanya Brokhman
-- 
QUALCOMM ISRAEL, on behalf of Qualcomm Innovation Center, Inc. is a member
of Code Aurora Forum, hosted by The Linux Foundation

  reply	other threads:[~2013-04-08  4:19 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-04-07 13:15 FLUSH mechanism implementation in block layer Tanya Brokhman
2013-04-07 16:33 ` Tejun Heo
2013-04-08  4:19   ` Tanya Brokhman [this message]
2013-04-09 19:03     ` Tejun Heo
2013-04-10  6:13       ` Tanya Brokhman

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=51624547.6000500@codeaurora.org \
    --to=tlinder@codeaurora.org \
    --cc=axboe@kernel.dk \
    --cc=kdorfman@codeaurora.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=merez@codeaurora.org \
    --cc=tj@kernel.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