From: Johannes Berg <johannes@sipsolutions.net>
To: John Linville <linville@tuxdriver.com>
Cc: Michael Wu <flamingice@sourmilk.net>, linux-wireless@vger.kernel.org
Subject: [PATCH 15/21] mac80211: rename ieee80211_cfg.c to cfg.c
Date: Thu, 06 Sep 2007 01:42:24 +0200 [thread overview]
Message-ID: <20070905234628.749705000@sipsolutions.net> (raw)
In-Reply-To: 20070905234209.108005000@sipsolutions.net
It's just painful to have the extra ieee80211_ prefix.
Signed-off-by: Johannes Berg <johannes@sipsolutions.net>
---
net/mac80211/Makefile | 2 -
net/mac80211/cfg.c | 75 +++++++++++++++++++++++++++++++++++++++++++
net/mac80211/ieee80211_cfg.c | 75 -------------------------------------------
3 files changed, 76 insertions(+), 76 deletions(-)
--- wireless-dev.orig/net/mac80211/Makefile 2007-09-06 01:34:54.904453431 +0200
+++ wireless-dev/net/mac80211/Makefile 2007-09-06 01:35:23.424453431 +0200
@@ -17,7 +17,7 @@ mac80211-objs := \
regdomain.o \
tkip.o \
aes_ccm.o \
- ieee80211_cfg.o \
+ cfg.o \
rx.o \
tx.o \
key.o \
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ wireless-dev/net/mac80211/cfg.c 2007-09-06 01:35:23.424453431 +0200
@@ -0,0 +1,75 @@
+/*
+ * mac80211 configuration hooks for cfg80211
+ *
+ * Copyright 2006 Johannes Berg <johannes@sipsolutions.net>
+ *
+ * This file is GPLv2 as found in COPYING.
+ */
+
+#include <linux/nl80211.h>
+#include <linux/rtnetlink.h>
+#include <net/cfg80211.h>
+#include "ieee80211_i.h"
+#include "ieee80211_cfg.h"
+
+static int ieee80211_add_iface(struct wiphy *wiphy, char *name,
+ enum nl80211_iftype type)
+{
+ struct ieee80211_local *local = wiphy_priv(wiphy);
+ int itype;
+
+ if (unlikely(local->reg_state != IEEE80211_DEV_REGISTERED))
+ return -ENODEV;
+
+ switch (type) {
+ case NL80211_IFTYPE_UNSPECIFIED:
+ itype = IEEE80211_IF_TYPE_STA;
+ break;
+ case NL80211_IFTYPE_ADHOC:
+ itype = IEEE80211_IF_TYPE_IBSS;
+ break;
+ case NL80211_IFTYPE_STATION:
+ itype = IEEE80211_IF_TYPE_STA;
+ break;
+ case NL80211_IFTYPE_AP:
+ itype = IEEE80211_IF_TYPE_AP;
+ break;
+ case NL80211_IFTYPE_AP_VLAN:
+ itype = IEEE80211_IF_TYPE_VLAN;
+ break;
+ case NL80211_IFTYPE_WDS:
+ itype = IEEE80211_IF_TYPE_WDS;
+ break;
+ case NL80211_IFTYPE_MONITOR:
+ itype = IEEE80211_IF_TYPE_MNTR;
+ break;
+ default:
+ return -EINVAL;
+ }
+
+ return ieee80211_if_add(local->mdev, name, NULL, itype);
+}
+
+static int ieee80211_del_iface(struct wiphy *wiphy, int ifindex)
+{
+ struct ieee80211_local *local = wiphy_priv(wiphy);
+ struct net_device *dev;
+ char *name;
+
+ if (unlikely(local->reg_state != IEEE80211_DEV_REGISTERED))
+ return -ENODEV;
+
+ dev = dev_get_by_index(ifindex);
+ if (!dev)
+ return 0;
+
+ name = dev->name;
+ dev_put(dev);
+
+ return ieee80211_if_remove(local->mdev, name, -1);
+}
+
+struct cfg80211_ops mac80211_config_ops = {
+ .add_virtual_intf = ieee80211_add_iface,
+ .del_virtual_intf = ieee80211_del_iface,
+};
--- wireless-dev.orig/net/mac80211/ieee80211_cfg.c 2007-09-06 01:35:13.764453431 +0200
+++ /dev/null 1970-01-01 00:00:00.000000000 +0000
@@ -1,75 +0,0 @@
-/*
- * mac80211 configuration hooks for cfg80211
- *
- * Copyright 2006 Johannes Berg <johannes@sipsolutions.net>
- *
- * This file is GPLv2 as found in COPYING.
- */
-
-#include <linux/nl80211.h>
-#include <linux/rtnetlink.h>
-#include <net/cfg80211.h>
-#include "ieee80211_i.h"
-#include "ieee80211_cfg.h"
-
-static int ieee80211_add_iface(struct wiphy *wiphy, char *name,
- enum nl80211_iftype type)
-{
- struct ieee80211_local *local = wiphy_priv(wiphy);
- int itype;
-
- if (unlikely(local->reg_state != IEEE80211_DEV_REGISTERED))
- return -ENODEV;
-
- switch (type) {
- case NL80211_IFTYPE_UNSPECIFIED:
- itype = IEEE80211_IF_TYPE_STA;
- break;
- case NL80211_IFTYPE_ADHOC:
- itype = IEEE80211_IF_TYPE_IBSS;
- break;
- case NL80211_IFTYPE_STATION:
- itype = IEEE80211_IF_TYPE_STA;
- break;
- case NL80211_IFTYPE_AP:
- itype = IEEE80211_IF_TYPE_AP;
- break;
- case NL80211_IFTYPE_AP_VLAN:
- itype = IEEE80211_IF_TYPE_VLAN;
- break;
- case NL80211_IFTYPE_WDS:
- itype = IEEE80211_IF_TYPE_WDS;
- break;
- case NL80211_IFTYPE_MONITOR:
- itype = IEEE80211_IF_TYPE_MNTR;
- break;
- default:
- return -EINVAL;
- }
-
- return ieee80211_if_add(local->mdev, name, NULL, itype);
-}
-
-static int ieee80211_del_iface(struct wiphy *wiphy, int ifindex)
-{
- struct ieee80211_local *local = wiphy_priv(wiphy);
- struct net_device *dev;
- char *name;
-
- if (unlikely(local->reg_state != IEEE80211_DEV_REGISTERED))
- return -ENODEV;
-
- dev = dev_get_by_index(ifindex);
- if (!dev)
- return 0;
-
- name = dev->name;
- dev_put(dev);
-
- return ieee80211_if_remove(local->mdev, name, -1);
-}
-
-struct cfg80211_ops mac80211_config_ops = {
- .add_virtual_intf = ieee80211_add_iface,
- .del_virtual_intf = ieee80211_del_iface,
-};
--
next prev parent reply other threads:[~2007-09-06 13:46 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-09-05 23:42 [PATCH 00/21] more mac80211 updates Johannes Berg
2007-09-05 23:42 ` [PATCH 01/21] mac80211: get STA after tx radiotap snipped Johannes Berg
2007-09-05 23:42 ` [PATCH 02/21] mac80211: allow drivers to indicate failed FCS/PLCP checksum Johannes Berg
2007-09-05 23:42 ` [PATCH 03/21] mac80211: revamp interface and filter configuration Johannes Berg
2007-09-06 14:28 ` Michael Buesch
2007-09-06 14:46 ` Johannes Berg
2007-09-06 17:05 ` Ivo van Doorn
2007-09-07 13:23 ` Johannes Berg
2007-09-07 17:56 ` Ivo van Doorn
2007-09-14 3:50 ` Michael Wu
2007-09-14 12:06 ` Johannes Berg
2007-09-05 23:42 ` [PATCH 04/21] mac80211: validate VLAN interfaces better Johannes Berg
2007-09-05 23:42 ` [PATCH 05/21] mac80211: remove key threshold stuff Johannes Berg
2007-09-05 23:42 ` [PATCH 06/21] mac80211: remove IEEE80211_CONF_SSID_HIDDEN and PRISM2_PARAM_BROADCAST_SSID Johannes Berg
2007-09-05 23:42 ` [PATCH 07/21] mac80211: renumber and document the hardware flags Johannes Berg
2007-09-05 23:42 ` [PATCH 08/21] mac80211: document a lot more Johannes Berg
2007-09-05 23:42 ` [PATCH 09/21] wireless networking: move frame inline functions to generic header Johannes Berg
2007-09-05 23:42 ` [PATCH 10/21] mac80211: yet more documentation Johannes Berg
2007-09-05 23:42 ` [PATCH 11/21] mac80211: fix warnings introduced by the doc patches Johannes Berg
2007-09-05 23:42 ` [PATCH 12/21] mac80211: remove tx info sw_retry_attempt member Johannes Berg
2007-09-05 23:42 ` [PATCH 13/21] mac80211: print out wiphy name instead of master device Johannes Berg
2007-09-05 23:42 ` [PATCH 14/21] mac80211 maintainership Johannes Berg
2007-09-05 23:42 ` Johannes Berg [this message]
2007-09-05 23:42 ` [PATCH 16/21] mac80211: consolidate decryption Johannes Berg
2007-09-05 23:42 ` [PATCH 17/21] mac80211: consolidate encryption Johannes Berg
2007-09-05 23:42 ` [PATCH 18/21] mac80211: remove ieee80211_wep_get_keyidx Johannes Berg
2007-09-05 23:42 ` [PATCH 19/21] mac80211: remove crypto algorithm typedef Johannes Berg
2007-09-05 23:42 ` [PATCH 20/21] mac80211: kill IE parse typedef Johannes Berg
2007-09-05 23:42 ` [PATCH 21/21] mac80211: kill vlan_id Johannes Berg
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=20070905234628.749705000@sipsolutions.net \
--to=johannes@sipsolutions.net \
--cc=flamingice@sourmilk.net \
--cc=linux-wireless@vger.kernel.org \
--cc=linville@tuxdriver.com \
/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).