[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110714230854.GA29160@quack.suse.cz>
Date: Fri, 15 Jul 2011 01:08:54 +0200
From: Jan Kara <jack@...e.cz>
To: Curt Wohlgemuth <curtw@...gle.com>
Cc: Jan Kara <jack@...e.cz>, Christoph Hellwig <hch@...radead.org>,
Al Viro <viro@...iv.linux.org.uk>,
linux-fsdevel@...r.kernel.org, linux-kernel@...r.kernel.org,
fengguang.wu@...el.com
Subject: Re: [PATCH] writeback: Don't wait for completion in
writeback_inodes_sb_nr
Hi Curt,
On Thu 14-07-11 09:29:34, Curt Wohlgemuth wrote:
> On Tue, Jul 12, 2011 at 3:37 PM, Jan Kara <jack@...e.cz> wrote:
> > On Tue 12-07-11 06:41:32, Christoph Hellwig wrote:
> >> On Tue, Jul 12, 2011 at 12:34:53PM +0200, Jan Kara wrote:
> >> > > All block device inodes sit on blockdev_superblock, we got rid of inodes
> >> > > without a superblock long time ago.
> >> > Sure, we can easily iterate also blockdev_superblock. What I meant is
> >> > that blockdev_superblock will need a special handling since we otherwise
> >> > ignore pseudo superblocks...
> >>
> >> Pseudo superblocks aren't ignored. They are added to super_blocks like
> >> all others, and iterate_supers doesn't skip over them. The problem
> >> is that blockdev_superblock doesn't have a proper s_bdi set, and thus
> >> gets skipped over by __sync_filesystem.
> > Yes. But even if it was not skipped writeback_inodes_sb() doesn't have
> > one flusher thread to kick to actually do the writeout (since each inode on
> > blockdev_superblock belongs to a different bdi). So it's perfectly fine we
> > skip blockdev_superblock.
> >
> > If we want to fix the problem something like attached patch should do.
> > Comments?
>
> Your patch looks good to me, in that it does hit all the bdevs with
> both WB_SYNC_NONE and SYNC_ALL. However, I still say that the call to
> wakeup_flusher_threads() in sys_sync() is superfluous, at least as
> long as writeback_inodes_sb() waits for completion of the work item
> that it enqueues.
Actually, it's the other way around writeback_inodes_sb() is superfluous
because of wakeup_flusher_threads(). So something like attached patch could
improve sync times (especially in presence of other IO). So far I have only
checked that sync times look reasonable with it but didn't really compare
them with original kernel...
Honza
--
Jan Kara <jack@...e.cz>
SUSE Labs, CR
View attachment "0001-vfs-Avoid-unnecessary-WB_SYNC_NONE-writeback-during-.patch" of type "text/x-patch" (3593 bytes)
Powered by blists - more mailing lists