Changes between Version 18 and Version 19 of 802.11/MAC/Support_HW


Ignore:
Timestamp:
Dec 14, 2016, 3:52:32 PM (7 years ago)
Author:
murphpo
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • 802.11/MAC/Support_HW

    v18 v19  
    196196}}}
    197197
     198Finally the backoff counter for Tx Controller A can be paused from software via the code below. The backoff counter must be paused when another Tx controller with higher priority is started (i.e. when a Beacon Tx must occur while an MPDU Tx defers).
     199{{{#!c
     200// Pause Tx Controller A backoff counter
     201wlan_mac_pause_backoff_tx_ctrl_A(1);
     202
     203// Verify Tx A backoff is paused - must check after asserting Pause in case backoff just expired
     204u32 mac_tx_ctrl_status;
     205
     206mac_tx_ctrl_status = wlan_mac_get_tx_ctrl_status();
     207if( ((mac_tx_ctrl_status & WLAN_MAC_TXCTRL_STATUS_MASK_TX_A_STATE) == WLAN_MAC_TXCTRL_STATUS_TX_A_STATE_DEFER) ||
     208    ((mac_tx_ctrl_status & WLAN_MAC_TXCTRL_STATUS_MASK_TX_A_STATE) == WLAN_MAC_TXCTRL_STATUS_TX_A_STATE_IDLE) ) {
     209
     210        // Backoff paused successfully - handle higher-priority Tx here
     211        ...
     212       
     213}
     214
     215// Resume Tx Controller A backoff counter
     216wlan_mac_pause_backoff_tx_ctrl_A(0);
     217}}}
     218
     219
    198220The Tx Controller A state machine is implemented as an m-code block in the {{{wlan_mac_hw}}} core. The m source code is in the repository at [browser:/ReferenceDesigns/w3_802.11/sysgen/wlan_mac_hw/mcode_blocks/mac_tx_ctrl_a_fsm.m mac_tx_ctrl_a_fsm.m]
    199221
     
    403425}}}
    404426
     427Finally the backoff counter for Tx Controllers C and D can be paused from software via the code below. The backoff counter must be paused when another Tx controller with higher priority is started.
     428{{{#!c
     429// Code below pauses/checks/resumes Tx C backoff
     430// Replace "C" with "D" in macros to control Tx D backoff
     431
     432// Pause Tx Controller C backoff counter
     433wlan_mac_pause_backoff_tx_ctrl_C(1);
     434
     435// Verify Tx C backoff is paused - must check after asserting Pause in case backoff just expired
     436u32 mac_tx_ctrl_status;
     437
     438mac_tx_ctrl_status = wlan_mac_get_tx_ctrl_status();
     439if( ((mac_tx_ctrl_status & WLAN_MAC_TXCTRL_STATUS_MASK_TX_C_STATE) == WLAN_MAC_TXCTRL_STATUS_TX_C_STATE_DEFER) ||
     440    ((mac_tx_ctrl_status & WLAN_MAC_TXCTRL_STATUS_MASK_TX_C_STATE) == WLAN_MAC_TXCTRL_STATUS_TX_C_STATE_IDLE) ) {
     441
     442        // Backoff paused successfully - handle higher-priority Tx here
     443        ...
     444       
     445}
     446
     447// Resume Tx Controller C backoff counter
     448wlan_mac_pause_backoff_tx_ctrl_C(0);
     449}}}
     450
     451
    405452The Tx Controller C/D state machine is implemented as an m-code block in the {{{wlan_mac_hw}}} core. The m source code is in the repository at [browser:/ReferenceDesigns/w3_802.11/sysgen/wlan_mac_hw/mcode_blocks/mac_tx_ctrl_cd_fsm.m mac_tx_ctrl_cd_fsm.m]
    406453