summaryrefslogtreecommitdiff
path: root/drivers
diff options
context:
space:
mode:
authorMinchan Kim <minchan@kernel.org>2017-09-07 02:19:50 +0300
committerLinus Torvalds <torvalds@linux-foundation.org>2017-09-07 03:27:25 +0300
commit693dc1ce25b8c8fa33f930d47cd8f926eeb90812 (patch)
treeb495352f5c03fd441d7ba2b9690bc9a2725e1397 /drivers
parent97ec7c8bd5d029b2c3e40355c1204197094e9ba1 (diff)
downloadlinux-693dc1ce25b8c8fa33f930d47cd8f926eeb90812.tar.xz
zram: rename zram_decompress_page to __zram_bvec_read
zram_decompress_page naming is not proper because it doesn't decompress if page was dedup hit or stored with compression. Use more abstract term and consistent with write path function __zram_bvec_write. Link: http://lkml.kernel.org/r/1498459987-24562-4-git-send-email-minchan@kernel.org Signed-off-by: Minchan Kim <minchan@kernel.org> Cc: Juneho Choi <juno.choi@lge.com> Cc: Sergey Senozhatsky <sergey.senozhatsky@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/block/zram/zram_drv.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/block/zram/zram_drv.c b/drivers/block/zram/zram_drv.c
index 7b16ab0b923a..7afe0d8487c0 100644
--- a/drivers/block/zram/zram_drv.c
+++ b/drivers/block/zram/zram_drv.c
@@ -518,7 +518,7 @@ static void zram_free_page(struct zram *zram, size_t index)
zram_set_obj_size(zram, index, 0);
}
-static int zram_decompress_page(struct zram *zram, struct page *page, u32 index)
+static int __zram_bvec_read(struct zram *zram, struct page *page, u32 index)
{
int ret;
unsigned long handle;
@@ -570,7 +570,7 @@ static int zram_bvec_read(struct zram *zram, struct bio_vec *bvec,
return -ENOMEM;
}
- ret = zram_decompress_page(zram, page, index);
+ ret = __zram_bvec_read(zram, page, index);
if (unlikely(ret))
goto out;
@@ -718,7 +718,7 @@ static int zram_bvec_write(struct zram *zram, struct bio_vec *bvec,
if (!page)
return -ENOMEM;
- ret = zram_decompress_page(zram, page, index);
+ ret = __zram_bvec_read(zram, page, index);
if (ret)
goto out;