Message ID | 20240130014208.565554-7-hannes@cmpxchg.org (mailing list archive) |
---|---|
State | New |
Headers | show |
Series | mm: zswap: cleanups | expand |
On 2024/1/30 09:36, Johannes Weiner wrote: > Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Reviewed-by: Chengming Zhou <zhouchengming@bytedance.com> > --- > mm/zswap.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/mm/zswap.c b/mm/zswap.c > index 7a7e8da2b4f8..bdc9f82fe4b9 100644 > --- a/mm/zswap.c > +++ b/mm/zswap.c > @@ -1316,7 +1316,7 @@ static int zswap_enabled_param_set(const char *val, > return ret; > } > > -static void __zswap_load(struct zswap_entry *entry, struct page *page) > +static void zswap_decompress(struct zswap_entry *entry, struct page *page) > { > struct zpool *zpool = zswap_find_zpool(entry); > struct scatterlist input, output; > @@ -1411,7 +1411,7 @@ static int zswap_writeback_entry(struct zswap_entry *entry, > zswap_entry_get(entry); > spin_unlock(&tree->lock); > > - __zswap_load(entry, &folio->page); > + zswap_decompress(entry, &folio->page); > > count_vm_event(ZSWPWB); > if (entry->objcg) > @@ -1702,7 +1702,7 @@ bool zswap_load(struct folio *folio) > spin_unlock(&tree->lock); > > if (entry->length) > - __zswap_load(entry, page); > + zswap_decompress(entry, page); > else { > dst = kmap_local_page(page); > zswap_fill_page(dst, entry->value);
On Mon, Jan 29, 2024 at 08:36:42PM -0500, Johannes Weiner wrote: > Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Acked-by: Yosry Ahmed <yosryahmed@google.com>
On Mon, Jan 29, 2024 at 5:42 PM Johannes Weiner <hannes@cmpxchg.org> wrote: > > Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> > --- > mm/zswap.c | 6 +++--- > 1 file changed, 3 insertions(+), 3 deletions(-) > > diff --git a/mm/zswap.c b/mm/zswap.c > index 7a7e8da2b4f8..bdc9f82fe4b9 100644 > --- a/mm/zswap.c > +++ b/mm/zswap.c > @@ -1316,7 +1316,7 @@ static int zswap_enabled_param_set(const char *val, > return ret; > } > > -static void __zswap_load(struct zswap_entry *entry, struct page *page) > +static void zswap_decompress(struct zswap_entry *entry, struct page *page) This is a much better name. Was gonna point this out in the original series - it's clearly just decompression :) Reviewed-by: Nhat Pham <nphamcs@gmail.com> > { > struct zpool *zpool = zswap_find_zpool(entry); > struct scatterlist input, output; > @@ -1411,7 +1411,7 @@ static int zswap_writeback_entry(struct zswap_entry *entry, > zswap_entry_get(entry); > spin_unlock(&tree->lock); > > - __zswap_load(entry, &folio->page); > + zswap_decompress(entry, &folio->page); > > count_vm_event(ZSWPWB); > if (entry->objcg) > @@ -1702,7 +1702,7 @@ bool zswap_load(struct folio *folio) > spin_unlock(&tree->lock); > > if (entry->length) > - __zswap_load(entry, page); > + zswap_decompress(entry, page); > else { > dst = kmap_local_page(page); > zswap_fill_page(dst, entry->value); > -- > 2.43.0 >
diff --git a/mm/zswap.c b/mm/zswap.c index 7a7e8da2b4f8..bdc9f82fe4b9 100644 --- a/mm/zswap.c +++ b/mm/zswap.c @@ -1316,7 +1316,7 @@ static int zswap_enabled_param_set(const char *val, return ret; } -static void __zswap_load(struct zswap_entry *entry, struct page *page) +static void zswap_decompress(struct zswap_entry *entry, struct page *page) { struct zpool *zpool = zswap_find_zpool(entry); struct scatterlist input, output; @@ -1411,7 +1411,7 @@ static int zswap_writeback_entry(struct zswap_entry *entry, zswap_entry_get(entry); spin_unlock(&tree->lock); - __zswap_load(entry, &folio->page); + zswap_decompress(entry, &folio->page); count_vm_event(ZSWPWB); if (entry->objcg) @@ -1702,7 +1702,7 @@ bool zswap_load(struct folio *folio) spin_unlock(&tree->lock); if (entry->length) - __zswap_load(entry, page); + zswap_decompress(entry, page); else { dst = kmap_local_page(page); zswap_fill_page(dst, entry->value);
Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> --- mm/zswap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)