From: Johannes Weiner <hannes-druUgvl0LCNAfugRpC6u6w@public.gmane.org>
To: Matthias Kaehlcke <mka-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
Cc: Michal Hocko <mhocko-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>,
Vladimir Davydov
<vdavydov.dev-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>,
Andrew Morton
<akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org>,
linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org,
linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org,
Doug Anderson <dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
Subject: Re: [PATCH] mm: memcontrol: Use int for event/state parameter in several functions
Date: Fri, 28 Jul 2017 15:52:36 -0400 [thread overview]
Message-ID: <20170728195236.GA22303@cmpxchg.org> (raw)
In-Reply-To: <20170728182354.GC84665-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>
On Fri, Jul 28, 2017 at 11:23:54AM -0700, Matthias Kaehlcke wrote:
> El Thu, Jul 27, 2017 at 02:10:04PM -0700 Matthias Kaehlcke ha dit:
>
> > Several functions use an enum type as parameter for an event/state,
> > but are called in some locations with an argument of a different enum
> > type. Adjust the interface of these functions to reality by changing the
> > parameter to int.
> >
> > This fixes a ton of enum-conversion warnings that are generated when
> > building the kernel with clang.
Thanks for fixing this, Matthias.
Acked-by: Johannes Weiner <hannes-druUgvl0LCNAfugRpC6u6w@public.gmane.org>
> While building for another target with a different configuration I
> noticed that inc/dec/mod_memcg_page_state() are also called with a
> conflicting enum type. Changing the parameter type for these functions
> also would make the API more consistent, with the current patch there
> is a somewhat odd mix of related functions, with some receiving an
> enum and others an int.
>
> Depending on your preference I can send a v3 of this patch or a
> separate patch to address the remaining functions (since this patch
> has already been added to -mm).
Since it's the exact same rationale for the other functions, it would
make sense to me to do a v3 that includes the remaining sites.
WARNING: multiple messages have this Message-ID (diff)
From: Johannes Weiner <hannes@cmpxchg.org>
To: Matthias Kaehlcke <mka@chromium.org>
Cc: Michal Hocko <mhocko@kernel.org>,
Vladimir Davydov <vdavydov.dev@gmail.com>,
Andrew Morton <akpm@linux-foundation.org>,
linux-kernel@vger.kernel.org, cgroups@vger.kernel.org,
linux-mm@kvack.org, Doug Anderson <dianders@chromium.org>
Subject: Re: [PATCH] mm: memcontrol: Use int for event/state parameter in several functions
Date: Fri, 28 Jul 2017 15:52:36 -0400 [thread overview]
Message-ID: <20170728195236.GA22303@cmpxchg.org> (raw)
In-Reply-To: <20170728182354.GC84665@google.com>
On Fri, Jul 28, 2017 at 11:23:54AM -0700, Matthias Kaehlcke wrote:
> El Thu, Jul 27, 2017 at 02:10:04PM -0700 Matthias Kaehlcke ha dit:
>
> > Several functions use an enum type as parameter for an event/state,
> > but are called in some locations with an argument of a different enum
> > type. Adjust the interface of these functions to reality by changing the
> > parameter to int.
> >
> > This fixes a ton of enum-conversion warnings that are generated when
> > building the kernel with clang.
Thanks for fixing this, Matthias.
Acked-by: Johannes Weiner <hannes@cmpxchg.org>
> While building for another target with a different configuration I
> noticed that inc/dec/mod_memcg_page_state() are also called with a
> conflicting enum type. Changing the parameter type for these functions
> also would make the API more consistent, with the current patch there
> is a somewhat odd mix of related functions, with some receiving an
> enum and others an int.
>
> Depending on your preference I can send a v3 of this patch or a
> separate patch to address the remaining functions (since this patch
> has already been added to -mm).
Since it's the exact same rationale for the other functions, it would
make sense to me to do a v3 that includes the remaining sites.
--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org. For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
WARNING: multiple messages have this Message-ID (diff)
From: Johannes Weiner <hannes@cmpxchg.org>
To: Matthias Kaehlcke <mka@chromium.org>
Cc: Michal Hocko <mhocko@kernel.org>,
Vladimir Davydov <vdavydov.dev@gmail.com>,
Andrew Morton <akpm@linux-foundation.org>,
linux-kernel@vger.kernel.org, cgroups@vger.kernel.org,
linux-mm@kvack.org, Doug Anderson <dianders@chromium.org>
Subject: Re: [PATCH] mm: memcontrol: Use int for event/state parameter in several functions
Date: Fri, 28 Jul 2017 15:52:36 -0400 [thread overview]
Message-ID: <20170728195236.GA22303@cmpxchg.org> (raw)
In-Reply-To: <20170728182354.GC84665@google.com>
On Fri, Jul 28, 2017 at 11:23:54AM -0700, Matthias Kaehlcke wrote:
> El Thu, Jul 27, 2017 at 02:10:04PM -0700 Matthias Kaehlcke ha dit:
>
> > Several functions use an enum type as parameter for an event/state,
> > but are called in some locations with an argument of a different enum
> > type. Adjust the interface of these functions to reality by changing the
> > parameter to int.
> >
> > This fixes a ton of enum-conversion warnings that are generated when
> > building the kernel with clang.
Thanks for fixing this, Matthias.
Acked-by: Johannes Weiner <hannes@cmpxchg.org>
> While building for another target with a different configuration I
> noticed that inc/dec/mod_memcg_page_state() are also called with a
> conflicting enum type. Changing the parameter type for these functions
> also would make the API more consistent, with the current patch there
> is a somewhat odd mix of related functions, with some receiving an
> enum and others an int.
>
> Depending on your preference I can send a v3 of this patch or a
> separate patch to address the remaining functions (since this patch
> has already been added to -mm).
Since it's the exact same rationale for the other functions, it would
make sense to me to do a v3 that includes the remaining sites.
next prev parent reply other threads:[~2017-07-28 19:52 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-27 21:10 [PATCH] mm: memcontrol: Use int for event/state parameter in several functions Matthias Kaehlcke
2017-07-27 21:10 ` Matthias Kaehlcke
[not found] ` <20170727211004.34435-1-mka-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org>
2017-07-28 6:58 ` Michal Hocko
2017-07-28 6:58 ` Michal Hocko
2017-07-28 6:58 ` Michal Hocko
2017-07-28 18:23 ` Matthias Kaehlcke
2017-07-28 18:23 ` Matthias Kaehlcke
2017-07-28 18:23 ` Matthias Kaehlcke
[not found] ` <20170728182354.GC84665-hpIqsD4AKlfQT0dZR+AlfA@public.gmane.org>
2017-07-28 19:52 ` Johannes Weiner [this message]
2017-07-28 19:52 ` Johannes Weiner
2017-07-28 19:52 ` Johannes Weiner
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=20170728195236.GA22303@cmpxchg.org \
--to=hannes-druugvl0lcnafugrpc6u6w@public.gmane.org \
--cc=akpm-de/tnXTf+JLsfHDXvbKv3WD2FQJk+8+b@public.gmane.org \
--cc=cgroups-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=dianders-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org \
--cc=linux-kernel-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=linux-mm-Bw31MaZKKs3YtjvyW6yDsg@public.gmane.org \
--cc=mhocko-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org \
--cc=mka-F7+t8E8rja9g9hUCZPvPmw@public.gmane.org \
--cc=vdavydov.dev-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.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.