]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commitdiff
fs/fs-writeback.c: remove redundant if check
authorTahsin Erdogan <tahsin@google.com>
Tue, 13 Dec 2016 00:43:20 +0000 (16:43 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Tue, 13 Dec 2016 02:55:08 +0000 (18:55 -0800)
b_more_io non-empty check is already preceded by an opposite check.

Link: http://lkml.kernel.org/r/1478591249-30641-1-git-send-email-tahsin@google.com
Signed-off-by: Tahsin Erdogan <tahsin@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/fs-writeback.c

index 05713a5da0834233edad0049d7443dd63e6c1078..ef600591d96f9a42be98699025f4cf94ef8e7762 100644 (file)
@@ -1769,15 +1769,13 @@ static long wb_writeback(struct bdi_writeback *wb,
                 * become available for writeback. Otherwise
                 * we'll just busyloop.
                 */
-               if (!list_empty(&wb->b_more_io))  {
-                       trace_writeback_wait(wb, work);
-                       inode = wb_inode(wb->b_more_io.prev);
-                       spin_lock(&inode->i_lock);
-                       spin_unlock(&wb->list_lock);
-                       /* This function drops i_lock... */
-                       inode_sleep_on_writeback(inode);
-                       spin_lock(&wb->list_lock);
-               }
+               trace_writeback_wait(wb, work);
+               inode = wb_inode(wb->b_more_io.prev);
+               spin_lock(&inode->i_lock);
+               spin_unlock(&wb->list_lock);
+               /* This function drops i_lock... */
+               inode_sleep_on_writeback(inode);
+               spin_lock(&wb->list_lock);
        }
        spin_unlock(&wb->list_lock);
        blk_finish_plug(&plug);