Bring over some more status codes from the Linux iwlwifi driver.
The (eventual) intention is to create MIB counters for transmitted frame completion to count how many packets with each status are transmitted. Note the difference between A-MPDU and non A-MPDU status. Obtained from: Linux iwlwifi/dvm driver
This commit is contained in:
parent
1bba7a88fc
commit
f7efe7e999
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=271246
@ -1267,18 +1267,91 @@ struct iwn_ucode_info {
|
|||||||
} __packed;
|
} __packed;
|
||||||
|
|
||||||
/* Structures for IWN_TX_DONE notification. */
|
/* Structures for IWN_TX_DONE notification. */
|
||||||
#define IWN_TX_STATUS_MSK 0xff
|
|
||||||
#define TX_STATUS_SUCCESS 0x01
|
|
||||||
#define TX_STATUS_DIRECT_DONE 0x02
|
|
||||||
|
|
||||||
#define IWN_TX_SUCCESS 0x00
|
/*
|
||||||
#define IWN_TX_FAIL 0x80 /* all failures have 0x80 set */
|
* TX command response is sent after *agn* transmission attempts.
|
||||||
#define IWN_TX_FAIL_SHORT_LIMIT 0x82 /* too many RTS retries */
|
*
|
||||||
#define IWN_TX_FAIL_LONG_LIMIT 0x83 /* too many retries */
|
* both postpone and abort status are expected behavior from uCode. there is
|
||||||
#define IWN_TX_FAIL_FIFO_UNDERRRUN 0x84 /* tx fifo not kept running */
|
* no special operation required from driver; except for RFKILL_FLUSH,
|
||||||
#define IWN_TX_FAIL_DEST_IN_PS 0x88 /* sta found in power save */
|
* which required tx flush host command to flush all the tx frames in queues
|
||||||
#define IWN_TX_FAIL_TX_LOCKED 0x90 /* waiting to see traffic */
|
*/
|
||||||
#define IWN_TX_FAIL_STA_INVALID 0x8b /* XXX STA invalid (???) */
|
#define IWN_TX_STATUS_MSK 0x000000ff
|
||||||
|
#define IWN_TX_STATUS_DELAY_MSK 0x00000040
|
||||||
|
#define IWN_TX_STATUS_ABORT_MSK 0x00000080
|
||||||
|
#define IWN_TX_PACKET_MODE_MSK 0x0000ff00
|
||||||
|
#define IWN_TX_FIFO_NUMBER_MSK 0x00070000
|
||||||
|
#define IWN_TX_RESERVED 0x00780000
|
||||||
|
#define IWN_TX_POWER_PA_DETECT_MSK 0x7f800000
|
||||||
|
#define IWN_TX_ABORT_REQUIRED_MSK 0x80000000
|
||||||
|
|
||||||
|
/* Success status */
|
||||||
|
#define IWN_TX_STATUS_SUCCESS 0x01
|
||||||
|
#define IWN_TX_STATUS_DIRECT_DONE 0x02
|
||||||
|
|
||||||
|
/* postpone TX */
|
||||||
|
#define IWN_TX_STATUS_POSTPONE_DELAY 0x40
|
||||||
|
#define IWN_TX_STATUS_POSTPONE_FEW_BYTES 0x41
|
||||||
|
#define IWN_TX_STATUS_POSTPONE_BT_PRIO 0x42
|
||||||
|
#define IWN_TX_STATUS_POSTPONE_QUIET_PERIOD 0x43
|
||||||
|
#define IWN_TX_STATUS_POSTPONE_CALC_TTAK 0x44
|
||||||
|
|
||||||
|
/* Failures */
|
||||||
|
#define IWN_TX_FAIL 0x80 /* all failures have 0x80 set */
|
||||||
|
#define IWN_TX_STATUS_FAIL_INTERNAL_CROSSED_RETRY 0x81
|
||||||
|
#define IWN_TX_FAIL_SHORT_LIMIT 0x82 /* too many RTS retries */
|
||||||
|
#define IWN_TX_FAIL_LONG_LIMIT 0x83 /* too many retries */
|
||||||
|
#define IWN_TX_FAIL_FIFO_UNDERRRUN 0x84 /* tx fifo not kept running */
|
||||||
|
#define IWN_TX_STATUS_FAIL_DRAIN_FLOW 0x85
|
||||||
|
#define IWN_TX_STATUS_FAIL_RFKILL_FLUSH 0x86
|
||||||
|
#define IWN_TX_STATUS_FAIL_LIFE_EXPIRE 0x87
|
||||||
|
#define IWN_TX_FAIL_DEST_IN_PS 0x88 /* sta found in power save */
|
||||||
|
#define IWN_TX_STATUS_FAIL_HOST_ABORTED 0x89
|
||||||
|
#define IWN_TX_STATUS_FAIL_BT_RETRY 0x8a
|
||||||
|
#define IWN_TX_FAIL_STA_INVALID 0x8b /* XXX STA invalid (???) */
|
||||||
|
#define IWN_TX_STATUS_FAIL_FRAG_DROPPED 0x8c
|
||||||
|
#define IWN_TX_STATUS_FAIL_TID_DISABLE 0x8d
|
||||||
|
#define IWN_TX_STATUS_FAIL_FIFO_FLUSHED 0x8e
|
||||||
|
#define IWN_TX_STATUS_FAIL_INSUFFICIENT_CF_POLL 0x8f
|
||||||
|
#define IWN_TX_FAIL_TX_LOCKED 0x90 /* waiting to see traffic */
|
||||||
|
#define IWN_TX_STATUS_FAIL_NO_BEACON_ON_RADAR 0x91
|
||||||
|
|
||||||
|
/*
|
||||||
|
* TX command response for A-MPDU packet responses.
|
||||||
|
*
|
||||||
|
* The status response is different to the non A-MPDU responses.
|
||||||
|
* In addition, the sequence number is treated as the sequence
|
||||||
|
* number of the TX command, NOT the 802.11 sequence number!
|
||||||
|
*/
|
||||||
|
#define IWN_AGG_TX_STATE_TRANSMITTED 0x00
|
||||||
|
#define IWN_AGG_TX_STATE_UNDERRUN_MSK 0x01
|
||||||
|
#define IWN_AGG_TX_STATE_FEW_BYTES_MSK 0x04
|
||||||
|
#define IWN_AGG_TX_STATE_ABORT_MSK 0x08
|
||||||
|
|
||||||
|
#define IWN_AGG_TX_STATE_LAST_SENT_TTL_MSK 0x10
|
||||||
|
#define IWN_AGG_TX_STATE_LAST_SENT_TRY_CNT_MSK 0x20
|
||||||
|
|
||||||
|
#define IWN_AGG_TX_STATE_SCD_QUERY_MSK 0x80
|
||||||
|
|
||||||
|
#define IWN_AGG_TX_STATE_TEST_BAD_CRC32_MSK 0x100
|
||||||
|
|
||||||
|
#define IWN_AGG_TX_STATE_RESPONSE_MSK 0x1ff
|
||||||
|
#define IWN_AGG_TX_STATE_DUMP_TX_MSK 0x200
|
||||||
|
#define IWN_AGG_TX_STATE_DELAY_TX_MSK 0x400
|
||||||
|
|
||||||
|
#define IWN_AGG_TX_STATUS_MSK 0x00000fff
|
||||||
|
#define IWN_AGG_TX_TRY_MSK 0x0000f000
|
||||||
|
|
||||||
|
#define IWN_AGG_TX_STATE_LAST_SENT_MSK \
|
||||||
|
(IWN_AGG_TX_STATE_LAST_SENT_TTL_MSK | \
|
||||||
|
IWN_AGG_TX_STATE_LAST_SENT_TRY_CNT_MSK)
|
||||||
|
|
||||||
|
/* # tx attempts for first frame in aggregation */
|
||||||
|
#define IWN_AGG_TX_STATE_TRY_CNT_POS 12
|
||||||
|
#define IWN_AGG_TX_STATE_TRY_CNT_MSK 0xf000
|
||||||
|
|
||||||
|
/* Command ID and sequence number of Tx command for this frame */
|
||||||
|
#define IWN_AGG_TX_STATE_SEQ_NUM_POS 16
|
||||||
|
#define IWN_AGG_TX_STATE_SEQ_NUM_MSK 0xffff0000
|
||||||
|
|
||||||
struct iwn4965_tx_stat {
|
struct iwn4965_tx_stat {
|
||||||
uint8_t nframes;
|
uint8_t nframes;
|
||||||
@ -1405,6 +1478,12 @@ struct iwn_compressed_ba {
|
|||||||
uint64_t bitmap;
|
uint64_t bitmap;
|
||||||
uint16_t qid;
|
uint16_t qid;
|
||||||
uint16_t ssn;
|
uint16_t ssn;
|
||||||
|
/* extra fields starting with iwn5000 */
|
||||||
|
#if 0
|
||||||
|
uint8_t txed; /* number of frames sent */
|
||||||
|
uint8_t txed_2_done; /* number of frames acked */
|
||||||
|
uint16_t reserved1;
|
||||||
|
#endif
|
||||||
} __packed;
|
} __packed;
|
||||||
|
|
||||||
/* Structure for IWN_START_SCAN notification. */
|
/* Structure for IWN_START_SCAN notification. */
|
||||||
|
Loading…
Reference in New Issue
Block a user