<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux.git/fs/erofs/data.c, branch v5.4.158</title>
<subtitle>Clone of https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git</subtitle>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/'/>
<entry>
<title>erofs: avoid using generic_block_bmap</title>
<updated>2020-12-30T10:51:23+00:00</updated>
<author>
<name>Huang Jianan</name>
<email>huangjianan@oppo.com</email>
</author>
<published>2020-12-09T11:57:40+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=6daf2d466380c31a39b46b72fa830d62e8417f31'/>
<id>6daf2d466380c31a39b46b72fa830d62e8417f31</id>
<content type='text'>
[ Upstream commit d8b3df8b1048405e73558b88cba2adf29490d468 ]

Surprisingly, `block' in sector_t indicates the number of
i_blkbits-sized blocks rather than sectors for bmap.

In addition, considering buffer_head limits mapped size to 32-bits,
should avoid using generic_block_bmap.

Link: https://lore.kernel.org/r/20201209115740.18802-1-huangjianan@oppo.com
Fixes: 9da681e017a3 ("staging: erofs: support bmap")
Reviewed-by: Chao Yu &lt;yuchao0@huawei.com&gt;
Reviewed-by: Gao Xiang &lt;hsiangkao@redhat.com&gt;
Signed-off-by: Huang Jianan &lt;huangjianan@oppo.com&gt;
Signed-off-by: Guo Weichao &lt;guoweichao@oppo.com&gt;
[ Gao Xiang: slightly update the commit message description. ]
Signed-off-by: Gao Xiang &lt;hsiangkao@redhat.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[ Upstream commit d8b3df8b1048405e73558b88cba2adf29490d468 ]

Surprisingly, `block' in sector_t indicates the number of
i_blkbits-sized blocks rather than sectors for bmap.

In addition, considering buffer_head limits mapped size to 32-bits,
should avoid using generic_block_bmap.

Link: https://lore.kernel.org/r/20201209115740.18802-1-huangjianan@oppo.com
Fixes: 9da681e017a3 ("staging: erofs: support bmap")
Reviewed-by: Chao Yu &lt;yuchao0@huawei.com&gt;
Reviewed-by: Gao Xiang &lt;hsiangkao@redhat.com&gt;
Signed-off-by: Huang Jianan &lt;huangjianan@oppo.com&gt;
Signed-off-by: Guo Weichao &lt;guoweichao@oppo.com&gt;
[ Gao Xiang: slightly update the commit message description. ]
Signed-off-by: Gao Xiang &lt;hsiangkao@redhat.com&gt;
Signed-off-by: Sasha Levin &lt;sashal@kernel.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: fix erofs_get_meta_page locking due to a cleanup</title>
<updated>2019-09-30T20:54:33+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-21T18:43:55+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=55252ab72b774119afedfdc6d1f142ffa2a9b818'/>
<id>55252ab72b774119afedfdc6d1f142ffa2a9b818</id>
<content type='text'>
After doing more drop_caches stress test on
our products, I found the mistake introduced by
a very recent cleanup [1].

The current rule is that "erofs_get_meta_page"
should be returned with page locked (although
it's mostly unnecessary for read-only fs after
pages are PG_uptodate), but a fix should be
done for this.

[1] https://lore.kernel.org/r/20190904020912.63925-26-gaoxiang25@huawei.com
Fixes: 618f40ea026b ("erofs: use read_cache_page_gfp for erofs_get_meta_page")
Reviewed-by: Chao Yu &lt;yuchao0@huawei.com&gt;
Link: https://lore.kernel.org/r/20190921184355.149928-1-gaoxiang25@huawei.com
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
After doing more drop_caches stress test on
our products, I found the mistake introduced by
a very recent cleanup [1].

The current rule is that "erofs_get_meta_page"
should be returned with page locked (although
it's mostly unnecessary for read-only fs after
pages are PG_uptodate), but a fix should be
done for this.

[1] https://lore.kernel.org/r/20190904020912.63925-26-gaoxiang25@huawei.com
Fixes: 618f40ea026b ("erofs: use read_cache_page_gfp for erofs_get_meta_page")
Reviewed-by: Chao Yu &lt;yuchao0@huawei.com&gt;
Link: https://lore.kernel.org/r/20190921184355.149928-1-gaoxiang25@huawei.com
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: use read_cache_page_gfp for erofs_get_meta_page</title>
<updated>2019-09-05T18:10:09+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-04T02:09:12+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=618f40ea026bda2866b2b1bc8ae2c7343a3d7a22'/>
<id>618f40ea026bda2866b2b1bc8ae2c7343a3d7a22</id>
<content type='text'>
As Christoph said [1], "I'd much prefer to just use
read_cache_page_gfp, and live with the fact that this
allocates bufferheads behind you for now.  I'll try to
speed up my attempts to get rid of the buffer heads on
the block device mapping instead. "

This simplifies the code a lot and a minor thing is
"no REQ_META (e.g. for blktrace) on metadata at all..."

[1] https://lore.kernel.org/r/20190903153704.GA2201@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-26-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As Christoph said [1], "I'd much prefer to just use
read_cache_page_gfp, and live with the fact that this
allocates bufferheads behind you for now.  I'll try to
speed up my attempts to get rid of the buffer heads on
the block device mapping instead. "

This simplifies the code a lot and a minor thing is
"no REQ_META (e.g. for blktrace) on metadata at all..."

[1] https://lore.kernel.org/r/20190903153704.GA2201@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-26-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: rename errln/infoln/debugln to erofs_{err, info, dbg}</title>
<updated>2019-09-05T18:10:09+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-04T02:09:09+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=4f761fa253b49f657de7ef6f695a124e08e56c3a'/>
<id>4f761fa253b49f657de7ef6f695a124e08e56c3a</id>
<content type='text'>
Add prefix "erofs_" to these functions and print
sb-&gt;s_id as a prefix to erofs_{err, info} so that
the user knows which file system is affected.

Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-23-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add prefix "erofs_" to these functions and print
sb-&gt;s_id as a prefix to erofs_{err, info} so that
the user knows which file system is affected.

Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-23-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: kill all erofs specific fault injection</title>
<updated>2019-09-05T18:10:08+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-04T02:09:06+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=e2c71e74b21e4053c18ac99ee93139d0aa95c53a'/>
<id>e2c71e74b21e4053c18ac99ee93139d0aa95c53a</id>
<content type='text'>
As Christoph suggested [1], "Please just use plain kmalloc
everywhere and let the normal kernel error injection code
take care of injeting any errors."

[1] https://lore.kernel.org/r/20190829102426.GE20598@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-20-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As Christoph suggested [1], "Please just use plain kmalloc
everywhere and let the normal kernel error injection code
take care of injeting any errors."

[1] https://lore.kernel.org/r/20190829102426.GE20598@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-20-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: add "erofs_" prefix for common and short functions</title>
<updated>2019-09-05T18:10:08+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-04T02:09:05+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=99634bf388db04048b83a075358a1d166e7300fb'/>
<id>99634bf388db04048b83a075358a1d166e7300fb</id>
<content type='text'>
Add erofs_ prefix to free_inode, alloc_inode, ...

Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-19-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Add erofs_ prefix to free_inode, alloc_inode, ...

Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-19-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: kill __submit_bio()</title>
<updated>2019-09-05T18:10:08+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-04T02:09:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=94e4e153b1c25a49b4953c424e6e2f66efb449f3'/>
<id>94e4e153b1c25a49b4953c424e6e2f66efb449f3</id>
<content type='text'>
As Christoph pointed out [1], "
Why is there __submit_bio which really just obsfucates
what is going on?  Also why is __submit_bio using
bio_set_op_attrs instead of opencode it as the comment
right next to it asks you to? "

Let's use submit_bio directly instead.

[1] https://lore.kernel.org/r/20190830162812.GA10694@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-18-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As Christoph pointed out [1], "
Why is there __submit_bio which really just obsfucates
what is going on?  Also why is __submit_bio using
bio_set_op_attrs instead of opencode it as the comment
right next to it asks you to? "

Let's use submit_bio directly instead.

[1] https://lore.kernel.org/r/20190830162812.GA10694@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-18-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: kill prio and nofail of erofs_get_meta_page()</title>
<updated>2019-09-05T18:10:08+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-04T02:09:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=e655b5b3a29c5a16056f13854ac3db5b39c0b804'/>
<id>e655b5b3a29c5a16056f13854ac3db5b39c0b804</id>
<content type='text'>
As Christoph pointed out [1],
"Why is there __erofs_get_meta_page with the two weird
booleans instead of a single erofs_get_meta_page that
gets and gfp_t for additional flags and an unsigned int
for additional bio op flags."

And since all callers can handle errors, let's kill
prio and nofail and erofs_get_inline_page() now.

[1] https://lore.kernel.org/r/20190830162812.GA10694@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-17-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As Christoph pointed out [1],
"Why is there __erofs_get_meta_page with the two weird
booleans instead of a single erofs_get_meta_page that
gets and gfp_t for additional flags and an unsigned int
for additional bio op flags."

And since all callers can handle errors, let's kill
prio and nofail and erofs_get_inline_page() now.

[1] https://lore.kernel.org/r/20190830162812.GA10694@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-17-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: localize erofs_grab_bio()</title>
<updated>2019-09-05T18:10:08+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-04T02:09:02+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=a5c0b7802cc9631e0dee67abd30c2f022621ae7c'/>
<id>a5c0b7802cc9631e0dee67abd30c2f022621ae7c</id>
<content type='text'>
As Christoph pointed out [1], "erofs_grab_bio tries to
handle a bio_alloc failure, except that the function will
not actually fail due the mempool backing it."

Sorry about useless code, fix it now and
localize erofs_grab_bio [2].

[1] https://lore.kernel.org/r/20190830162812.GA10694@infradead.org/
[2] https://lore.kernel.org/r/20190902122016.GL15931@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-16-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As Christoph pointed out [1], "erofs_grab_bio tries to
handle a bio_alloc failure, except that the function will
not actually fail due the mempool backing it."

Sorry about useless code, fix it now and
localize erofs_grab_bio [2].

[1] https://lore.kernel.org/r/20190830162812.GA10694@infradead.org/
[2] https://lore.kernel.org/r/20190902122016.GL15931@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-16-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>erofs: use erofs_inode naming</title>
<updated>2019-09-05T18:10:07+00:00</updated>
<author>
<name>Gao Xiang</name>
<email>gaoxiang25@huawei.com</email>
</author>
<published>2019-09-04T02:08:56+00:00</published>
<link rel='alternate' type='text/html' href='https://git.exis.tech/linux.git/commit/?id=a5876e24f13f13483fbd602b972d35801fb80b74'/>
<id>a5876e24f13f13483fbd602b972d35801fb80b74</id>
<content type='text'>
As Christoph suggested [1], "Why is this called vnode instead
of inode?  That seems like a rather odd naming for a Linux
file system."

[1] https://lore.kernel.org/r/20190829101545.GC20598@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-10-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
As Christoph suggested [1], "Why is this called vnode instead
of inode?  That seems like a rather odd naming for a Linux
file system."

[1] https://lore.kernel.org/r/20190829101545.GC20598@infradead.org/
Reported-by: Christoph Hellwig &lt;hch@infradead.org&gt;
Signed-off-by: Gao Xiang &lt;gaoxiang25@huawei.com&gt;
Link: https://lore.kernel.org/r/20190904020912.63925-10-gaoxiang25@huawei.com
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@linuxfoundation.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
