Blob Blame History Raw
From linux-wireless-owner@vger.kernel.org Thu Jan 26 18:23:05 2012
Return-Path: linville@tuxdriver.com
Received: from zmta01.collab.prod.int.phx2.redhat.com (LHLO
 zmta01.collab.prod.int.phx2.redhat.com) (10.5.5.31) by
 zmail15.collab.prod.int.phx2.redhat.com with LMTP; Thu, 26 Jan 2012
 18:23:05 -0500 (EST)
Received: from localhost (localhost.localdomain [127.0.0.1]) by
 zmta01.collab.prod.int.phx2.redhat.com (Postfix) with ESMTP id BEE90114AAB
 for <linville@redhat.com>; Thu, 26 Jan 2012 18:23:05 -0500 (EST)
Received: from zmta01.collab.prod.int.phx2.redhat.com ([127.0.0.1]) by
 localhost (zmta01.collab.prod.int.phx2.redhat.com [127.0.0.1])
 (amavisd-new, port 10024) with ESMTP id vqGh0M65OdhD for
 <linville@redhat.com>; Thu, 26 Jan 2012 18:23:05 -0500 (EST)
Received: from int-mx10.intmail.prod.int.phx2.redhat.com
 (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by
 zmta01.collab.prod.int.phx2.redhat.com (Postfix) with ESMTP id AB0BE114A54
 for <linville@mail.corp.redhat.com>; Thu, 26 Jan 2012 18:23:05 -0500 (EST)
Received: from mx1.redhat.com (ext-mx13.extmail.prod.ext.phx2.redhat.com
 [10.5.110.18]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4)
 with ESMTP id q0QNN44o004565 for <linville@redhat.com>; Thu, 26 Jan 2012
 18:23:05 -0500
Received: from smtp.tuxdriver.com (charlotte.tuxdriver.com [70.61.120.58])
 by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id q0QNN2jG004833 for
 <linville@redhat.com>; Thu, 26 Jan 2012 18:23:03 -0500
Received: from sapphire.tuxdriver.com ([70.61.120.61] helo=localhost) by
 smtp.tuxdriver.com with esmtp (Exim 4.63) (envelope-from
 <linville@tuxdriver.com>) id 1RqYej-0005zd-E7 for linville@redhat.com; Thu,
 26 Jan 2012 18:23:01 -0500
Resent-From: "John W. Linville" <linville@tuxdriver.com>
Resent-Date: Thu, 26 Jan 2012 18:22:43 -0500
Resent-Message-ID: <20120126232243.GA2190@tuxdriver.com>
Resent-To: linville@redhat.com
Received: from vger.kernel.org ([209.132.180.67]) by smtp.tuxdriver.com
 with esmtp (Exim 4.63) (envelope-from
 <linux-wireless-owner@vger.kernel.org>) id 1RqYC2-0005sF-Ja for
 linville@tuxdriver.com; Thu, 26 Jan 2012 17:53:25 -0500
Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id
 S1753594Ab2AZWxH (ORCPT <rfc822;linville@tuxdriver.com>); Thu, 26 Jan 2012
 17:53:07 -0500
Received: from server19320154104.serverpool.info ([193.201.54.104]:51996
 "EHLO hauke-m.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id
 S1753449Ab2AZWxG (ORCPT <rfc822;linux-wireless@vger.kernel.org>); Thu, 26
 Jan 2012 17:53:06 -0500
Received: from localhost (localhost [127.0.0.1]) by hauke-m.de (Postfix)
 with ESMTP id CCCF88F60; Thu, 26 Jan 2012 23:53:03 +0100 (CET)
X-Virus-Scanned: Debian amavisd-new at hauke-m.de 
Received: from hauke-m.de ([127.0.0.1]) by localhost (hauke-m.de
 [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LKxWWkfakUtI; Thu, 26
 Jan 2012 23:51:49 +0100 (CET)
Received: from localhost.localdomain (unknown [134.102.132.222]) by
 hauke-m.de (Postfix) with ESMTPSA id DBFF98F61; Thu, 26 Jan 2012 23:51:48
 +0100 (CET)
From: Hauke Mehrtens <hauke@hauke-m.de>
To: mcgrof@gmail.com, mcgrof@qca.qualcomm.com
Cc: linux-wireless@vger.kernel.org, Hauke Mehrtens <hauke@hauke-m.de>
Subject: [PATCH] compat: move br_port_exists() to compat-2.6.36.h
Date:	Thu, 26 Jan 2012 23:51:45 +0100
Message-Id: <1327618305-23077-1-git-send-email-hauke@hauke-m.de>
Sender: linux-wireless-owner@vger.kernel.org
Precedence: bulk
List-ID: <linux-wireless.vger.kernel.org>
X-Mailing-List:	linux-wireless@vger.kernel.org
X-Spam-Status: No
X-RedHat-Spam-Score: -0.01  (T_RP_MATCHES_RCVD)
X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23
X-Scanned-By: MIMEDefang 2.68 on 10.5.110.18
X-Evolution-Source: imap://linville@mail.corp.redhat.com/
Content-Transfer-Encoding: 8bit
Mime-Version: 1.0

br_port_exists() was moved to a new compat-*.h file for every new
kernel release, as it is not in mainline. This patch moves it to compat-
2.6.36.h so it has not to be moved any more for a new kernel version.

Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
---
 include/linux/compat-2.6.36.h |   15 +++++++++++++++
 include/linux/compat-3.3.h    |   17 -----------------
 2 files changed, 15 insertions(+), 17 deletions(-)

diff --git a/include/linux/compat-2.6.36.h b/include/linux/compat-2.6.36.h
index b5d9975..314fb35 100644
--- a/include/linux/compat-2.6.36.h
+++ b/include/linux/compat-2.6.36.h
@@ -142,6 +142,8 @@ extern struct workqueue_struct *system_nrt_wq;
 void compat_system_workqueue_create(void);
 void compat_system_workqueue_destroy(void);
 
+#define br_port_exists(dev)	(dev->br_port)
+
 #else
 
 static inline void compat_system_workqueue_create(void)
@@ -152,6 +154,19 @@ static inline void compat_system_workqueue_destroy(void)
 {
 }
 
+/*
+ * This is not part of The 2.6.37 kernel yet but we
+ * we use it to optimize the backport code we
+ * need to implement. Instead of using ifdefs
+ * to check what version of the check we use
+ * we just replace all checks on current code
+ * with this. I'll submit this upstream too, that
+ * way all we'd have to do is to implement this
+ * for older kernels, then we would not have to
+ * edit the upstrema code for backport efforts.
+ */
+#define br_port_exists(dev)	(dev->priv_flags & IFF_BRIDGE_PORT)
+
 #endif /* (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,36)) */
 
 #endif /* LINUX_26_36_COMPAT_H */
diff --git a/include/linux/compat-3.3.h b/include/linux/compat-3.3.h
index 821333c..4965f23 100644
--- a/include/linux/compat-3.3.h
+++ b/include/linux/compat-3.3.h
@@ -8,23 +8,6 @@
 /* include to override NL80211_FEATURE_SK_TX_STATUS */
 #include <linux/nl80211.h>
 
-/*
- * This is not part of The 2.6.37 kernel yet but we
- * we use it to optimize the backport code we
- * need to implement. Instead of using ifdefs
- * to check what version of the check we use
- * we just replace all checks on current code
- * with this. I'll submit this upstream too, that
- * way all we'd have to do is to implement this
- * for older kernels, then we would not have to
- * edit the upstrema code for backport efforts.
- */
-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,36))
-#define br_port_exists(dev)	(dev->priv_flags & IFF_BRIDGE_PORT)
-#else
-#define br_port_exists(dev)	(dev->br_port)
-#endif
-
 static inline void skb_complete_wifi_ack(struct sk_buff *skb, bool acked)
 {
 	WARN_ON(1);
-- 
1.7.5.4

--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html