[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1269420538-18039-3-git-send-email-tj@kernel.org>
Date: Wed, 24 Mar 2010 17:48:56 +0900
From: Tejun Heo <tj@...nel.org>
To: torvalds@...ux-foundation.org, akpm@...ux-foundation.org,
linux-kernel@...r.kernel.org, Lee.Schermerhorn@...com,
cl@...ux-foundation.org, mingo@...e.hu, adobriyan@...il.com,
tglx@...utronix.de, hpa@...or.com, yi.zhu@...el.com,
reinette.chatre@...el.com, ilw@...ux.intel.com
Cc: Tejun Heo <tj@...nel.org>, Ingo Molnar <mingo@...hat.com>
Subject: [PATCH 2/4] iwlwifi: don't include iwl-dev.h from iwl-devtrace.h
iwl-devtrace.h is used to declare and define trace points and
including iwl-dev.h from the file, which in turn includes other
generic headers can lead to problems like generating duplicate copies
of generic trace points depending on the order of includes. Don't
include iwl-dev.h from iwl-devtrace.h but include it from its users -
iwl-io.h and iwl-devtrace.c.
Signed-off-by: Tejun Heo <tj@...nel.org>
Cc: Zhu Yi <yi.zhu@...el.com>
Cc: Reinette Chatre <reinette.chatre@...el.com>
Cc: Intel Linux Wireless <ilw@...ux.intel.com>
Cc: Ingo Molnar <mingo@...hat.com>
---
drivers/net/wireless/iwlwifi/iwl-devtrace.c | 2 ++
drivers/net/wireless/iwlwifi/iwl-devtrace.h | 1 -
drivers/net/wireless/iwlwifi/iwl-io.h | 1 +
3 files changed, 3 insertions(+), 1 deletions(-)
diff --git a/drivers/net/wireless/iwlwifi/iwl-devtrace.c b/drivers/net/wireless/iwlwifi/iwl-devtrace.c
index 36580d8..2ffc2ed 100644
--- a/drivers/net/wireless/iwlwifi/iwl-devtrace.c
+++ b/drivers/net/wireless/iwlwifi/iwl-devtrace.c
@@ -28,6 +28,8 @@
/* sparse doesn't like tracepoint macros */
#ifndef __CHECKER__
+#include "iwl-dev.h"
+
#define CREATE_TRACE_POINTS
#include "iwl-devtrace.h"
diff --git a/drivers/net/wireless/iwlwifi/iwl-devtrace.h b/drivers/net/wireless/iwlwifi/iwl-devtrace.h
index ff4d012..ae7319b 100644
--- a/drivers/net/wireless/iwlwifi/iwl-devtrace.h
+++ b/drivers/net/wireless/iwlwifi/iwl-devtrace.h
@@ -28,7 +28,6 @@
#define __IWLWIFI_DEVICE_TRACE
#include <linux/tracepoint.h>
-#include "iwl-dev.h"
#if !defined(CONFIG_IWLWIFI_DEVICE_TRACING) || defined(__CHECKER__)
#undef TRACE_EVENT
diff --git a/drivers/net/wireless/iwlwifi/iwl-io.h b/drivers/net/wireless/iwlwifi/iwl-io.h
index c719baf..16eb3ce 100644
--- a/drivers/net/wireless/iwlwifi/iwl-io.h
+++ b/drivers/net/wireless/iwlwifi/iwl-io.h
@@ -31,6 +31,7 @@
#include <linux/io.h>
+#include "iwl-dev.h"
#include "iwl-debug.h"
#include "iwl-devtrace.h"
--
1.6.4.2
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists