Skip to content

Commit

Permalink
Open up the new pfcwd fixture for t0/t1. (sonic-net#16847)
Browse files Browse the repository at this point in the history
  • Loading branch information
rraghav-cisco authored Feb 21, 2025
1 parent 052c41c commit a3a0651
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
7 changes: 4 additions & 3 deletions tests/pfcwd/cisco/set_pfc_time.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,8 @@
# Verified on Q200 @ 100G port speed. e.g. 687 is bit time to pause for 50ms (clock at 900Mhz).

import math

# Replace INTERFACE with appropriate port when used
arg_interface = "INTERFACE"


def get_ifg_reg_list(slice_idx):
''' Gr2 does not have an ifg list, listify '''
Expand Down Expand Up @@ -67,4 +68,4 @@ def set_pfc512_bit_sec(interface, time_sec):
# Increase PFC pause time
num_ms = 50
print("Setting PFC frame time to {}ms".format(num_ms))
set_pfc512_bit_sec("INTERFACE", num_ms / 1000)
set_pfc512_bit_sec(arg_interface, num_ms / 1000)
3 changes: 1 addition & 2 deletions tests/pfcwd/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -267,8 +267,7 @@ def set_pfc_time_cisco_8000(
test_ports = setup_pfc_test['test_ports']

# Lets limit this to cisco and T2 only.
if not (duthost.facts['asic_type'] == "cisco-8000"
and duthost.get_facts().get("modular_chassis")):
if duthost.facts['asic_type'] != "cisco-8000":
yield
return

Expand Down

0 comments on commit a3a0651

Please sign in to comment.