On Wed, 2013-04-17 at 12:57 -0700, Andrew Morton wrote:
> On Wed, 17 Apr 2013 12:13:36 +0400 Vyacheslav Dubeyko <[email protected]> 
> wrote:
> 
> > +   BUG_ON(!test_bit(PG_locked, &page->flags));
> 
> The fs should be using PageLocked() here.

Yes, I agree. Please, find correction patch below.

With the best regards,
Vyacheslav Dubeyko.
---
From: Vyacheslav Dubeyko <[email protected]>
Subject: [PATCH] nilfs2: fix using of PageLocked() in nilfs_clear_dirty_page()

This patch changes test_bit(PG_locked, &page->flags) on PageLocked().

Signed-off-by: Vyacheslav Dubeyko <[email protected]>
---
 fs/nilfs2/page.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/fs/nilfs2/page.c b/fs/nilfs2/page.c
index 2a2187f..a1db80f 100644
--- a/fs/nilfs2/page.c
+++ b/fs/nilfs2/page.c
@@ -407,7 +407,7 @@ void nilfs_clear_dirty_page(struct page *page, bool silent)
        struct inode *inode = page->mapping->host;
        struct super_block *sb = inode->i_sb;
 
-       BUG_ON(!test_bit(PG_locked, &page->flags));
+       BUG_ON(!PageLocked(page));
 
        if (!silent) {
                nilfs_warning(sb, __func__,
-- 
1.7.9.5



--
To unsubscribe from this list: send the line "unsubscribe linux-nilfs" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to