All of lore.kernel.org
 help / color / mirror / Atom feed
From: Chao Yu <chao2.yu@samsung.com>
To: 'He YunLei' <heyunlei@huawei.com>,
	jaegeuk@kernel.org, linux-f2fs-devel@lists.sourceforge.net
Cc: 'Biao He' <hebiao6@huawei.com>
Subject: Re: [PATCH] f2fs: avoid hungtask problem caused by losing wake_up
Date: Thu, 25 Feb 2016 17:41:26 +0800	[thread overview]
Message-ID: <013101d16fb0$ceb54b10$6c1fe130$@samsung.com> (raw)
In-Reply-To: <56CEAEE7.2060501@huawei.com>

Hi Yunlei,

> -----Original Message-----
> From: He YunLei [mailto:heyunlei@huawei.com]
> Sent: Thursday, February 25, 2016 3:36 PM
> To: Chao Yu; jaegeuk@kernel.org; linux-f2fs-devel@lists.sourceforge.net
> Cc: bintian.wang@huawei.com; 'Biao He'
> Subject: Re: [f2fs-dev] [PATCH] f2fs: avoid hungtask problem caused by losing wake_up
> 
> On 2016/2/24 11:46, Chao Yu wrote:
> >>> > >
> >>> > >But I doubt more that the reason we are stuck is there are remained pages
> >>> > >cached in bio buffer without being submitted. To make sure, maybe in
> >>> > >wait_on_all_pages_writeback we could add print info to see whether
> >>> > >sbi->write_io[].bio is valid or not.
> >>> > >
> >> >We use tool dump f2fs_sb_info information and find that:
> >> >
> >> >	write_io[DATA].bio = 0;
> >> >	write_io[NODE].bio = 0;
> >> >	write_io[META].bio = 0;
> >> >
> >> >	nr_pages[F2FS_WRITEBACK] = 0;
> >> >	nr_pages[F2FS_DIRTY_DENTS] = 0;
> >> >	nr_pages[F2FS_DIRTY_NODES] = 13;
> > Weird, dirty nodes count should be 0.
> >
> > Thanks
> >
> Hi Chao,
> 
> In our code,
> 
> 1524 static int f2fs_write_end(struct file *file,
> 1525                         struct address_space *mapping,
> 1526                         loff_t pos, unsigned len, unsigned copied,
> 1527                         struct page *page, void *fsdata)
> 1528 {
> 1529         struct inode *inode = page->mapping->host;
> 1530
> 1531         trace_f2fs_write_end(inode, pos, len, copied);
> 1532
> 1533         set_page_dirty(page);
> 1534
> 1535         if (pos + copied > i_size_read(inode)) {
> 1536                 i_size_write(inode, pos + copied);
> 1537                 mark_inode_dirty(inode);
> 1538                 update_inode_page(inode);
> 1539         }
> 1540
> 1541         f2fs_put_page(page, 1);
> 1542         return copied;
> 1543 }
> 
> Here update_inode_page(inode) has been removed by Kim, maybe here could
> result dirty node page is not zero.

As your hint, I found an issue in f2fs_write_inode which may be related to
our problem. I wrote a patch for fixing.

Thanks,

> 
> Thanks,
> 
> >> >	nr_pages[F2FS_DIRTY_META] = 0;
> >> >	nr_pages[F2FS_INMEM_PAGES] = 0;
> >> >
> >> >So we believe that the block device is ok!
> >> >
> >> >Thanks,



------------------------------------------------------------------------------
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=272487151&iu=/4140

  reply	other threads:[~2016-02-25  9:42 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-23  4:07 [PATCH] f2fs: avoid hungtask problem caused by losing wake_up Yunlei He
2016-02-23  5:44 ` Chao Yu
2016-02-23  7:02   ` He YunLei
2016-02-23  9:15     ` Chao Yu
2016-02-23 11:36       ` He YunLei
2016-02-24  3:46         ` Chao Yu
2016-02-24  7:32           ` He YunLei
2016-02-24  8:05             ` Chao Yu
2016-02-24  9:45               ` hebiao (G)
2016-02-25  9:32                 ` Chao Yu
2016-02-25  7:36           ` He YunLei
2016-02-25  9:41             ` Chao Yu [this message]
2016-02-25 19:03               ` Jaegeuk Kim
2016-02-26  1:15                 ` Chao Yu
2016-02-23  9:32     ` Shawn Lin
2016-02-23 11:45       ` He YunLei

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='013101d16fb0$ceb54b10$6c1fe130$@samsung.com' \
    --to=chao2.yu@samsung.com \
    --cc=hebiao6@huawei.com \
    --cc=heyunlei@huawei.com \
    --cc=jaegeuk@kernel.org \
    --cc=linux-f2fs-devel@lists.sourceforge.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.