Added an option to add (or override) Credential attribute(s) in M8
[wpasupplicant] / hostapd / driver_nl80211.c
index a7300bc..508a379 100644 (file)
@@ -36,6 +36,7 @@
 #include "mlme.h"
 #include "radiotap.h"
 #include "radiotap_iter.h"
+#include "ieee802_11_defs.h"
 
 #ifdef CONFIG_LIBNL20
 /* libnl 2.0 compatibility code */
@@ -608,14 +609,14 @@ static int i802_set_retry(void *priv, int short_retry, int long_retry)
 
        iwr.u.retry.value = short_retry;
        iwr.u.retry.flags = IW_RETRY_LIMIT | IW_RETRY_MIN;
-       if (ioctl(drv->ioctl_sock, SIOCSIWFRAG, &iwr) < 0) {
+       if (ioctl(drv->ioctl_sock, SIOCSIWRETRY, &iwr) < 0) {
                perror("ioctl[SIOCSIWRETRY(short)]");
                return -1;
        }
 
        iwr.u.retry.value = long_retry;
        iwr.u.retry.flags = IW_RETRY_LIMIT | IW_RETRY_MAX;
-       if (ioctl(drv->ioctl_sock, SIOCSIWFRAG, &iwr) < 0) {
+       if (ioctl(drv->ioctl_sock, SIOCSIWRETRY, &iwr) < 0) {
                perror("ioctl[SIOCSIWRETRY(long)]");
                return -1;
        }
@@ -919,12 +920,6 @@ static int i802_sta_set_flags(void *priv, const u8 *addr,
 }
 
 
-static int i802_set_regulatory_domain(void *priv, unsigned int rd)
-{
-       return -1;
-}
-
-
 static int i802_set_tx_queue_params(void *priv, int queue, int aifs,
                                    int cw_min, int cw_max, int burst_time)
 {
@@ -1967,8 +1962,6 @@ static int i802_init_sockets(struct i802_driver_data *drv, const u8 *bssid)
        struct ifreq ifr;
        struct sockaddr_ll addr;
 
-       drv->ioctl_sock = -1;
-
        drv->ioctl_sock = socket(PF_INET, SOCK_DGRAM, 0);
        if (drv->ioctl_sock < 0) {
                perror("socket[PF_INET,SOCK_DGRAM]");
@@ -2494,7 +2487,6 @@ const struct wpa_driver_ops wpa_driver_nl80211_ops = {
        .set_retry = i802_set_retry,
        .get_retry = i802_get_retry,
        .set_rate_sets = i802_set_rate_sets,
-       .set_regulatory_domain = i802_set_regulatory_domain,
        .set_beacon = i802_set_beacon,
        .set_internal_bridge = i802_set_internal_bridge,
        .set_beacon_int = i802_set_beacon_int,