public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Chengming Zhou <chengming.zhou@linux.dev>
To: Sergey Senozhatsky <senozhatsky@chromium.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	Minchan Kim <minchan@kernel.org>
Cc: linux-kernel@vger.kernel.org
Subject: Re: [PATCH] zsmalloc: rename class stat mutators
Date: Fri, 28 Jun 2024 11:22:48 +0800	[thread overview]
Message-ID: <fa282bea-4639-4d04-9d99-b9e2838a6b7a@linux.dev> (raw)
In-Reply-To: <20240628015154.3230389-1-senozhatsky@chromium.org>

On 2024/6/28 09:42, Sergey Senozhatsky wrote:
> A cosmetic change.
> 
> o Rename class_stat_inc() and class_stat_dec() to class_stat_add()
>    and class_stat_sub() correspondingly. inc/dec are usually associated
>    with +1/-1 modifications, while zsmlloc can modify stats by up
>    to ->objs_per_zspage. Use add/sub (follow atomics naming).
> 
> o Rename zs_stat_get() to class_stat_read()
>    get() is usually associated with ref-counting and is paired with put().
>    zs_stat_get() simply reads class stat so rename to reflect it.
>    (This also follows atomics naming).
> 
> Signed-off-by: Sergey Senozhatsky <senozhatsky@chromium.org>

Looks good to me.

Reviewed-by: Chengming Zhou <chengming.zhou@linux.dev>


  parent reply	other threads:[~2024-06-28  3:22 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-28  1:42 [PATCH] zsmalloc: rename class stat mutators Sergey Senozhatsky
2024-06-28  2:22 ` Sergey Senozhatsky
2024-06-28  3:22 ` Chengming Zhou [this message]
  -- strict thread matches above, loose matches on Subject: below --
2024-07-01  3:11 Sergey Senozhatsky
2024-07-01  3:19 ` Chengming Zhou

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fa282bea-4639-4d04-9d99-b9e2838a6b7a@linux.dev \
    --to=chengming.zhou@linux.dev \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=minchan@kernel.org \
    --cc=senozhatsky@chromium.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox