]> git.ipfire.org Git - thirdparty/hostap.git/commitdiff
nl80211: Rename send_action_cookie to send_frame_cookie
authorJouni Malinen <j@w1.fi>
Fri, 3 Jan 2020 13:23:49 +0000 (15:23 +0200)
committerJouni Malinen <j@w1.fi>
Fri, 3 Jan 2020 13:23:49 +0000 (15:23 +0200)
This is to match the NL80211_CMD_ACTION renaming to NL80211_CMD_FRAME
that happened long time ago. This command can be used with any IEEE
802.11 frame and it should not be implied to be limited to Action
frames.

Signed-off-by: Jouni Malinen <j@w1.fi>
src/drivers/driver_nl80211.c
src/drivers/driver_nl80211.h
src/drivers/driver_nl80211_event.c

index 93fa457db3b8a4c324fdc08ed87ee9f0f63e5643..c7c4042a6c097270d5de735b2d02be97ef10f0c4 100644 (file)
@@ -7480,21 +7480,21 @@ static int nl80211_send_frame_cmd(struct i802_bss *bss,
                           (long long unsigned int) cookie);
 
                if (save_cookie)
-                       drv->send_action_cookie = no_ack ? (u64) -1 : cookie;
+                       drv->send_frame_cookie = no_ack ? (u64) -1 : cookie;
 
-               if (drv->num_send_action_cookies == MAX_SEND_ACTION_COOKIES) {
+               if (drv->num_send_frame_cookies == MAX_SEND_FRAME_COOKIES) {
                        wpa_printf(MSG_DEBUG,
-                                  "nl80211: Drop oldest pending send action cookie 0x%llx",
+                                  "nl80211: Drop oldest pending send frame cookie 0x%llx",
                                   (long long unsigned int)
-                                  drv->send_action_cookies[0]);
-                       os_memmove(&drv->send_action_cookies[0],
-                                  &drv->send_action_cookies[1],
-                                  (MAX_SEND_ACTION_COOKIES - 1) *
+                                  drv->send_frame_cookies[0]);
+                       os_memmove(&drv->send_frame_cookies[0],
+                                  &drv->send_frame_cookies[1],
+                                  (MAX_SEND_FRAME_COOKIES - 1) *
                                   sizeof(u64));
-                       drv->num_send_action_cookies--;
+                       drv->num_send_frame_cookies--;
                }
-               drv->send_action_cookies[drv->num_send_action_cookies] = cookie;
-               drv->num_send_action_cookies++;
+               drv->send_frame_cookies[drv->num_send_frame_cookies] = cookie;
+               drv->num_send_frame_cookies++;
        }
 
 fail:
@@ -7585,19 +7585,19 @@ static void wpa_driver_nl80211_send_action_cancel_wait(void *priv)
        u64 cookie;
 
        /* Cancel the last pending TX cookie */
-       nl80211_frame_wait_cancel(bss, drv->send_action_cookie);
+       nl80211_frame_wait_cancel(bss, drv->send_frame_cookie);
 
        /*
         * Cancel the other pending TX cookies, if any. This is needed since
         * the driver may keep a list of all pending offchannel TX operations
         * and free up the radio only once they have expired or cancelled.
         */
-       for (i = drv->num_send_action_cookies; i > 0; i--) {
-               cookie = drv->send_action_cookies[i - 1];
-               if (cookie != drv->send_action_cookie)
+       for (i = drv->num_send_frame_cookies; i > 0; i--) {
+               cookie = drv->send_frame_cookies[i - 1];
+               if (cookie != drv->send_frame_cookie)
                        nl80211_frame_wait_cancel(bss, cookie);
        }
-       drv->num_send_action_cookies = 0;
+       drv->num_send_frame_cookies = 0;
 }
 
 
index cbafc1bb053e8f8c12f76c5566717cccf4d68c38..e4d81b12503a67b4884f1e0334f8902c033304d2 100644 (file)
@@ -169,10 +169,10 @@ struct wpa_driver_nl80211_data {
 
        u64 vendor_scan_cookie;
        u64 remain_on_chan_cookie;
-       u64 send_action_cookie;
-#define MAX_SEND_ACTION_COOKIES 20
-       u64 send_action_cookies[MAX_SEND_ACTION_COOKIES];
-       unsigned int num_send_action_cookies;
+       u64 send_frame_cookie;
+#define MAX_SEND_FRAME_COOKIES 20
+       u64 send_frame_cookies[MAX_SEND_FRAME_COOKIES];
+       unsigned int num_send_frame_cookies;
 
        unsigned int last_mgmt_freq;
 
index 2aecc7492c85276cd4a1b8a724ac966bc5ba3fca..6c6e5c185d8928c8cc26a2e16262518fd2a749dc 100644 (file)
@@ -694,12 +694,12 @@ static void mlme_event_mgmt_tx_status(struct wpa_driver_nl80211_data *drv,
                        return;
 
                cookie_val = nla_get_u64(cookie);
-               wpa_printf(MSG_DEBUG, "nl80211: Action TX status:"
-                          " cookie=0x%llx%s (ack=%d)",
+               wpa_printf(MSG_DEBUG,
+                          "nl80211: Frame TX status: cookie=0x%llx%s (ack=%d)",
                           (long long unsigned int) cookie_val,
-                          cookie_val == drv->send_action_cookie ?
+                          cookie_val == drv->send_frame_cookie ?
                           " (match)" : " (unknown)", ack != NULL);
-               if (cookie_val != drv->send_action_cookie)
+               if (cookie_val != drv->send_frame_cookie)
                        return;
        }