[xiang-erofs:dev-test] BUILD SUCCESS 0e9a3c4fae5498e86dd11985143c4858a8300705

2021-02-09 Thread kernel test robot
allyesconfig powerpc allmodconfig powerpc allnoconfig x86_64 randconfig-a006-20210209 x86_64 randconfig-a001-20210209 x86_64 randconfig-a005-20210209 x86_64 randconfig-a004

Re: [PATCH v2] erofs-utils: fuse: fix random readlink error

2021-02-09 Thread Gao Xiang via Linux-erofs
Hi Weiwen, On Sat, Jan 30, 2021 at 02:07:47AM +0800, Hu Weiwen wrote: > readlink should fill a **null-terminated** string in the buffer. > > To achieve this: > 1) memset(0) for unmapped extents; > 2) make erofsfuse_read() properly returning the actual bytes read; > 3) insert a null character if

[PATCH 2/2] erofs-utils: more sanity check for buffer allocation optimization

2021-02-09 Thread Gao Xiang via Linux-erofs
From: Gao Xiang In case that new buffer allocation optimization logic is potentially broken. Signed-off-by: Gao Xiang --- lib/cache.c | 7 ++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/cache.c b/lib/cache.c index e8840ac5dd31..c4851168ede7 100644 --- a/lib/cache.c

[PATCH 1/2] erofs-utils: don't reuse full mapped buffer blocks

2021-02-09 Thread Gao Xiang via Linux-erofs
From: Gao Xiang Otherwise it could cause data corruption since erofs_battach() doesn't support full buffer blocks (and oob would be misjudged.) Fixes: 185b0bcdef4b ("erofs-utils: optimize buffer allocation logic") Signed-off-by: Gao Xiang --- lib/cache.c | 8 1 file changed, 4

[PATCH] erofs: initialized fields can only be observed after bit is set

2021-02-09 Thread Gao Xiang via Linux-erofs
From: Gao Xiang Currently, although set_bit() & test_bit() pairs are used as a fast- path for initialized configurations. However, these atomic ops are actually relaxed forms. Instead, load-acquire & store-release form is needed to make sure uninitialized fields won't be observed in advance here