From: Michal Hocko <mhocko@suse.com>
To: Wan Jiabing <wanjiabing@vivo.com>
Cc: Andrew Morton <akpm@linux-foundation.org>,
Shakeel Butt <shakeelb@google.com>,
Johannes Weiner <hannes@cmpxchg.org>,
Roman Gushchin <guro@fb.com>,
Muchun Song <songmuchun@bytedance.com>,
Alex Shi <alex.shi@linux.alibaba.com>,
Alexander Duyck <alexander.h.duyck@linux.intel.com>,
Chris Down <chris@chrisdown.name>,
Yafang Shao <laoar.shao@gmail.com>,
Wei Yang <richard.weiyang@gmail.com>,
linux-kernel@vger.kernel.org, kael_w@yeah.net
Subject: Re: [PATCH] linux/memcontrol.h: Remove duplicate struct declaration
Date: Tue, 30 Mar 2021 10:32:47 +0200 [thread overview]
Message-ID: <YGLiL4CTvLQRSXy/@dhcp22.suse.cz> (raw)
In-Reply-To: <20210330020246.2265371-1-wanjiabing@vivo.com>
On Tue 30-03-21 10:02:36, Wan Jiabing wrote:
> struct mem_cgroup is declared twice. One has been declared
> at forward struct declaration. Remove the duplicate.
Duplicate declaration shouldn't really cause any problems. You are right
that there is one which is independent on CONFIG_MEMCG so the below one
is not needed though. It would be great if the changelog mentioned that
so that.
> Signed-off-by: Wan Jiabing <wanjiabing@vivo.com>
Acked-by: Michal Hocko <mhocko@suse.com>
> ---
> include/linux/memcontrol.h | 2 --
> 1 file changed, 2 deletions(-)
>
> diff --git a/include/linux/memcontrol.h b/include/linux/memcontrol.h
> index 0c04d39a7967..f0ae33a0f175 100644
> --- a/include/linux/memcontrol.h
> +++ b/include/linux/memcontrol.h
> @@ -1068,8 +1068,6 @@ void split_page_memcg(struct page *head, unsigned int nr);
> #define MEM_CGROUP_ID_SHIFT 0
> #define MEM_CGROUP_ID_MAX 0
>
> -struct mem_cgroup;
> -
> static inline struct mem_cgroup *page_memcg(struct page *page)
> {
> return NULL;
> --
> 2.25.1
--
Michal Hocko
SUSE Labs
prev parent reply other threads:[~2021-03-30 8:33 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-30 2:02 Wan Jiabing
2021-03-30 2:13 ` [External] " Muchun Song
2021-03-30 8:32 ` Michal Hocko [this message]
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=YGLiL4CTvLQRSXy/@dhcp22.suse.cz \
--to=mhocko@suse.com \
--cc=akpm@linux-foundation.org \
--cc=alex.shi@linux.alibaba.com \
--cc=alexander.h.duyck@linux.intel.com \
--cc=chris@chrisdown.name \
--cc=guro@fb.com \
--cc=hannes@cmpxchg.org \
--cc=kael_w@yeah.net \
--cc=laoar.shao@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=richard.weiyang@gmail.com \
--cc=shakeelb@google.com \
--cc=songmuchun@bytedance.com \
--cc=wanjiabing@vivo.com \
/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
all inboxes | Powered by JetHome®