linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: "Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org,
	Guenter Roeck <linux@roeck-us.net>,
	"Kirill A. Shutemov" <kirill.shutemov@linux.intel.com>
Subject: [PATCH 1/4] mm: move enum tlb_flush_reason into <trace/events/tlb.h>
Date: Wed, 28 Jan 2015 15:17:41 +0200	[thread overview]
Message-ID: <1422451064-109023-2-git-send-email-kirill.shutemov@linux.intel.com> (raw)
In-Reply-To: <1422451064-109023-1-git-send-email-kirill.shutemov@linux.intel.com>

The only user of tlb_flush_reason is trace_tlb_flush*(). There's no
reason to define it in mm_types.h

Signed-off-by: Kirill A. Shutemov <kirill.shutemov@linux.intel.com>
---
 include/linux/mm_types.h   |  8 --------
 include/trace/events/tlb.h | 15 ++++++++++++---
 2 files changed, 12 insertions(+), 11 deletions(-)

diff --git a/include/linux/mm_types.h b/include/linux/mm_types.h
index 199a03aab8dc..5dfdd5ed5254 100644
--- a/include/linux/mm_types.h
+++ b/include/linux/mm_types.h
@@ -527,14 +527,6 @@ struct vm_special_mapping
 	struct page **pages;
 };
 
-enum tlb_flush_reason {
-	TLB_FLUSH_ON_TASK_SWITCH,
-	TLB_REMOTE_SHOOTDOWN,
-	TLB_LOCAL_SHOOTDOWN,
-	TLB_LOCAL_MM_SHOOTDOWN,
-	NR_TLB_FLUSH_REASONS,
-};
-
  /*
   * A swap entry has to fit into a "unsigned long", as the entry is hidden
   * in the "index" field of the swapper address space.
diff --git a/include/trace/events/tlb.h b/include/trace/events/tlb.h
index 13391d288107..1f764ff60cf6 100644
--- a/include/trace/events/tlb.h
+++ b/include/trace/events/tlb.h
@@ -4,9 +4,18 @@
 #if !defined(_TRACE_TLB_H) || defined(TRACE_HEADER_MULTI_READ)
 #define _TRACE_TLB_H
 
-#include <linux/mm_types.h>
 #include <linux/tracepoint.h>
 
+#ifndef TRACE_HEADER_MULTI_READ
+enum tlb_flush_reason {
+	TLB_FLUSH_ON_TASK_SWITCH,
+	TLB_REMOTE_SHOOTDOWN,
+	TLB_LOCAL_SHOOTDOWN,
+	TLB_LOCAL_MM_SHOOTDOWN,
+	NR_TLB_FLUSH_REASONS,
+};
+#endif
+
 #define TLB_FLUSH_REASON	\
 	{ TLB_FLUSH_ON_TASK_SWITCH,	"flush on task switch" },	\
 	{ TLB_REMOTE_SHOOTDOWN,		"remote shootdown" },		\
@@ -15,11 +24,11 @@
 
 TRACE_EVENT(tlb_flush,
 
-	TP_PROTO(int reason, unsigned long pages),
+	TP_PROTO(enum tlb_flush_reason reason, unsigned long pages),
 	TP_ARGS(reason, pages),
 
 	TP_STRUCT__entry(
-		__field(	  int, reason)
+		__field(enum tlb_flush_reason, reason)
 		__field(unsigned long,  pages)
 	),
 
-- 
2.1.4

--
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>

  reply	other threads:[~2015-01-28 13:24 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-01-28 13:17 [PATCH 0/4] Introduce <linux/mm_struct.h> Kirill A. Shutemov
2015-01-28 13:17 ` Kirill A. Shutemov [this message]
2015-01-28 13:17 ` [PATCH 2/4] mm: split up mm_struct to separate header file Kirill A. Shutemov
2015-01-29  0:30   ` Kirill A. Shutemov
2015-01-29  2:02     ` Guenter Roeck
2015-01-29  4:22     ` Guenter Roeck
2015-01-28 13:17 ` [PATCH 3/4] mm: define __PAGETABLE_{PMD,PUD}_FOLDED to zero or one Kirill A. Shutemov
2015-01-28 13:17 ` [PATCH 4/4] mm: do not add nr_pmds into mm_struct if PMD is folded Kirill A. Shutemov
2015-01-28 17:06 ` [PATCH 0/4] Introduce <linux/mm_struct.h> Guenter Roeck
2015-01-28 18:50 ` Guenter Roeck
2015-01-28 20:45   ` Kirill A. Shutemov
2015-01-28 21:18     ` Guenter Roeck
2015-01-28 21:16   ` Kirill A. Shutemov

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=1422451064-109023-2-git-send-email-kirill.shutemov@linux.intel.com \
    --to=kirill.shutemov@linux.intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    --cc=linux@roeck-us.net \
    /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;
as well as URLs for NNTP newsgroup(s).