diff options
| author | Christoph Hellwig <hch@lst.de> | 2025-05-08 07:14:30 +0200 |
|---|---|---|
| committer | Jaegeuk Kim <jaegeuk@kernel.org> | 2025-05-08 15:23:18 +0000 |
| commit | 84c5d16711a300949cfec83e76299a75b4cdf04a (patch) | |
| tree | f1803483f07bbbe69a78b14b1a6dc096431466fa /fs/f2fs/compress.c | |
| parent | f2fs: remove wbc->for_reclaim handling (diff) | |
| download | linux-84c5d16711a300949cfec83e76299a75b4cdf04a.tar.gz linux-84c5d16711a300949cfec83e76299a75b4cdf04a.zip | |
f2fs: always unlock the page in f2fs_write_single_data_page
Consolidate the code to unlock the page in f2fs_write_single_data_page
instead of leaving it to the callers for the AOP_WRITEPAGE_ACTIVATE case.
Replace AOP_WRITEPAGE_ACTIVATE with a positive return of 1 as this case
now doesn't match the historic ->writepage special return code that is
on it's way out now that ->writepage has been removed.
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Jaegeuk Kim <jaegeuk@kernel.org>
Diffstat (limited to 'fs/f2fs/compress.c')
| -rw-r--r-- | fs/f2fs/compress.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/fs/f2fs/compress.c b/fs/f2fs/compress.c index e016b0f96313..1e62fdffda07 100644 --- a/fs/f2fs/compress.c +++ b/fs/f2fs/compress.c @@ -1565,8 +1565,7 @@ continue_unlock: NULL, NULL, wbc, io_type, compr_blocks, false); if (ret) { - if (ret == AOP_WRITEPAGE_ACTIVATE) { - folio_unlock(folio); + if (ret == 1) { ret = 0; } else if (ret == -EAGAIN) { ret = 0; |
