Jeffle Xu
9c0cc9c729
erofs: add 'fsid' mount option
...
Introduce 'fsid' mount option to enable on-demand read sementics, in
which case, erofs will be mounted from data blobs. Users could specify
the name of primary data blob by this mount option.
Signed-off-by: Jeffle Xu <jefflexu@linux.alibaba.com >
Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com >
Link: https://lore.kernel.org/r/20220425122143.56815-22-jefflexu@linux.alibaba.com
Acked-by: Chao Yu <chao@kernel.org >
Tested-by: Zichen Tian <tianzichen@kuaishou.com >
Tested-by: Jia Zhu <zhujia.zj@bytedance.com >
Tested-by: Yan Song <yansong.ys@antgroup.com >
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com >
2022-05-18 00:11:21 +08:00
Dongliang Mu
a942da24ab
fs: erofs: add sanity check for kobject in erofs_unregister_sysfs
...
Syzkaller hit 'WARNING: kobject bug in erofs_unregister_sysfs'. This bug
is triggered by injecting fault in kobject_init_and_add of
erofs_unregister_sysfs.
Fix this by adding sanity check for kobject in erofs_unregister_sysfs
Note that I've tested the patch and the crash does not occur any more.
Link: https://lore.kernel.org/r/20220315132814.12332-1-dzm91@hust.edu.cn
Signed-off-by: Dongliang Mu <mudongliangabcd@gmail.com >
Fixes: 168e9a7620 ("erofs: add sysfs interface")
Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com >
Reviewed-by: Chao Yu <chao@kernel.org >
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com >
2022-03-17 00:09:02 +08:00
Yue Hu
ab92184ff8
erofs: add on-disk compressed tail-packing inline support
...
Introduces erofs compressed tail-packing inline support.
This approach adds a new field called `h_idata_size' in the
per-file compression header to indicate the encoded size of
each tail-packing pcluster.
At runtime, it will find the start logical offset of the tail
pcluster when initializing per-inode zmap and record such
extent (headlcn, idataoff) information to the in-memory inode.
Therefore, follow-on requests can directly recognize if one
pcluster is a tail-packing inline pcluster or not.
Link: https://lore.kernel.org/r/20211228054604.114518-6-hsiangkao@linux.alibaba.com
Reviewed-by: Chao Yu <chao@kernel.org >
Signed-off-by: Yue Hu <huyue2@yulong.com >
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com >
2021-12-31 00:51:10 +08:00
Huang Jianan
40452ffca3
erofs: add sysfs node to control sync decompression strategy
...
Although readpage is a synchronous path, there will be no additional
kworker scheduling overhead in non-atomic contexts together with
dm-verity.
Let's add a sysfs node to disable sync decompression as an option.
Link: https://lore.kernel.org/r/20211206143552.8384-1-huangjianan@oppo.com
Reviewed-by: Chao Yu <chao@kernel.org >
Signed-off-by: Huang Jianan <huangjianan@oppo.com >
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com >
2021-12-08 09:42:18 +08:00
Huang Jianan
168e9a7620
erofs: add sysfs interface
...
Add sysfs interface to configure erofs related parameters later.
Link: https://lore.kernel.org/r/20211201145436.4357-1-huangjianan@oppo.com
Reviewed-by: Chao Yu <chao@kernel.org >
Reviewed-by: Gao Xiang <hsiangkao@linux.alibaba.com >
Signed-off-by: Huang Jianan <huangjianan@oppo.com >
Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com >
2021-12-08 09:40:37 +08:00