From patchwork Tue Aug 10 09:28:49 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stefan Bader X-Patchwork-Id: 61351 X-Patchwork-Delegate: stefan.bader@canonical.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from chlorine.canonical.com (chlorine.canonical.com [91.189.94.204]) by ozlabs.org (Postfix) with ESMTP id C51E9B70F9 for ; Tue, 10 Aug 2010 19:29:17 +1000 (EST) Received: from localhost ([127.0.0.1] helo=chlorine.canonical.com) by chlorine.canonical.com with esmtp (Exim 4.69) (envelope-from ) id 1Oil8v-00054K-Pq; Tue, 10 Aug 2010 10:29:09 +0100 Received: from adelie.canonical.com ([91.189.90.139]) by chlorine.canonical.com with esmtp (Exim 4.69) (envelope-from ) id 1Oil8r-00053H-Su for kernel-team@lists.ubuntu.com; Tue, 10 Aug 2010 10:29:05 +0100 Received: from hutte.canonical.com ([91.189.90.181]) by adelie.canonical.com with esmtp (Exim 4.69 #1 (Debian)) id 1Oil8r-00012t-QX; Tue, 10 Aug 2010 10:29:05 +0100 Received: from p5b2e54bf.dip.t-dialin.net ([91.46.84.191] helo=canonical.com) by hutte.canonical.com with esmtpsa (TLS-1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.69) (envelope-from ) id 1Oil8r-00052z-Kv; Tue, 10 Aug 2010 10:29:05 +0100 From: Stefan Bader To: kernel-team@lists.ubuntu.com, stable@kernel.org Subject: [PATCH 01/16] writeback: remove the always false bdi_cap_writeback_dirty() test Date: Tue, 10 Aug 2010 11:28:49 +0200 Message-Id: <1281432544-20831-2-git-send-email-stefan.bader@canonical.com> X-Mailer: git-send-email 1.7.0.4 In-Reply-To: <1281432544-20831-1-git-send-email-stefan.bader@canonical.com> References: <1281432544-20831-1-git-send-email-stefan.bader@canonical.com> Cc: axboe@kernel.dk X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.9 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: kernel-team-bounces@lists.ubuntu.com Errors-To: kernel-team-bounces@lists.ubuntu.com From: Wu Fengguang BugLink: http://bugs.launchpad.net/bugs/585092 commit 951c30d135390a108f102b0f6e3cfa6241f2a1aa upstream This is dead code because no bdi flush thread will be started for !bdi_cap_writeback_dirty bdi. Signed-off-by: Wu Fengguang Cc: Jens Axboe Cc: Trond Myklebust Cc: Christoph Hellwig Signed-off-by: Jens Axboe Signed-off-by: Stefan Bader --- fs/fs-writeback.c | 18 ------------------ 1 files changed, 0 insertions(+), 18 deletions(-) diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c index ef2acd2..596a43d 100644 --- a/fs/fs-writeback.c +++ b/fs/fs-writeback.c @@ -614,7 +614,6 @@ static void writeback_inodes_wb(struct bdi_writeback *wb, struct writeback_control *wbc) { struct super_block *sb = wbc->sb, *pin_sb = NULL; - const int is_blkdev_sb = sb_is_blkdev_sb(sb); const unsigned long start = jiffies; /* livelock avoidance */ spin_lock(&inode_lock); @@ -635,23 +634,6 @@ static void writeback_inodes_wb(struct bdi_writeback *wb, continue; } - if (!bdi_cap_writeback_dirty(wb->bdi)) { - redirty_tail(inode); - if (is_blkdev_sb) { - /* - * Dirty memory-backed blockdev: the ramdisk - * driver does this. Skip just this inode - */ - continue; - } - /* - * Dirty memory-backed inode against a filesystem other - * than the kernel-internal bdev filesystem. Skip the - * entire superblock. - */ - break; - } - if (inode->i_state & (I_NEW | I_WILL_FREE)) { requeue_io(inode); continue;