[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOzFzEjCf7ZPbheq-tfhts-E=Ep1kvn0muksaaTFqJ=cMm772w@mail.gmail.com>
Date: Thu, 13 Sep 2012 09:12:25 +1000
From: Joseph Glanville <joseph.glanville@...onvm.com.au>
To: Tejun Heo <tj@...nel.org>
Cc: NeilBrown <neilb@...e.de>,
Kent Overstreet <koverstreet@...gle.com>,
Jens Axboe <axboe@...nel.dk>,
Philipp Reisner <philipp.reisner@...bit.com>,
linux-kernel@...r.kernel.org, Christoph Hellwig <hch@....de>,
Vivek Goyal <vgoyal@...hat.com>, drbd-dev@...ts.linbit.com
Subject: Re: [Drbd-dev] FLUSH/FUA documentation & code discrepancy
On 13 September 2012 04:58, Tejun Heo <tj@...nel.org> wrote:
> Hello,
>
> On Tue, Sep 11, 2012 at 10:25:01AM +0200, Lars Ellenberg wrote:
>> Or do we have a better place to document write ordering requirements?
>>
>> "To enforce write-after-write dependencies, you *have* to drain the
>> queue (do we have a generic interface available for that?),
>> or at least wait for the completion of all the requests you
>> (potentially) depend upon, before even submitting the dependent request.
>>
>> Additionally, to avoid integrity issues due to volatile caches,
>> you need to use FLUSH/FUA as appropriate."
>
> I think it would be best to note the lack of any ordering guarantee in
> the comment of bio_submit()? Any one interested in submitting a
> patch?
>
> Thanks.
>
> --
> tejun
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@...r.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.org/lkml/
Something along the lines of this?
diff --git a/block/blk-core.c b/block/blk-core.c
index 4b4dbdf..68b5671 100644
--- a/block/blk-core.c
+++ b/block/blk-core.c
@@ -1809,6 +1809,9 @@ EXPORT_SYMBOL(generic_make_request);
* uses that function to do most of the work. Both are fairly rough
* interfaces; @bio must be presetup and ready for I/O.
*
+ * Ordering of requests is not guaranteed, callers should drain the queue
+ * and issue a flush before submission of any dependent bios.
+ *
*/
void submit_bio(int rw, struct bio *bio)
{
--
CTO | Orion Virtualisation Solutions | www.orionvm.com.au
Phone: 1300 56 99 52 | Mobile: 0428 754 846
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists