Commit bd9ae4a
f2fs: compress: fix to relocate check condition in f2fs_ioc_{,de}compress_file()
Compress flag should be checked after inode lock held to avoid
racing w/ f2fs_setflags_common() , fix it.
Fixes: 5fdb322 ("f2fs: add F2FS_IOC_DECOMPRESS_FILE and F2FS_IOC_COMPRESS_FILE")
Reported-by: Zhiguo Niu <zhiguo.niu@unisoc.com>
Closes: https://lore.kernel.org/linux-f2fs-devel/CAHJ8P3LdZXLc2rqeYjvymgYHr2+YLuJ0sLG9DdsJZmwO7deuhw@mail.gmail.com
Signed-off-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>1 parent 7c5dffb commit bd9ae4a
1 file changed
Lines changed: 4 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
4136 | 4136 | | |
4137 | 4137 | | |
4138 | 4138 | | |
4139 | | - | |
4140 | | - | |
4141 | | - | |
4142 | 4139 | | |
4143 | 4140 | | |
4144 | 4141 | | |
| |||
4149 | 4146 | | |
4150 | 4147 | | |
4151 | 4148 | | |
4152 | | - | |
| 4149 | + | |
| 4150 | + | |
4153 | 4151 | | |
4154 | 4152 | | |
4155 | 4153 | | |
| |||
4214 | 4212 | | |
4215 | 4213 | | |
4216 | 4214 | | |
4217 | | - | |
4218 | | - | |
4219 | | - | |
4220 | 4215 | | |
4221 | 4216 | | |
4222 | 4217 | | |
| |||
4227 | 4222 | | |
4228 | 4223 | | |
4229 | 4224 | | |
4230 | | - | |
| 4225 | + | |
| 4226 | + | |
4231 | 4227 | | |
4232 | 4228 | | |
4233 | 4229 | | |
| |||
0 commit comments