All of lore.kernel.org
 help / color / mirror / Atom feed
From: Yosry Ahmed <yosryahmed@google.com>
To: Miaohe Lin <linmiaohe@huawei.com>
Cc: lizefan.x@bytedance.com, tj@kernel.org, hannes@cmpxchg.org,
	cgroups@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] cgroup: remove unused macro for_each_e_css()
Date: Fri, 26 May 2023 20:55:49 -0700	[thread overview]
Message-ID: <CAJD7tkbY0kXbb3r3ObgOjmSa5kmw7n1uhN=Opvumty3=i9Ev0g@mail.gmail.com> (raw)
In-Reply-To: <20230527093353.153078-1-linmiaohe@huawei.com>

On Fri, May 26, 2023 at 6:43 PM Miaohe Lin <linmiaohe@huawei.com> wrote:
>
> for_each_e_css() is unused now. Remove it.
>
> Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>

LGTM. I can't see any references in Linus's tree or mm-unstable.

Reviewed-by: Yosry Ahmed <yosryahmed@google.com>

> ---
>  kernel/cgroup/cgroup.c | 15 ---------------
>  1 file changed, 15 deletions(-)
>
> diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
> index 625d7483951c..413b4f1f1b70 100644
> --- a/kernel/cgroup/cgroup.c
> +++ b/kernel/cgroup/cgroup.c
> @@ -689,21 +689,6 @@ EXPORT_SYMBOL_GPL(of_css);
>                                 lockdep_is_held(&cgroup_mutex)))) { }   \
>                 else
>
> -/**
> - * for_each_e_css - iterate all effective css's of a cgroup
> - * @css: the iteration cursor
> - * @ssid: the index of the subsystem, CGROUP_SUBSYS_COUNT after reaching the end
> - * @cgrp: the target cgroup to iterate css's of
> - *
> - * Should be called under cgroup_[tree_]mutex.
> - */
> -#define for_each_e_css(css, ssid, cgrp)                                            \
> -       for ((ssid) = 0; (ssid) < CGROUP_SUBSYS_COUNT; (ssid)++)            \
> -               if (!((css) = cgroup_e_css_by_mask(cgrp,                    \
> -                                                  cgroup_subsys[(ssid)]))) \
> -                       ;                                                   \
> -               else
> -
>  /**
>   * do_each_subsys_mask - filter for_each_subsys with a bitmask
>   * @ss: the iteration cursor
> --
> 2.27.0
>

WARNING: multiple messages have this Message-ID (diff)
From: Yosry Ahmed <yosryahmed-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>
To: Miaohe Lin <linmiaohe-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>
Cc: lizefan.x-EC8Uxl6Npydl57MIdRCFDg@public.gmane.org,
	tj-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org,
	hannes-druUgvl0LCNAfugRpC6u6w@public.gmane.org,
	cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] cgroup: remove unused macro for_each_e_css()
Date: Fri, 26 May 2023 20:55:49 -0700	[thread overview]
Message-ID: <CAJD7tkbY0kXbb3r3ObgOjmSa5kmw7n1uhN=Opvumty3=i9Ev0g@mail.gmail.com> (raw)
In-Reply-To: <20230527093353.153078-1-linmiaohe-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>

On Fri, May 26, 2023 at 6:43 PM Miaohe Lin <linmiaohe-hv44wF8Li93QT0dZR+AlfA@public.gmane.org> wrote:
>
> for_each_e_css() is unused now. Remove it.
>
> Signed-off-by: Miaohe Lin <linmiaohe-hv44wF8Li93QT0dZR+AlfA@public.gmane.org>

LGTM. I can't see any references in Linus's tree or mm-unstable.

Reviewed-by: Yosry Ahmed <yosryahmed-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>

> ---
>  kernel/cgroup/cgroup.c | 15 ---------------
>  1 file changed, 15 deletions(-)
>
> diff --git a/kernel/cgroup/cgroup.c b/kernel/cgroup/cgroup.c
> index 625d7483951c..413b4f1f1b70 100644
> --- a/kernel/cgroup/cgroup.c
> +++ b/kernel/cgroup/cgroup.c
> @@ -689,21 +689,6 @@ EXPORT_SYMBOL_GPL(of_css);
>                                 lockdep_is_held(&cgroup_mutex)))) { }   \
>                 else
>
> -/**
> - * for_each_e_css - iterate all effective css's of a cgroup
> - * @css: the iteration cursor
> - * @ssid: the index of the subsystem, CGROUP_SUBSYS_COUNT after reaching the end
> - * @cgrp: the target cgroup to iterate css's of
> - *
> - * Should be called under cgroup_[tree_]mutex.
> - */
> -#define for_each_e_css(css, ssid, cgrp)                                            \
> -       for ((ssid) = 0; (ssid) < CGROUP_SUBSYS_COUNT; (ssid)++)            \
> -               if (!((css) = cgroup_e_css_by_mask(cgrp,                    \
> -                                                  cgroup_subsys[(ssid)]))) \
> -                       ;                                                   \
> -               else
> -
>  /**
>   * do_each_subsys_mask - filter for_each_subsys with a bitmask
>   * @ss: the iteration cursor
> --
> 2.27.0
>

  reply	other threads:[~2023-05-27  3:56 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-27  9:33 [PATCH] cgroup: remove unused macro for_each_e_css() Miaohe Lin
2023-05-27  9:33 ` Miaohe Lin
2023-05-27  3:55 ` Yosry Ahmed [this message]
2023-05-27  3:55   ` Yosry Ahmed
2023-06-01 14:06 ` Michal Koutný
2023-06-05 19:20 ` Tejun Heo
2023-06-05 19:20   ` Tejun Heo

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='CAJD7tkbY0kXbb3r3ObgOjmSa5kmw7n1uhN=Opvumty3=i9Ev0g@mail.gmail.com' \
    --to=yosryahmed@google.com \
    --cc=cgroups@vger.kernel.org \
    --cc=hannes@cmpxchg.org \
    --cc=linmiaohe@huawei.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lizefan.x@bytedance.com \
    --cc=tj@kernel.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.