Re: [PATCH 1/7] block: add queue_logical_block_mask() and bdev_logical_block_mask()

2023-06-28 Thread Yangtao Li
On 2023/6/29 0:46, Matthew Wilcox wrote: On Wed, Jun 28, 2023 at 05:34:54PM +0800, Yangtao Li wrote: Introduce queue_logical_block_mask() and bdev_logical_block_mask() to simplify code, which replace (queue_logical_block_size(q) - 1) and (bdev_logical_block_size(bdev) - 1). The thing is that

[PATCH 2/7] block: Convert to bdev_logical_block_mask()

2023-06-28 Thread Yangtao Li
Use bdev_logical_block_mask() to simplify code. Signed-off-by: Yangtao Li --- block/bio.c | 2 +- block/fops.c | 4 ++-- block/ioctl.c | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/block/bio.c b/block/bio.c index 8672179213b9..42ccf5a21696 100644 --- a/block/bio.c

[PATCH 7/7] erofs: Convert to bdev_logical_block_mask()

2023-06-28 Thread Yangtao Li
Use bdev_logical_block_mask() to simplify code. Signed-off-by: Yangtao Li --- fs/erofs/data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/erofs/data.c b/fs/erofs/data.c index db5e4b7636ec..13bd185ef3b3 100644 --- a/fs/erofs/data.c +++ b/fs/erofs/data.c @@ -387,7

[PATCH 6/7] xfs: Convert to bdev_logical_block_mask()

2023-06-28 Thread Yangtao Li
Use bdev_logical_block_mask() to simplify code. Signed-off-by: Yangtao Li --- fs/xfs/xfs_buf.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/xfs/xfs_buf.c b/fs/xfs/xfs_buf.c index 15d1e5a7c2d3..f784daa21219 100644 --- a/fs/xfs/xfs_buf.c +++ b/fs/xfs/xfs_buf.c @@ -1968,7

[PATCH 5/7] iomap: Convert to bdev_logical_block_mask()

2023-06-28 Thread Yangtao Li
Use bdev_logical_block_mask() to simplify code. Signed-off-by: Yangtao Li --- fs/iomap/direct-io.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/iomap/direct-io.c b/fs/iomap/direct-io.c index ea3b868c8355..8d4a06bc14b3 100644 --- a/fs/iomap/direct-io.c +++ b/fs/iomap

[PATCH 4/7] buffer: Convert to bdev_logical_block_mask()

2023-06-28 Thread Yangtao Li
Use bdev_logical_block_mask() to simplify code. Signed-off-by: Yangtao Li --- fs/buffer.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/buffer.c b/fs/buffer.c index bd091329026c..fd2705465a5e 100644 --- a/fs/buffer.c +++ b/fs/buffer.c @@ -1128,7 +1128,7 @@ __getblk_slow

[PATCH 1/7] block: add queue_logical_block_mask() and bdev_logical_block_mask()

2023-06-28 Thread Yangtao Li
Introduce queue_logical_block_mask() and bdev_logical_block_mask() to simplify code, which replace (queue_logical_block_size(q) - 1) and (bdev_logical_block_size(bdev) - 1). Signed-off-by: Yangtao Li --- include/linux/blkdev.h | 10 ++ 1 file changed, 10 insertions(+) diff --git a

[PATCH 3/7] md: Convert to queue_logical_block_mask()

2023-06-28 Thread Yangtao Li
Use queue_logical_block_mask() to simplify code. Signed-off-by: Yangtao Li --- drivers/md/md.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/md/md.c b/drivers/md/md.c index 2e38ef421d69..fd646e5ed082 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -1649,7

[PATCH] erofs: remove unnecessary goto

2023-06-14 Thread Yangtao Li
It's redundant, let's remove it. Signed-off-by: Yangtao Li --- fs/erofs/super.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/fs/erofs/super.c b/fs/erofs/super.c index 811ab66d805e..f48ce692094d 100644 --- a/fs/erofs/super.c +++ b/fs/erofs/super.c @

[PATCH] erofs: don't access kobject object members directly

2023-04-11 Thread Yangtao Li
It is better not to directly access the internal members of the kobject object, especially kobject_init_and_add() may failure. BTW remove unnecessary kobject_del(), kobject_put() actually covers kobject removal automatically, which is single stage removal. Signed-off-by: Yangtao Li --- fs/erofs

Re: [PATCH 2/3] erofs: convert to use kobject_is_added()

2023-04-07 Thread Yangtao Li
Hi all, > Later, I thought I could send some demo code that strips the kobject in sbi > into a pointer. I made the following modifications, not sure if I'm going the right way. diff --git a/fs/erofs/internal.h b/fs/erofs/internal.h index 1db018f8c2e8..8e1799f690c0 100644 --- a/fs/erofs/internal

Re: [PATCH 2/3] erofs: convert to use kobject_is_added()

2023-04-06 Thread Yangtao Li
Hi Greg, > just let it hang off as a separate structure (i.e. a pointer to something > else.) I have made some attempts. According to my understanding, the reason why the filesystem needs to embed the kobj structure (not a pointer) is that the kobj_to_sbi method is required in the attr_store/at

Re: [PATCH 2/3] erofs: convert to use kobject_is_added()

2023-04-06 Thread Yangtao Li
Hi Greg, > That isn't going to work, and as proof of that, the release callback > should be a simple call to kfree(), NOT as a completion notification > which then something else will go off and free the memory here. That > implies that there are multiple reference counting structures happening >

Re: [PATCH 2/3] erofs: convert to use kobject_is_added()

2023-04-06 Thread Yangtao Li
> > Meta-comment, we need to come up with a "filesystem kobject type" to get > > rid of lots of the boilerplate filesystem kobject logic as it's > > duplicated in every filesystem in tiny different ways and lots of times > > (like here), it's wrong. > > Can we add the following structure? > > str

Re: [PATCH 2/3] erofs: convert to use kobject_is_added()

2023-04-06 Thread Yangtao Li
> Meta-comment, we need to come up with a "filesystem kobject type" to get > rid of lots of the boilerplate filesystem kobject logic as it's > duplicated in every filesystem in tiny different ways and lots of times > (like here), it's wrong. Can we add the following structure? struct filesystem_k

Re: [PATCH 2/2] erofs: remove unnecessary kobject_del()

2023-04-06 Thread Yangtao Li
HI Gao Xiang, > Would you mind taking a look at > commit a942da24abc5 ("fs: erofs: add sanity check for kobject in > erofs_unregister_sysfs") > > , which could be "git-blame"ed (I'd suggest looking into these > blame first), and the related discussion was: > > https://lore.kernel.org/r/CAD-N9QXNx

[PATCH 3/3] zonefs: convert to use kobject_is_added()

2023-04-06 Thread Yangtao Li
Use kobject_is_added() instead of local `s_sysfs_registered` variables. BTW kill kobject_del() directly, because kobject_put() actually covers kobject removal automatically. Signed-off-by: Yangtao Li --- fs/zonefs/sysfs.c | 11 +-- fs/zonefs/zonefs.h | 1 - 2 files changed, 5

[PATCH 2/3] erofs: convert to use kobject_is_added()

2023-04-06 Thread Yangtao Li
Use kobject_is_added() instead of directly accessing the internal variables of kobject. BTW kill kobject_del() directly, because kobject_put() actually covers kobject removal automatically. Signed-off-by: Yangtao Li --- fs/erofs/sysfs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions

[PATCH 1/3] kobject: introduce kobject_is_added()

2023-04-06 Thread Yangtao Li
Add kobject_is_added() to avoid consumers from directly accessing the internal variables of kobject. Signed-off-by: Yangtao Li --- include/linux/kobject.h | 5 + 1 file changed, 5 insertions(+) diff --git a/include/linux/kobject.h b/include/linux/kobject.h index bdab370a24f4..b5cdb0c58729

[PATCH 2/2] erofs: remove unnecessary kobject_del()

2023-04-04 Thread Yangtao Li
kobject_put() actually covers kobject removal automatically, which is single stage removal. So it is safe to kill kobject_del() directly. Signed-off-by: Yangtao Li --- fs/erofs/sysfs.c | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c

Re: [PATCH v3 01/10] kobject: introduce kobject_del_and_put()

2023-04-04 Thread Yangtao Li
> kobject_put() actually covers kobject removal automatically, which is > single stage removal. So if you see the two called together, it is > safe to kill kobject_del() directly. If the reference count is not abnormal, kobject_put() does contain what kobject_del() does. Thx, Yangtao

[PATCH v3 03/10] erofs: convert to kobject_del_and_put()

2023-03-22 Thread Yangtao Li
Use kobject_del_and_put() to simplify code. Cc: Greg Kroah-Hartman Cc: "Rafael J. Wysocki" Cc: Damien Le Moal Signed-off-by: Yangtao Li --- fs/erofs/sysfs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c index 43

[PATCH v3 01/10] kobject: introduce kobject_del_and_put()

2023-03-22 Thread Yangtao Li
There are plenty of using kobject_del() and kobject_put() together in the kernel tree. This patch wraps these two calls in a single helper. Signed-off-by: Yangtao Li --- v3: -convert to inline helper v2: -add kobject_del_and_put() users include/linux/kobject.h | 13 + lib/kobject.c

[RESEND,PATCH v2 03/10] erofs: convert to kobject_del_and_put()

2023-03-20 Thread Yangtao Li
Use kobject_del_and_put() to simplify code. Cc: Greg Kroah-Hartman Cc: "Rafael J. Wysocki" Cc: Damien Le Moal Signed-off-by: Yangtao Li --- fs/erofs/sysfs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c index 43

[RESEND,PATCH v2 01/10] kobject: introduce kobject_del_and_put()

2023-03-20 Thread Yangtao Li
There are plenty of using kobject_del() and kobject_put() together in the kernel tree. This patch wraps these two calls in a single helper. Signed-off-by: Yangtao Li --- v2: -add kobject_del_and_put() users resend patchset to gregkh, Rafael and Damien include/linux/kobject.h | 1 + lib

Re: [PATCH v2, RESEND 01/10] kobject: introduce kobject_del_and_put()

2023-03-20 Thread Yangtao Li
Hi filesystem maintainers, > Hard to comment on patches with this. It is only 10 patches. So send > everything please. If you are interested in the entire patchset besides Damien, please let me know. I'll resend the email later to cc more people. Thx, Yangtao

Re: [PATCH v2, RESEND 01/10] kobject: introduce kobject_del_and_put()

2023-03-19 Thread Yangtao Li
Hi all, Out of consideration for minimizing disruption, I did not send the patchset to everyone. However, it seems that my consideration was unnecessary, so I CC'd everyone on the first patch. If you would like to see the entire patchset, you can access it at this address. https://lore.kernel.org

[PATCH v2, RESEND 03/10] erofs: convert to kobject_del_and_put()

2023-03-19 Thread Yangtao Li
Use kobject_del_and_put() to simplify code. Cc: Greg Kroah-Hartman Cc: "Rafael J. Wysocki" Signed-off-by: Yangtao Li --- fs/erofs/sysfs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c index 435e515c0792..9ed7d6552155 10064

[PATCH v2 03/10] erofs: convert to kobject_del_and_put()

2023-03-19 Thread Yangtao Li
Use kobject_del_and_put() to simplify code. Signed-off-by: Yangtao Li --- fs/erofs/sysfs.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/fs/erofs/sysfs.c b/fs/erofs/sysfs.c index 435e515c0792..9ed7d6552155 100644 --- a/fs/erofs/sysfs.c +++ b/fs/erofs/sysfs.c @@ -241,8

Re: erofs: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
> I can pick the stuff in the areas that don't have active development. Could you please consider helping to pick this patch("ecryptfs: make splice write available again")? ecryptfs seems to be unmaintained. https://lore.kernel.org/lkml/20220831033505.23178-1-frank...@vivo.com/ Thx, Yangtao

Re: [PATCH] ext4: convert to DIV_ROUND_UP() in mpage_process_page_bufs()

2023-03-09 Thread Yangtao Li
> Please don't do this. This makes the code compile down to a division, which > is > far less efficient. I've verified this by checking the assembly generated. How much is the performance impact? So should the following be modified as shift operations as well? fs/erofs/namei.c:92:int head

Re: [PATCH v4 2/5] erofs: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Hi Gao Xiang, > Please help drop this one since we'd like to use it until i_blockmask() lands > to upstream. I'm OK. Not sure if I need to resend v5? Thx, Yangtao

[PATCH v4 5/5] fs/remap_range: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- fs/remap_range.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/remap_range.c b/fs/remap_range.c index 1331a890f2f2..7a524b620e7d 100644 --- a/fs/remap_range.c +++ b/fs/remap_range.c @@ -127,7 +127,7

[PATCH v4 4/5] ocfs2: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. BTW convert ocfs2_is_io_unaligned to return bool type and the fact that the value will be the same (i.e. that ->i_blkbits is never changed by ocfs2). Signed-off-by: Yangtao Li --- fs/ocfs2/file.c | 9 ++--- 1 file changed, 2 insertions(+), 7 deleti

[PATCH v4 3/5] gfs2: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- fs/gfs2/bmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c index eedf6926c652..1c6874b3851a 100644 --- a/fs/gfs2/bmap.c +++ b/fs/gfs2/bmap.c @@ -960,7 +960,7 @@ static

[PATCH v4 2/5] erofs: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- fs/erofs/data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/erofs/data.c b/fs/erofs/data.c index e16545849ea7..d394102ef9de 100644 --- a/fs/erofs/data.c +++ b/fs/erofs/data.c @@ -376,7 +376,7 @@ static

[PATCH v4 1/5] fs: add i_blockmask()

2023-03-09 Thread Yangtao Li
Introduce i_blockmask() to simplify code, which replace (i_blocksize(node) - 1). Like done in commit 93407472a21b("fs: add i_blocksize()"). Signed-off-by: Yangtao Li --- v4: -drop ext4 patch -erofs patch based on mainline -a bit change in ocfs2 patch include/linux/fs.h | 5 + 1 fi

Re: erofs: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Hi AI, > Umm... What's the branchpoint for that series? > Not the mainline - there we have i_blocksize() open-coded... Sorry, I'm based on the latest branch of the erofs repository. https://git.kernel.org/pub/scm/linux/kernel/git/xiang/erofs.git/log/?h=dev-test I think I can resend based on ma

[PATCH v3 6/6] fs/remap_range: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- fs/remap_range.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/remap_range.c b/fs/remap_range.c index 1331a890f2f2..7a524b620e7d 100644 --- a/fs/remap_range.c +++ b/fs/remap_range.c @@ -127,7 +127,7

[PATCH v3 5/6] ocfs2: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. BTW convert ocfs2_is_io_unaligned to return bool type. Signed-off-by: Yangtao Li --- v3: -none fs/ocfs2/file.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c index efb09de4343d..baefab3b12c9

[PATCH v3 4/6] ext4: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- v3: -none v2: -convert to i_blockmask() fs/ext4/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index d251d705c276..eec36520e5e9 100644 --- a/fs/ext4/inode.c +++ b/fs

[PATCH v3 3/6] gfs2: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- v3: -none v2: -convert to i_blockmask() fs/gfs2/bmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c index eedf6926c652..1c6874b3851a 100644 --- a/fs/gfs2/bmap.c +++ b/fs/gfs2

[PATCH v3 2/6] erofs: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- v3: -none v2: -convert to i_blockmask() fs/erofs/data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/erofs/data.c b/fs/erofs/data.c index 7e8baf56faa5..e9d1869cd4b3 100644 --- a/fs/erofs/data.c +++ b/fs

[PATCH v3 1/6] fs: add i_blockmask()

2023-03-09 Thread Yangtao Li
Introduce i_blockmask() to simplify code, which replace (i_blocksize(node) - 1). Like done in commit 93407472a21b("fs: add i_blocksize()"). Signed-off-by: Yangtao Li --- v3: -none v2: -convert to i_blockmask() include/linux/fs.h | 5 + 1 file changed, 5 insertions(+) diff --git

[PATCH v2 5/5] ocfs2: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. BTW convert ocfs2_is_io_unaligned to return bool type. Signed-off-by: Yangtao Li --- fs/ocfs2/file.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/fs/ocfs2/file.c b/fs/ocfs2/file.c index efb09de4343d..baefab3b12c9 100644 --- a/fs

[PATCH v2 4/5] ext4: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- v2: -convert to i_blockmask() fs/ext4/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index d251d705c276..eec36520e5e9 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4

[PATCH v2 3/5] gfs2: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- v2: -convert to i_blockmask() fs/gfs2/bmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c index eedf6926c652..1c6874b3851a 100644 --- a/fs/gfs2/bmap.c +++ b/fs/gfs2/bmap.c

[PATCH v2 2/5] erofs: convert to use i_blockmask()

2023-03-09 Thread Yangtao Li
Use i_blockmask() to simplify code. Signed-off-by: Yangtao Li --- v2: -convert to i_blockmask() fs/erofs/data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/erofs/data.c b/fs/erofs/data.c index 7e8baf56faa5..e9d1869cd4b3 100644 --- a/fs/erofs/data.c +++ b/fs/erofs

[PATCH v2 1/5] fs: add i_blockmask()

2023-03-09 Thread Yangtao Li
Introduce i_blockmask() to simplify code, which replace (i_blocksize(node) - 1). Like done in commit 93407472a21b("fs: add i_blocksize()"). Signed-off-by: Yangtao Li --- v2: -convert to i_blockmask() include/linux/fs.h | 5 + 1 file changed, 5 insertions(+) diff --git a/include/

[PATCH 4/4] ext4: convert to use i_blocksize_mask()

2023-03-09 Thread Yangtao Li
Use i_blocksize_mask() to simplify code. Signed-off-by: Yangtao Li --- fs/ext4/inode.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ext4/inode.c b/fs/ext4/inode.c index d251d705c276..c33f91f3b749 100644 --- a/fs/ext4/inode.c +++ b/fs/ext4/inode.c @@ -2218,7 +2218,7

[PATCH 3/4] gfs2: convert to use i_blocksize_mask()

2023-03-09 Thread Yangtao Li
Use i_blocksize_mask() to simplify code. Signed-off-by: Yangtao Li --- fs/gfs2/bmap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/gfs2/bmap.c b/fs/gfs2/bmap.c index eedf6926c652..d59f9b3f0b85 100644 --- a/fs/gfs2/bmap.c +++ b/fs/gfs2/bmap.c @@ -960,7 +960,7 @@ static

[PATCH 2/4] erofs: convert to use i_blocksize_mask()

2023-03-09 Thread Yangtao Li
Use i_blocksize_mask() to simplify code. Signed-off-by: Yangtao Li --- fs/erofs/data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/erofs/data.c b/fs/erofs/data.c index 7e8baf56faa5..234ca4dd5053 100644 --- a/fs/erofs/data.c +++ b/fs/erofs/data.c @@ -380,7 +380,7

[PATCH 1/4] fs: add i_blocksize_mask()

2023-03-09 Thread Yangtao Li
Introduce i_blocksize_mask() to simplify code, which replace (i_blocksize(node) - 1). Like done in commit 93407472a21b("fs: add i_blocksize()"). Signed-off-by: Yangtao Li --- include/linux/fs.h | 5 + 1 file changed, 5 insertions(+) diff --git a/include/linux/fs.h b/include/

Re: erofs: use wrapper i_blocksize() in erofs_file_read_iter()

2023-03-08 Thread Yangtao Li
> FYI it seems that GENMASK macro is widely used in driver and arch code base, > while it's rarely used in fs, except for f2fs. I think the following usage can be changed to bitmap api, just like in f2fs? https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=c4ca1f7164734

Re: erofs: use wrapper i_blocksize() in erofs_file_read_iter()

2023-03-08 Thread Yangtao Li
> @@ -380,7 +380,7 @@ static ssize_t erofs_file_read_iter(struct kiocb *iocb, > struct iov_iter *to) > if (bdev) > blksize_mask = bdev_logical_block_size(bdev) - 1; > else > - blksize_mask = (1 << inode->i_blkbits) - 1; > +

[PATCH v2] erofs: mark z_erofs_lzma_init/erofs_pcpubuf_init w/ __init

2023-03-02 Thread Yangtao Li
They are used during the erofs module init phase. Let's mark it as __init like any other function. Signed-off-by: Yangtao Li --- v2: -change in internal.h fs/erofs/decompressor_lzma.c | 2 +- fs/erofs/internal.h | 4 ++-- fs/erofs/pcpubuf.c | 2 +- 3 files chang

[PATCH] erofs: mark z_erofs_lzma_init/erofs_pcpubuf_init w/ __init

2023-03-02 Thread Yangtao Li
They are used during the erofs module init phase. Let's mark it as __init like any other function. Signed-off-by: Yangtao Li --- fs/erofs/decompressor_lzma.c | 2 +- fs/erofs/pcpubuf.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/fs/erofs/decompressor_l

[PATCH] MAINTAINERS: erofs: Add Documentation/ABI/testing/sysfs-fs-erofs

2023-02-08 Thread Yangtao Li
Add this doc to the erofs maintainers entry. Signed-off-by: Yangtao Li --- MAINTAINERS | 1 + 1 file changed, 1 insertion(+) diff --git a/MAINTAINERS b/MAINTAINERS index d0485b58b9d9..7d50e5df4508 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -7745,6 +7745,7 @@ R:Jeffle Xu L