revert 'Remove MAC alignment WA for Mellanox platforms.' (#2677)

Signed-off-by: Mykola Faryma <mykolaf@mellanox.com>
This commit is contained in:
Mykola F 2019-03-18 17:52:32 +02:00 committed by lguohan
parent 6341b87d1b
commit 1ddf4b75c9

View File

@ -56,7 +56,7 @@ def get_system_mac():
mac = mac.strip() mac = mac.strip()
# Align last byte of MAC if necessary # Align last byte of MAC if necessary
if version_info and version_info['asic_type'] == 'centec': if version_info and (version_info['asic_type'] == 'mellanox' or version_info['asic_type'] == 'centec'):
last_byte = mac[-2:] last_byte = mac[-2:]
aligned_last_byte = format(int(int(last_byte, 16) & 0b11000000), '02x') aligned_last_byte = format(int(int(last_byte, 16) & 0b11000000), '02x')
mac = mac[:-2] + aligned_last_byte mac = mac[:-2] + aligned_last_byte