* @get_tx_power: store the current TX power into the dbm variable;
  *     return 0 if successful
  *
- * @set_wds_peer: set the WDS peer for a WDS interface
- *
  * @rfkill_poll: polls the hw rfkill line, use cfg80211 reporting
  *     functions to adjust rfkill hw state
  *
        int     (*get_tx_power)(struct wiphy *wiphy, struct wireless_dev *wdev,
                                int *dbm);
 
-       int     (*set_wds_peer)(struct wiphy *wiphy, struct net_device *dev,
-                               const u8 *addr);
-
        void    (*rfkill_poll)(struct wiphy *wiphy);
 
 #ifdef CONFIG_NL80211_TESTMODE
 
  *     of any other interfaces, and other interfaces will again take
  *     precedence when they are used.
  *
- * @NL80211_CMD_SET_WDS_PEER: Set the MAC address of the peer on a WDS interface.
+ * @NL80211_CMD_SET_WDS_PEER: Set the MAC address of the peer on a WDS interface
+ *     (no longer supported).
  *
  * @NL80211_CMD_SET_MULTICAST_TO_UNICAST: Configure if this AP should perform
  *     multicast to unicast conversion. When enabled, all multicast packets
 
        case NL80211_IFTYPE_P2P_CLIENT:
        case NL80211_IFTYPE_MONITOR:
        case NL80211_IFTYPE_AP_VLAN:
-       case NL80211_IFTYPE_WDS:
        case NL80211_IFTYPE_P2P_DEVICE:
        case NL80211_IFTYPE_NAN:
                break;
+       case NL80211_IFTYPE_WDS:
        case NL80211_IFTYPE_UNSPECIFIED:
        case NUM_NL80211_IFTYPES:
                WARN_ON(1);
        case NL80211_IFTYPE_P2P_CLIENT:
        case NL80211_IFTYPE_MONITOR:
        case NL80211_IFTYPE_AP_VLAN:
-       case NL80211_IFTYPE_WDS:
        case NL80211_IFTYPE_P2P_DEVICE:
        /* Can NAN type be considered as beaconing interface? */
        case NL80211_IFTYPE_NAN:
                break;
        case NL80211_IFTYPE_UNSPECIFIED:
+       case NL80211_IFTYPE_WDS:
        case NUM_NL80211_IFTYPES:
                WARN_ON(1);
        }
                break;
        case NL80211_IFTYPE_MONITOR:
        case NL80211_IFTYPE_AP_VLAN:
-       case NL80211_IFTYPE_WDS:
        case NL80211_IFTYPE_P2P_DEVICE:
        case NL80211_IFTYPE_NAN:
                /* these interface types don't really have a channel */
                return;
        case NL80211_IFTYPE_UNSPECIFIED:
+       case NL80211_IFTYPE_WDS:
        case NUM_NL80211_IFTYPES:
                WARN_ON(1);
        }
 
                                return -EINVAL;
                }
 
-#ifndef CONFIG_WIRELESS_WDS
                if (WARN_ON(all_iftypes & BIT(NL80211_IFTYPE_WDS)))
                        return -EINVAL;
-#endif
 
                /* You can't even choose that many! */
                if (WARN_ON(cnt < c->max_interfaces))
                     !(wiphy->nan_supported_bands & BIT(NL80211_BAND_2GHZ)))))
                return -EINVAL;
 
-#ifndef CONFIG_WIRELESS_WDS
        if (WARN_ON(wiphy->interface_modes & BIT(NL80211_IFTYPE_WDS)))
                return -EINVAL;
-#endif
 
        if (WARN_ON(wiphy->pmsr_capa && !wiphy->pmsr_capa->ftm.supported))
                return -EINVAL;
        case NL80211_IFTYPE_OCB:
                __cfg80211_leave_ocb(rdev, dev);
                break;
-       case NL80211_IFTYPE_WDS:
-               /* must be handled by mac80211/driver, has no APIs */
-               break;
        case NL80211_IFTYPE_P2P_DEVICE:
        case NL80211_IFTYPE_NAN:
                /* cannot happen, has no netdev */
                /* nothing to do */
                break;
        case NL80211_IFTYPE_UNSPECIFIED:
+       case NL80211_IFTYPE_WDS:
        case NUM_NL80211_IFTYPES:
                /* invalid */
                break;
 
                if (nla_put_u32(msg, i, NL80211_CMD_SET_CHANNEL))
                        goto nla_put_failure;
        }
-       CMD(set_wds_peer, SET_WDS_PEER);
        if (rdev->wiphy.flags & WIPHY_FLAG_SUPPORTS_TDLS) {
                CMD(tdls_mgmt, TDLS_MGMT);
                CMD(tdls_oper, TDLS_OPER);
 static bool nl80211_can_set_dev_channel(struct wireless_dev *wdev)
 {
        /*
-        * You can only set the channel explicitly for WDS interfaces,
-        * all others have their channel managed via their respective
+        * You can only set the channel explicitly for some interfaces,
+        * most have their channel managed via their respective
         * "establish a connection" command (connect, join, ...)
         *
         * For AP/GO and mesh mode, the channel can be set with the
        return __nl80211_set_channel(rdev, netdev, info);
 }
 
-static int nl80211_set_wds_peer(struct sk_buff *skb, struct genl_info *info)
-{
-       struct cfg80211_registered_device *rdev = info->user_ptr[0];
-       struct net_device *dev = info->user_ptr[1];
-       struct wireless_dev *wdev = dev->ieee80211_ptr;
-       const u8 *bssid;
-
-       if (!info->attrs[NL80211_ATTR_MAC])
-               return -EINVAL;
-
-       if (netif_running(dev))
-               return -EBUSY;
-
-       if (!rdev->ops->set_wds_peer)
-               return -EOPNOTSUPP;
-
-       if (wdev->iftype != NL80211_IFTYPE_WDS)
-               return -EOPNOTSUPP;
-
-       bssid = nla_data(info->attrs[NL80211_ATTR_MAC]);
-       return rdev_set_wds_peer(rdev, dev, bssid);
-}
-
 static int nl80211_set_wiphy(struct sk_buff *skb, struct genl_info *info)
 {
        struct cfg80211_registered_device *rdev;
                .internal_flags = NL80211_FLAG_NEED_NETDEV |
                                  NL80211_FLAG_NEED_RTNL,
        },
-       {
-               .cmd = NL80211_CMD_SET_WDS_PEER,
-               .validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
-               .doit = nl80211_set_wds_peer,
-               .flags = GENL_UNS_ADMIN_PERM,
-               .internal_flags = NL80211_FLAG_NEED_NETDEV |
-                                 NL80211_FLAG_NEED_RTNL,
-       },
        {
                .cmd = NL80211_CMD_JOIN_MESH,
                .validate = GENL_DONT_VALIDATE_STRICT | GENL_DONT_VALIDATE_DUMP,
 
        return ret;
 }
 
-static inline int rdev_set_wds_peer(struct cfg80211_registered_device *rdev,
-                                   struct net_device *dev, const u8 *addr)
-{
-       int ret;
-       trace_rdev_set_wds_peer(&rdev->wiphy, dev, addr);
-       ret = rdev->ops->set_wds_peer(&rdev->wiphy, dev, addr);
-       trace_rdev_return_int(&rdev->wiphy, ret);
-       return ret;
-}
-
 static inline int
 rdev_set_multicast_to_unicast(struct cfg80211_registered_device *rdev,
                              struct net_device *dev,
 
        TP_ARGS(wiphy, netdev, mac)
 );
 
-DEFINE_EVENT(wiphy_netdev_mac_evt, rdev_set_wds_peer,
-       TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, const u8 *mac),
-       TP_ARGS(wiphy, netdev, mac)
-);
-
 TRACE_EVENT(rdev_dump_station,
        TP_PROTO(struct wiphy *wiphy, struct net_device *netdev, int _idx,
                 u8 *mac),
 
                        return -1;
                break;
        case cpu_to_le16(IEEE80211_FCTL_TODS | IEEE80211_FCTL_FROMDS):
-               if (unlikely(iftype != NL80211_IFTYPE_WDS &&
-                            iftype != NL80211_IFTYPE_MESH_POINT &&
+               if (unlikely(iftype != NL80211_IFTYPE_MESH_POINT &&
                             iftype != NL80211_IFTYPE_AP_VLAN &&
                             iftype != NL80211_IFTYPE_STATION))
                        return -1;
                case NL80211_IFTYPE_P2P_GO:
                case NL80211_IFTYPE_AP:
                case NL80211_IFTYPE_AP_VLAN:
-               case NL80211_IFTYPE_WDS:
                case NL80211_IFTYPE_MESH_POINT:
                        /* bridging OK */
                        break;
                        /* not happening */
                        break;
                case NL80211_IFTYPE_P2P_DEVICE:
+               case NL80211_IFTYPE_WDS:
                case NL80211_IFTYPE_NAN:
                        WARN_ON(1);
                        break;
 
        case IW_MODE_ADHOC:
                type = NL80211_IFTYPE_ADHOC;
                break;
-       case IW_MODE_REPEAT:
-               type = NL80211_IFTYPE_WDS;
-               break;
        case IW_MODE_MONITOR:
                type = NL80211_IFTYPE_MONITOR;
                break;
        return 0;
 }
 
-static int cfg80211_wds_wext_siwap(struct net_device *dev,
-                                  struct iw_request_info *info,
-                                  struct sockaddr *addr, char *extra)
-{
-       struct wireless_dev *wdev = dev->ieee80211_ptr;
-       struct cfg80211_registered_device *rdev = wiphy_to_rdev(wdev->wiphy);
-       int err;
-
-       if (WARN_ON(wdev->iftype != NL80211_IFTYPE_WDS))
-               return -EINVAL;
-
-       if (addr->sa_family != ARPHRD_ETHER)
-               return -EINVAL;
-
-       if (netif_running(dev))
-               return -EBUSY;
-
-       if (!rdev->ops->set_wds_peer)
-               return -EOPNOTSUPP;
-
-       err = rdev_set_wds_peer(rdev, dev, (u8 *)&addr->sa_data);
-       if (err)
-               return err;
-
-       memcpy(&wdev->wext.bssid, (u8 *) &addr->sa_data, ETH_ALEN);
-
-       return 0;
-}
-
-static int cfg80211_wds_wext_giwap(struct net_device *dev,
-                                  struct iw_request_info *info,
-                                  struct sockaddr *addr, char *extra)
-{
-       struct wireless_dev *wdev = dev->ieee80211_ptr;
-
-       if (WARN_ON(wdev->iftype != NL80211_IFTYPE_WDS))
-               return -EINVAL;
-
-       addr->sa_family = ARPHRD_ETHER;
-       memcpy(&addr->sa_data, wdev->wext.bssid, ETH_ALEN);
-
-       return 0;
-}
-
 static int cfg80211_wext_siwrate(struct net_device *dev,
                                 struct iw_request_info *info,
                                 struct iw_param *rate, char *extra)
                return cfg80211_ibss_wext_siwap(dev, info, ap_addr, extra);
        case NL80211_IFTYPE_STATION:
                return cfg80211_mgd_wext_siwap(dev, info, ap_addr, extra);
-       case NL80211_IFTYPE_WDS:
-               return cfg80211_wds_wext_siwap(dev, info, ap_addr, extra);
        default:
                return -EOPNOTSUPP;
        }
                return cfg80211_ibss_wext_giwap(dev, info, ap_addr, extra);
        case NL80211_IFTYPE_STATION:
                return cfg80211_mgd_wext_giwap(dev, info, ap_addr, extra);
-       case NL80211_IFTYPE_WDS:
-               return cfg80211_wds_wext_giwap(dev, info, ap_addr, extra);
        default:
                return -EOPNOTSUPP;
        }