Esempio n. 1
0
def check_qos_map(ap, hapd, dev, sta, dscp, tid, ap_tid=None):
    if not ap_tid:
        ap_tid = tid
    bssid = ap['bssid']
    wt = Wlantest()
    wt.clear_sta_counters(bssid, sta)
    hwsim_utils.test_connectivity(dev, hapd, dscp=dscp, config=False)
    time.sleep(0.02)
    tx = wt.get_tx_tid(bssid, sta, tid)
    if tx == 0:
        [ tx, rx ] = wt.get_tid_counters(bssid, sta)
        logger.info("Expected TX DSCP " + str(dscp) + " with TID " + str(tid) + " but counters: " + str(tx))
        raise Exception("No STA->AP data frame using the expected TID")
    rx = wt.get_rx_tid(bssid, sta, ap_tid)
    if rx == 0:
        [ tx, rx ] = wt.get_tid_counters(bssid, sta)
        logger.info("Expected RX DSCP " + str(dscp) + " with TID " + str(ap_tid) + " but counters: " + str(rx))
        raise Exception("No AP->STA data frame using the expected TID")
Esempio n. 2
0
def check_qos_map(ap, hapd, dev, sta, dscp, tid, ap_tid=None):
    if not ap_tid:
        ap_tid = tid
    bssid = ap['bssid']
    wt = Wlantest()
    wt.clear_sta_counters(bssid, sta)
    hwsim_utils.test_connectivity(dev, hapd, dscp=dscp, config=False)
    time.sleep(0.02)
    tx = wt.get_tx_tid(bssid, sta, tid)
    if tx == 0:
        [tx, rx] = wt.get_tid_counters(bssid, sta)
        logger.info("Expected TX DSCP " + str(dscp) + " with TID " + str(tid) +
                    " but counters: " + str(tx))
        raise Exception("No STA->AP data frame using the expected TID")
    rx = wt.get_rx_tid(bssid, sta, ap_tid)
    if rx == 0:
        [tx, rx] = wt.get_tid_counters(bssid, sta)
        logger.info("Expected RX DSCP " + str(dscp) + " with TID " +
                    str(ap_tid) + " but counters: " + str(rx))
        raise Exception("No AP->STA data frame using the expected TID")