[PATCH v2 09/29] memcg: change defines to an enum
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- To: <linux-kernel@xxxxxxxxxxxxxxx>
- Subject: [PATCH v2 09/29] memcg: change defines to an enum
- From: Glauber Costa <glommer@xxxxxxxxxxxxx>
- Date: Fri, 11 May 2012 14:44:11 -0300
- Cc: <cgroups@xxxxxxxxxxxxxxx>, <linux-mm@xxxxxxxxx>, <kamezawa.hiroyu@xxxxxxxxxxxxxx>, Tejun Heo <tj@xxxxxxxxxx>, Li Zefan <lizefan@xxxxxxxxxx>, Greg Thelen <gthelen@xxxxxxxxxx>, Suleiman Souhlal <suleiman@xxxxxxxxxx>, Michal Hocko <mhocko@xxxxxxx>, Johannes Weiner <hannes@xxxxxxxxxxx>, <devel@xxxxxxxxxx>, Glauber Costa <glommer@xxxxxxxxxxxxx>
- In-reply-to: <1336758272-24284-1-git-send-email-glommer@parallels.com>
This is just a cleanup patch for clarity of expression.
In earlier submissions, people asked it to be in a separate
patch, so here it is.
Signed-off-by: Glauber Costa <glommer@xxxxxxxxxxxxx>
CC: Michal Hocko <mhocko@xxxxxxx>
CC: Johannes Weiner <hannes@xxxxxxxxxxx>
Acked-by: Kamezawa Hiroyuki <kamezawa.hiroyu@xxxxxxxxxxxxxx>
---
mm/memcontrol.c | 9 ++++++---
1 files changed, 6 insertions(+), 3 deletions(-)
diff --git a/mm/memcontrol.c b/mm/memcontrol.c
index 47d3979..789ca5a 100644
--- a/mm/memcontrol.c
+++ b/mm/memcontrol.c
@@ -374,9 +374,12 @@ enum charge_type {
};
/* for encoding cft->private value on file */
-#define _MEM (0)
-#define _MEMSWAP (1)
-#define _OOM_TYPE (2)
+enum res_type {
+ _MEM,
+ _MEMSWAP,
+ _OOM_TYPE,
+};
+
#define MEMFILE_PRIVATE(x, val) (((x) << 16) | (val))
#define MEMFILE_TYPE(val) (((val) >> 16) & 0xffff)
#define MEMFILE_ATTR(val) ((val) & 0xffff)
--
1.7.7.6
--
To unsubscribe from this list: send the line "unsubscribe cgroups" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[Linux ARM Kernel]
[Linux ARM]
[Linux Omap]
[Fedora ARM]
[IETF Annouce]
[Security]
[Bugtraq]
[Linux]
[Linux OMAP]
[Linux MIPS]
[ECOS]
[Tools]
[DDR & Rambus]
[Asterisk Internet PBX]
[Linux API]
[Monitors]