瀏覽代碼

cfg80211: constify WDS address

There's no need for the WDS peer address
to not be const, so make it const.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Johannes Berg 14 年之前
父節點
當前提交
388ac775be
共有 3 個文件被更改,包括 3 次插入3 次删除
  1. 1 1
      include/net/cfg80211.h
  2. 1 1
      net/mac80211/cfg.c
  3. 1 1
      net/wireless/nl80211.c

+ 1 - 1
include/net/cfg80211.h

@@ -1229,7 +1229,7 @@ struct cfg80211_ops {
 	int	(*get_tx_power)(struct wiphy *wiphy, int *dbm);
 	int	(*get_tx_power)(struct wiphy *wiphy, int *dbm);
 
 
 	int	(*set_wds_peer)(struct wiphy *wiphy, struct net_device *dev,
 	int	(*set_wds_peer)(struct wiphy *wiphy, struct net_device *dev,
-				u8 *addr);
+				const u8 *addr);
 
 
 	void	(*rfkill_poll)(struct wiphy *wiphy);
 	void	(*rfkill_poll)(struct wiphy *wiphy);
 
 

+ 1 - 1
net/mac80211/cfg.c

@@ -1363,7 +1363,7 @@ static int ieee80211_get_tx_power(struct wiphy *wiphy, int *dbm)
 }
 }
 
 
 static int ieee80211_set_wds_peer(struct wiphy *wiphy, struct net_device *dev,
 static int ieee80211_set_wds_peer(struct wiphy *wiphy, struct net_device *dev,
-				  u8 *addr)
+				  const u8 *addr)
 {
 {
 	struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
 	struct ieee80211_sub_if_data *sdata = IEEE80211_DEV_TO_SUB_IF(dev);
 
 

+ 1 - 1
net/wireless/nl80211.c

@@ -879,7 +879,7 @@ static int nl80211_set_wds_peer(struct sk_buff *skb, struct genl_info *info)
 	struct cfg80211_registered_device *rdev = info->user_ptr[0];
 	struct cfg80211_registered_device *rdev = info->user_ptr[0];
 	struct net_device *dev = info->user_ptr[1];
 	struct net_device *dev = info->user_ptr[1];
 	struct wireless_dev *wdev = dev->ieee80211_ptr;
 	struct wireless_dev *wdev = dev->ieee80211_ptr;
-	u8 *bssid;
+	const u8 *bssid;
 
 
 	if (!info->attrs[NL80211_ATTR_MAC])
 	if (!info->attrs[NL80211_ATTR_MAC])
 		return -EINVAL;
 		return -EINVAL;