90
90
y_cable_port_instances = {}
91
91
y_cable_port_locks = {}
92
92
93
+ disable_telemetry = False
93
94
94
95
Y_CABLE_STATUS_NO_TOR_ACTIVE = 0
95
96
Y_CABLE_STATUS_TORA_ACTIVE = 1
@@ -1505,6 +1506,11 @@ def delete_ports_status_for_y_cable():
1505
1506
1506
1507
def check_identifier_presence_and_update_mux_info_entry (state_db , mux_tbl , asic_index , logical_port_name ):
1507
1508
1509
+ global disable_telemetry
1510
+
1511
+ if disable_telemetry == True :
1512
+ return
1513
+
1508
1514
# Get the namespaces in the platform
1509
1515
config_db , port_tbl = {}, {}
1510
1516
namespaces = multi_asic .get_front_end_namespaces ()
@@ -3537,6 +3543,8 @@ def task_worker(self):
3537
3543
3538
3544
def task_cli_worker (self ):
3539
3545
3546
+ global disable_telemetry
3547
+
3540
3548
# Connect to STATE_DB and APPL_DB and get both the HW_MUX_STATUS_TABLE info
3541
3549
appl_db , config_db , state_db , y_cable_tbl = {}, {}, {}, {}
3542
3550
xcvrd_log_tbl = {}
@@ -3730,8 +3738,8 @@ def task_cli_worker(self):
3730
3738
helper_logger .log_notice ("Y_CABLE_DEBUG: trying to enable/disable debug logs" )
3731
3739
if fvp_m :
3732
3740
3733
- if key = = "Y_CABLE" :
3734
- continue
3741
+ if key ! = "Y_CABLE" :
3742
+ break
3735
3743
3736
3744
fvp_dict = dict (fvp_m )
3737
3745
if "log_verbosity" in fvp_dict :
@@ -3743,6 +3751,16 @@ def task_cli_worker(self):
3743
3751
3744
3752
elif probe_identifier == "notice" :
3745
3753
helper_logger .set_min_log_priority_notice ()
3754
+ if "disable_telemetry" in fvp_dict :
3755
+ # check if xcvrd got a probe command
3756
+ enable = fvp_dict ["disable_telemetry" ]
3757
+
3758
+ helper_logger .log_notice ("Y_CABLE_DEBUG: trying to enable/disable telemetry flag to {}" .format (enable ))
3759
+ if enable == "True" :
3760
+ disable_telemetry = True
3761
+
3762
+ elif enable == "False" :
3763
+ disable_telemetry = False
3746
3764
3747
3765
while True :
3748
3766
# show muxcable hwmode state <port>
0 commit comments