From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jens Axboe Subject: Re: [PATCH 7/7] ext4: add support for write stream IDs Date: Thu, 26 Mar 2015 14:39:10 -0600 Message-ID: <55146E6E.4020106@fb.com> References: <1427296070-8472-1-git-send-email-axboe@fb.com> <1427296070-8472-8-git-send-email-axboe@fb.com> <3A47B4705F6BE24CBB43C61AA7328621506A97@SSIEXCH-MB3.ssi.samsung.com> Mime-Version: 1.0 Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit Cc: "david@fromorbit.com" To: Ming Lin-SSI , "linux-kernel@vger.kernel.org" , "linux-fsdevel@vger.kernel.org" Return-path: In-Reply-To: <3A47B4705F6BE24CBB43C61AA7328621506A97@SSIEXCH-MB3.ssi.samsung.com> Sender: linux-kernel-owner@vger.kernel.org List-Id: linux-fsdevel.vger.kernel.org On 03/26/2015 02:34 PM, Ming Lin-SSI wrote: >> -----Original Message----- >> From: Jens Axboe [mailto:axboe@fb.com] >> Sent: Wednesday, March 25, 2015 8:08 AM >> To: linux-kernel@vger.kernel.org; linux-fsdevel@vger.kernel.org >> Cc: Ming Lin-SSI; david@fromorbit.com; Jens Axboe >> Subject: [PATCH 7/7] ext4: add support for write stream IDs >> >> Signed-off-by: Jens Axboe >> --- >> fs/ext4/page-io.c | 1 + >> 1 file changed, 1 insertion(+) >> >> diff --git a/fs/ext4/page-io.c b/fs/ext4/page-io.c index >> b24a2541a9ba..f642d0b87a32 100644 >> --- a/fs/ext4/page-io.c >> +++ b/fs/ext4/page-io.c >> @@ -390,6 +390,7 @@ submit_and_retry: >> ret = io_submit_init_bio(io, bh); >> if (ret) >> return ret; >> + bio_set_streamid(io->io_bio, inode_streamid(inode)); > > For "writeback" and "ordered" journal mode, it should be OK. > > But for "journal" journal mode, > Step1: data written to journal > Step2: data written from journal to fs > > Do we need other code to carry stream_id in step2? For either mode, arguably the journal should be written with its own stream ID. But that's a subject that the filesystem guys need to tackle, once the support is one. For the case of maintaining stream ID when in data=journal mode and copying the data out, I doubt that a use case that anyone would care about. If they do, the ext4/3 guys would need to sort that out. I'll update the commit message to reflect that, it is a bit under explained at the moment. -- Jens Axboe