<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/fs/f2fs/inode.c, branch linux-3.14.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.14.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-3.14.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2014-01-20T01:27:12Z</updated>
<entry>
<title>f2fs: clean checkpatch warnings</title>
<updated>2014-01-20T01:27:12Z</updated>
<author>
<name>Chris Fries</name>
</author>
<published>2014-01-17T20:44:39Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=6c311ec6c2d9e015d454b4e3fda8008b5bebf316'/>
<id>urn:sha1:6c311ec6c2d9e015d454b4e3fda8008b5bebf316</id>
<content type='text'>
Fixed a variety of trivial checkpatch warnings.  The only delta should
be some minor formatting on log strings that were split / too long.

Signed-off-by: Chris Fries &lt;cfries@motorola.com&gt;
Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: remove the needless parameter of f2fs_wait_on_page_writeback</title>
<updated>2014-01-14T08:45:54Z</updated>
<author>
<name>Yuan Zhong</name>
</author>
<published>2014-01-10T07:26:14Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5514f0aadddcdfaaaea697b60203f5402552eb7b'/>
<id>urn:sha1:5514f0aadddcdfaaaea697b60203f5402552eb7b</id>
<content type='text'>
"boo sync" parameter is never referenced in f2fs_wait_on_page_writeback.
We should remove this parameter.

Signed-off-by: Yuan Zhong &lt;yuan.mark.zhong@samsung.com&gt;
Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: add the number of inline_data files to status info</title>
<updated>2014-01-06T07:42:20Z</updated>
<author>
<name>Jaegeuk Kim</name>
</author>
<published>2013-11-26T02:08:57Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=0dbdc2ae9bba0a358816cc4a22e41a6ef16db8a2'/>
<id>urn:sha1:0dbdc2ae9bba0a358816cc4a22e41a6ef16db8a2</id>
<content type='text'>
This patch adds the number of inline_data files into the status information.
Note that the number is reset whenever the filesystem is newly mounted.

Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: introduce F2FS_INODE macro to get f2fs_inode</title>
<updated>2013-12-26T11:32:48Z</updated>
<author>
<name>Jaegeuk Kim</name>
</author>
<published>2013-12-26T07:30:41Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=58bfaf44df58082c72882b235cae611c975537d4'/>
<id>urn:sha1:58bfaf44df58082c72882b235cae611c975537d4</id>
<content type='text'>
This patch introduces F2FS_INODE that returns struct f2fs_inode * from the inode
page.
By using this macro, we can remove unnecessary casting codes like below.

   struct f2fs_inode *ri = &amp;F2FS_NODE(inode_page)-&gt;i;
-&gt; struct f2fs_inode *ri = F2FS_INODE(inode_page);

Reviewed-by: Chao Yu &lt;chao2.yu@samsung.com&gt;
Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: add an option to avoid unnecessary BUG_ONs</title>
<updated>2013-10-29T06:44:38Z</updated>
<author>
<name>Jaegeuk Kim</name>
</author>
<published>2013-10-29T06:14:54Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5d56b6718a0f4e5c58cdd3cb6b7a472d7c5671b9'/>
<id>urn:sha1:5d56b6718a0f4e5c58cdd3cb6b7a472d7c5671b9</id>
<content type='text'>
If you want to remove unnecessary BUG_ONs, you can just turn off F2FS_CHECK_FS
in your kernel config.

Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: fix to store and retrieve i_rdev correctly</title>
<updated>2013-10-18T00:43:38Z</updated>
<author>
<name>Jaegeuk Kim</name>
</author>
<published>2013-10-08T09:01:51Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=3d1e38073b3f33d31df1ae09aaccab3dfd9fb61e'/>
<id>urn:sha1:3d1e38073b3f33d31df1ae09aaccab3dfd9fb61e</id>
<content type='text'>
When storing i_rdev, we should check its file type.

Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: use rw_sem instead of fs_lock(locks mutex)</title>
<updated>2013-10-07T02:33:05Z</updated>
<author>
<name>Gu Zheng</name>
</author>
<published>2013-09-27T10:08:30Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=e479556bfdd136669854292eb57ed0139d7253d5'/>
<id>urn:sha1:e479556bfdd136669854292eb57ed0139d7253d5</id>
<content type='text'>
The fs_locks is used to block other ops(ex, recovery) when doing checkpoint.
And each other operate routine(besides checkpoint) needs to acquire a fs_lock,
there is a terrible problem here, if these are too many concurrency threads acquiring
fs_lock, so that they will block each other and may lead to some performance problem,
but this is not the phenomenon we want to see.
Though there are some optimization patches introduced to enhance the usage of fs_lock,
but the thorough solution is using a *rw_sem* to replace the fs_lock.
Checkpoint routine takes write_sem, and other ops take read_sem, so that we can block
other ops(ex, recovery) when doing checkpoint, and other ops will not disturb each other,
this can avoid the problem described above completely.
Because of the weakness of rw_sem, the above change may introduce a potential problem
that the checkpoint thread might get starved if other threads are intensively locking
the read semaphore for I/O.(Pointed out by Xu Jin)
In order to avoid this, a wait_list is introduced, the appending read semaphore ops
will be dropped into the wait_list if checkpoint thread is waiting for write semaphore,
and will be waked up when checkpoint thread gives up write semaphore.
Thanks to Kim's previous review and test, and will be very glad to see other guys'
performance tests about this patch.

V2:
  -fix the potential starvation problem.
  -use more suitable func name suggested by Xu Jin.

Signed-off-by: Gu Zheng &lt;guz.fnst@cn.fujitsu.com&gt;
[Jaegeuk Kim: adjust minor coding standard]
Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: add flags for inline xattrs</title>
<updated>2013-08-26T11:02:12Z</updated>
<author>
<name>Jaegeuk Kim</name>
</author>
<published>2013-08-08T06:16:22Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=444c580f7e9ad29927a5d5269d576bd7cdccebb8'/>
<id>urn:sha1:444c580f7e9ad29927a5d5269d576bd7cdccebb8</id>
<content type='text'>
This patch adds basic inode flags for inline xattrs, F2FS_INLINE_XATTR,
and add a mount option, inline_xattr, which is enabled when xattr is set.

If the mount option is enabled, all the files are marked with the inline_xattrs
flag.

Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: avoid writing inode redundantly when creating a file</title>
<updated>2013-08-19T00:43:25Z</updated>
<author>
<name>Jin Xu</name>
</author>
<published>2013-08-15T11:17:01Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=92c4342fb72a6baf9ee9fcd079b46ed0286ebe33'/>
<id>urn:sha1:92c4342fb72a6baf9ee9fcd079b46ed0286ebe33</id>
<content type='text'>
In f2fs_write_inode, updating inode after f2fs_balance_fs is not
a optimized way in the case that f2fs_gc is performed ahead. The
inode page will be unnecessarily written out twice, one of which
is in f2fs_gc-&gt;...-&gt;sync_node_pages and the other is in
update_inode_page.

Let's update the inode page in prior to f2fs_balance_fs to avoid
this.

To reproduce it,
$ touch file (before this step, should make the device need f2fs_gc)
$ sync (or wait the bdi to write dirty inode)

Signed-off-by: Jin Xu &lt;jinuxstyle@gmail.com&gt;
Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
<entry>
<title>f2fs: fix a deadlock in fsync</title>
<updated>2013-08-06T13:00:36Z</updated>
<author>
<name>Jin Xu</name>
</author>
<published>2013-08-05T12:02:04Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=a569469e967022d9ceeaa4b73619f96614087d2d'/>
<id>urn:sha1:a569469e967022d9ceeaa4b73619f96614087d2d</id>
<content type='text'>
This patch fixes a deadlock bug that occurs quite often when there are
concurrent write and fsync on a same file.

Following is the simplified call trace when tasks get hung.

fsync thread:
- f2fs_sync_file
 ...
 - f2fs_write_data_pages
 ...
  - update_extent_cache
  ...
   - update_inode
    - wait_on_page_writeback

bdi writeback thread
- __writeback_single_inode
 - f2fs_write_data_pages
  - mutex_lock(sbi-&gt;writepages)

The deadlock happens when the fsync thread waits on a inode page that has
been added to the f2fs' cached bio sbi-&gt;bio[NODE], and unfortunately,
no one else could be able to submit the cached bio to block layer for
writeback. This is because the fsync thread already hold a sbi-&gt;fs_lock and
the sbi-&gt;writepages lock, causing the bdi thread being blocked when attempt
to write data pages for the same inode. At the same time, f2fs_gc thread
does not notice the situation and could not help. Even the sync syscall
gets blocked.

To fix it, we could submit the cached bio first before waiting on a inode page
that is being written back.

Signed-off-by: Jin Xu &lt;jinuxstyle@gmail.com&gt;
[Jaegeuk Kim: add more cases to use f2fs_wait_on_page_writeback]
Signed-off-by: Jaegeuk Kim &lt;jaegeuk.kim@samsung.com&gt;
</content>
</entry>
</feed>
