diff --git a/src/frame-xchg.c b/src/frame-xchg.c index e0174732..4a4db561 100644 --- a/src/frame-xchg.c +++ b/src/frame-xchg.c @@ -906,8 +906,6 @@ static void frame_xchg_tx_cb(struct l_genl_msg *msg, void *user_data) fx->tx_cmd_id = 0; - l_debug("err %i", -error); - if (error < 0) { if (error == -EBUSY) { fx->timeout = l_timeout_create_ms(fx->retry_interval, @@ -926,6 +924,8 @@ static void frame_xchg_tx_cb(struct l_genl_msg *msg, void *user_data) goto error; } + l_debug("Frame sent, cookie: %"PRIu64" obtained", cookie); + early_status = fx->early_status && cookie == fx->cookie; fx->tx_acked = early_status && fx->tx_acked; fx->have_cookie = true; @@ -1269,13 +1269,14 @@ static void frame_xchg_mlme_notify(struct l_genl_msg *msg, void *user_data) NL80211_ATTR_UNSPEC) < 0) return; - l_debug("Received %s", ack ? "an ACK" : "no ACK"); - fx = l_queue_find(frame_xchgs, frame_xchg_match_running, &wdev_id); if (!fx) return; + l_debug("Received %s for cookie: %"PRIu64, + ack ? "an ACK" : "no ACK", cookie); + if (fx->have_cookie && cookie == fx->cookie && !fx->tx_acked) frame_xchg_tx_status(fx, ack); else if (!fx->have_cookie && !fx->tx_acked) {