Skip to content

Commit 722d25d

Browse files
sihuihan88lguohan
authored andcommitted
[pfcwd]: enable pfcwd on all port by default (sonic-net#307)
Signed-off-by: Sihui Han <[email protected]>
1 parent 04a62dd commit 722d25d

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

pfcwd/main.py

+2-6
Original file line numberDiff line numberDiff line change
@@ -198,15 +198,11 @@ def start_default():
198198
configdb.connect()
199199
enable = configdb.get_entry('DEVICE_METADATA', 'localhost').get('default_pfcwd_status')
200200

201-
server_facing_ports = get_server_facing_ports(configdb)
201+
all_ports = get_all_ports(configdb)
202202

203203
if not enable or enable.lower() != "enable":
204204
return
205205

206-
device_type = configdb.get_entry('DEVICE_METADATA', 'localhost').get('type')
207-
if device_type.lower() != "torrouter":
208-
return
209-
210206
port_num = len(configdb.get_table('PORT').keys())
211207

212208
# Paramter values positively correlate to the number of ports.
@@ -217,7 +213,7 @@ def start_default():
217213
'action': DEFAULT_ACTION
218214
}
219215

220-
for port in server_facing_ports:
216+
for port in all_ports:
221217
configdb.set_entry("PFC_WD_TABLE", port, pfcwd_info)
222218

223219
pfcwd_info = {}

0 commit comments

Comments
 (0)