Re: INFO: task hung in generic_file_write_iter

From: Tetsuo Handa
Date: Fri Jul 20 2018 - 06:37:30 EST


On 2018/07/18 19:28, Tetsuo Handa wrote:
> There are many reports which are stalling inside __getblk_gfp().

Currently 18 reports out of 65 "INFO: task hung in " reports.

INFO: task hung in aead_recvmsg
INFO: task hung in inode_sleep_on_writeback
INFO: task hung in __writeback_inodes_sb_nr
INFO: task hung in __blkdev_get (2)
INFO: task hung in lookup_slow
INFO: task hung in iterate_supers
INFO: task hung in flush_work
INFO: task hung in vfs_setxattr
INFO: task hung in lock_mount
INFO: task hung in __get_super
INFO: task hung in do_unlinkat
INFO: task hung in fat_fallocate
INFO: task hung in generic_file_write_iter
INFO: task hung in d_alloc_parallel
INFO: task hung in __fdget_pos (2)
INFO: task hung in path_openat
INFO: task hung in do_truncate
INFO: task hung in filename_create

> And there is horrible comment for __getblk_gfp():
>
> /*
> * __getblk_gfp() will locate (and, if necessary, create) the buffer_head
> * which corresponds to the passed block_device, block and size. The
> * returned buffer has its reference count incremented.
> *
> * __getblk_gfp() will lock up the machine if grow_dev_page's
> * try_to_free_buffers() attempt is failing. FIXME, perhaps?
> */
>
> This report is stalling after mount() completed and process used remap_file_pages().
> I think that we might need to use debug printk(). But I don't know what to examine.
>

Andrew, can you pick up this debug printk() patch?
I guess we can get the result within one week.