<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/fs/exfat, branch v5.10</title>
<subtitle>Linux kernel source tree</subtitle>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/'/>
<entry>
<title>Merge branch 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs</title>
<updated>2020-10-24T19:26:05+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@linux-foundation.org</email>
</author>
<published>2020-10-24T19:26:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=0eac1102e94807023e57d032bbba51830928b78e'/>
<id>0eac1102e94807023e57d032bbba51830928b78e</id>
<content type='text'>
Pull misc vfs updates from Al Viro:
 "Assorted stuff all over the place (the largest group here is
  Christoph's stat cleanups)"

* 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  fs: remove KSTAT_QUERY_FLAGS
  fs: remove vfs_stat_set_lookup_flags
  fs: move vfs_fstatat out of line
  fs: implement vfs_stat and vfs_lstat in terms of vfs_fstatat
  fs: remove vfs_statx_fd
  fs: omfs: use kmemdup() rather than kmalloc+memcpy
  [PATCH] reduce boilerplate in fsid handling
  fs: Remove duplicated flag O_NDELAY occurring twice in VALID_OPEN_FLAGS
  selftests: mount: add nosymfollow tests
  Add a "nosymfollow" mount option.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Pull misc vfs updates from Al Viro:
 "Assorted stuff all over the place (the largest group here is
  Christoph's stat cleanups)"

* 'work.misc' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs:
  fs: remove KSTAT_QUERY_FLAGS
  fs: remove vfs_stat_set_lookup_flags
  fs: move vfs_fstatat out of line
  fs: implement vfs_stat and vfs_lstat in terms of vfs_fstatat
  fs: remove vfs_statx_fd
  fs: omfs: use kmemdup() rather than kmalloc+memcpy
  [PATCH] reduce boilerplate in fsid handling
  fs: Remove duplicated flag O_NDELAY occurring twice in VALID_OPEN_FLAGS
  selftests: mount: add nosymfollow tests
  Add a "nosymfollow" mount option.
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: remove useless check in exfat_move_file()</title>
<updated>2020-10-21T23:29:12+00:00</updated>
<author>
<name>Tetsuhiro Kohada</name>
<email>kohada.t2@gmail.com</email>
</author>
<published>2020-09-11T04:45:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=eae503f7eb0509594076a951e422e29082385c96'/>
<id>eae503f7eb0509594076a951e422e29082385c96</id>
<content type='text'>
In exfat_move_file(), the identity of source and target directory has been
checked by the caller.
Also, it gets stream.start_clu from file dir-entry, which is an invalid
determination.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In exfat_move_file(), the identity of source and target directory has been
checked by the caller.
Also, it gets stream.start_clu from file dir-entry, which is an invalid
determination.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: remove 'rwoffset' in exfat_inode_info</title>
<updated>2020-10-21T23:29:11+00:00</updated>
<author>
<name>Tetsuhiro Kohada</name>
<email>kohada.t2@gmail.com</email>
</author>
<published>2020-09-17T01:39:16+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=04cee52fb8bdbdb0506460f191ed6fd9e6faf00b'/>
<id>04cee52fb8bdbdb0506460f191ed6fd9e6faf00b</id>
<content type='text'>
Remove 'rwoffset' in exfat_inode_info and replace it with the parameter of
exfat_readdir().
Since rwoffset is referenced only by exfat_readdir(), it is not necessary
a exfat_inode_info's member.
Also, change cpos to point to the next of entry-set, and return the index
of dir-entry via dir_entry-&gt;entry.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Remove 'rwoffset' in exfat_inode_info and replace it with the parameter of
exfat_readdir().
Since rwoffset is referenced only by exfat_readdir(), it is not necessary
a exfat_inode_info's member.
Also, change cpos to point to the next of entry-set, and return the index
of dir-entry via dir_entry-&gt;entry.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: replace memcpy with structure assignment</title>
<updated>2020-10-21T23:29:11+00:00</updated>
<author>
<name>Tetsuhiro Kohada</name>
<email>kohada.t2@gmail.com</email>
</author>
<published>2020-09-11T04:45:19+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=a7a241686c8f8142afafbd5fa5b9b9b6ea1aa173'/>
<id>a7a241686c8f8142afafbd5fa5b9b9b6ea1aa173</id>
<content type='text'>
Use structure assignment instead of memcpy.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Use structure assignment instead of memcpy.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: remove useless directory scan in exfat_add_entry()</title>
<updated>2020-10-21T23:29:11+00:00</updated>
<author>
<name>Tetsuhiro Kohada</name>
<email>kohada.t2@gmail.com</email>
</author>
<published>2020-09-11T04:44:39+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=6c958a09555515684947d94bfcfa8e8a414f0572'/>
<id>6c958a09555515684947d94bfcfa8e8a414f0572</id>
<content type='text'>
There is nothing in directory just created, so there is no need to scan.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
There is nothing in directory just created, so there is no need to scan.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: eliminate dead code in exfat_find()</title>
<updated>2020-10-21T23:29:11+00:00</updated>
<author>
<name>Tetsuhiro Kohada</name>
<email>kohada.t2@gmail.com</email>
</author>
<published>2020-09-02T07:53:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=188df41f212c9282f6cb05b832383ffca3c66893'/>
<id>188df41f212c9282f6cb05b832383ffca3c66893</id>
<content type='text'>
The exfat_find_dir_entry() called by exfat_find() doesn't return -EEXIST.
Therefore, the root-dir information setting is never executed.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The exfat_find_dir_entry() called by exfat_find() doesn't return -EEXIST.
Therefore, the root-dir information setting is never executed.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Acked-by: Sungjong Seo &lt;sj1557.seo@samsung.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: use i_blocksize() to get blocksize</title>
<updated>2020-10-21T23:29:10+00:00</updated>
<author>
<name>Xianting Tian</name>
<email>tian.xianting@h3c.com</email>
</author>
<published>2020-08-15T10:57:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=45882a6a0dbd1189defae1a449152f8a8168c274'/>
<id>45882a6a0dbd1189defae1a449152f8a8168c274</id>
<content type='text'>
We alreday has the interface i_blocksize() to get blocksize,
so use it.

Signed-off-by: Xianting Tian &lt;tian.xianting@h3c.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
We alreday has the interface i_blocksize() to get blocksize,
so use it.

Signed-off-by: Xianting Tian &lt;tian.xianting@h3c.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: fix misspellings using codespell tool</title>
<updated>2020-10-21T23:29:10+00:00</updated>
<author>
<name>Namjae Jeon</name>
<email>namjae.jeon@samsung.com</email>
</author>
<published>2020-08-14T02:03:46+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=9e456aeaacb6b44c5d8f858800d53c1958daad3d'/>
<id>9e456aeaacb6b44c5d8f858800d53c1958daad3d</id>
<content type='text'>
Sedat reported typos using codespell tool.

 $ codespell fs/exfat/*.c | grep -v iput
 fs/exfat/namei.c:293: upto ==&gt; up to
 fs/exfat/nls.c:14: tabel ==&gt; table

 $ codespell fs/exfat/*.h
 fs/exfat/exfat_fs.h:133: usally ==&gt; usually

Fix typos found by codespell.

Reported-by: Sedat Dilek &lt;sedat.dilek@gmail.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Sedat reported typos using codespell tool.

 $ codespell fs/exfat/*.c | grep -v iput
 fs/exfat/namei.c:293: upto ==&gt; up to
 fs/exfat/nls.c:14: tabel ==&gt; table

 $ codespell fs/exfat/*.h
 fs/exfat/exfat_fs.h:133: usally ==&gt; usually

Fix typos found by codespell.

Reported-by: Sedat Dilek &lt;sedat.dilek@gmail.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: fix use of uninitialized spinlock on error path</title>
<updated>2020-10-07T05:27:13+00:00</updated>
<author>
<name>Namjae Jeon</name>
<email>namjae.jeon@samsung.com</email>
</author>
<published>2020-09-29T00:09:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=8ff006e57ad3a25f909c456d053aa498b6673a39'/>
<id>8ff006e57ad3a25f909c456d053aa498b6673a39</id>
<content type='text'>
syzbot reported warning message:

Call Trace:
 __dump_stack lib/dump_stack.c:77 [inline]
 dump_stack+0x1d6/0x29e lib/dump_stack.c:118
 register_lock_class+0xf06/0x1520 kernel/locking/lockdep.c:893
 __lock_acquire+0xfd/0x2ae0 kernel/locking/lockdep.c:4320
 lock_acquire+0x148/0x720 kernel/locking/lockdep.c:5029
 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline]
 _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:151
 spin_lock include/linux/spinlock.h:354 [inline]
 exfat_cache_inval_inode+0x30/0x280 fs/exfat/cache.c:226
 exfat_evict_inode+0x124/0x270 fs/exfat/inode.c:660
 evict+0x2bb/0x6d0 fs/inode.c:576
 exfat_fill_super+0x1e07/0x27d0 fs/exfat/super.c:681
 get_tree_bdev+0x3e9/0x5f0 fs/super.c:1342
 vfs_get_tree+0x88/0x270 fs/super.c:1547
 do_new_mount fs/namespace.c:2875 [inline]
 path_mount+0x179d/0x29e0 fs/namespace.c:3192
 do_mount fs/namespace.c:3205 [inline]
 __do_sys_mount fs/namespace.c:3413 [inline]
 __se_sys_mount+0x126/0x180 fs/namespace.c:3390
 do_syscall_64+0x31/0x70 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

If exfat_read_root() returns an error, spinlock is used in
exfat_evict_inode() without initialization. This patch combines
exfat_cache_init_inode() with exfat_inode_init_once() to initialize
spinlock by slab constructor.

Fixes: c35b6810c495 ("exfat: add exfat cache")
Cc: stable@vger.kernel.org # v5.7+
Reported-by: syzbot &lt;syzbot+b91107320911a26c9a95@syzkaller.appspotmail.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
syzbot reported warning message:

Call Trace:
 __dump_stack lib/dump_stack.c:77 [inline]
 dump_stack+0x1d6/0x29e lib/dump_stack.c:118
 register_lock_class+0xf06/0x1520 kernel/locking/lockdep.c:893
 __lock_acquire+0xfd/0x2ae0 kernel/locking/lockdep.c:4320
 lock_acquire+0x148/0x720 kernel/locking/lockdep.c:5029
 __raw_spin_lock include/linux/spinlock_api_smp.h:142 [inline]
 _raw_spin_lock+0x2a/0x40 kernel/locking/spinlock.c:151
 spin_lock include/linux/spinlock.h:354 [inline]
 exfat_cache_inval_inode+0x30/0x280 fs/exfat/cache.c:226
 exfat_evict_inode+0x124/0x270 fs/exfat/inode.c:660
 evict+0x2bb/0x6d0 fs/inode.c:576
 exfat_fill_super+0x1e07/0x27d0 fs/exfat/super.c:681
 get_tree_bdev+0x3e9/0x5f0 fs/super.c:1342
 vfs_get_tree+0x88/0x270 fs/super.c:1547
 do_new_mount fs/namespace.c:2875 [inline]
 path_mount+0x179d/0x29e0 fs/namespace.c:3192
 do_mount fs/namespace.c:3205 [inline]
 __do_sys_mount fs/namespace.c:3413 [inline]
 __se_sys_mount+0x126/0x180 fs/namespace.c:3390
 do_syscall_64+0x31/0x70 arch/x86/entry/common.c:46
 entry_SYSCALL_64_after_hwframe+0x44/0xa9

If exfat_read_root() returns an error, spinlock is used in
exfat_evict_inode() without initialization. This patch combines
exfat_cache_init_inode() with exfat_inode_init_once() to initialize
spinlock by slab constructor.

Fixes: c35b6810c495 ("exfat: add exfat cache")
Cc: stable@vger.kernel.org # v5.7+
Reported-by: syzbot &lt;syzbot+b91107320911a26c9a95@syzkaller.appspotmail.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>exfat: fix pointer error checking</title>
<updated>2020-10-07T05:26:55+00:00</updated>
<author>
<name>Tetsuhiro Kohada</name>
<email>kohada.t2@gmail.com</email>
</author>
<published>2020-08-26T01:18:29+00:00</published>
<link rel='alternate' type='text/html' href='https://git.tavy.me/linux.git/commit/?id=d6c9efd92443b23307995f34246c2374056ebbd8'/>
<id>d6c9efd92443b23307995f34246c2374056ebbd8</id>
<content type='text'>
Fix missing result check of exfat_build_inode().
And use PTR_ERR_OR_ZERO instead of PTR_ERR.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Fix missing result check of exfat_build_inode().
And use PTR_ERR_OR_ZERO instead of PTR_ERR.

Signed-off-by: Tetsuhiro Kohada &lt;kohada.t2@gmail.com&gt;
Signed-off-by: Namjae Jeon &lt;namjae.jeon@samsung.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
