diff --git a/device/arista/x86_64-arista_7050_qx32/plugins b/device/arista/x86_64-arista_7050_qx32/plugins new file mode 120000 index 000000000000..5fbbf98a6284 --- /dev/null +++ b/device/arista/x86_64-arista_7050_qx32/plugins @@ -0,0 +1 @@ +../x86_64-arista_common/plugins/ \ No newline at end of file diff --git a/device/arista/x86_64-arista_7050_qx32/plugins/eeprom.py b/device/arista/x86_64-arista_7050_qx32/plugins/eeprom.py deleted file mode 100644 index 9da54dbf1b90..000000000000 --- a/device/arista/x86_64-arista_7050_qx32/plugins/eeprom.py +++ /dev/null @@ -1,13 +0,0 @@ -#!/usr/bin/env python - -""" -Arista 7050QX-32 eeprom plugin -Uses the arista driver library to obtain the TlvInfoDecoder -""" - -try: - import arista.utils.sonic_eeprom as arista_eeprom -except ImportError, e: - raise ImportError (str(e) + "- required module not found") - -board = arista_eeprom.getTlvInfoDecoder() diff --git a/device/arista/x86_64-arista_7050_qx32/plugins/led_control.py b/device/arista/x86_64-arista_7050_qx32/plugins/led_control.py deleted file mode 100644 index 8d387e513c6c..000000000000 --- a/device/arista/x86_64-arista_7050_qx32/plugins/led_control.py +++ /dev/null @@ -1,6 +0,0 @@ -try: - import arista.utils.sonic_leds as arista_leds -except ImportError, e: - raise ImportError (str(e) + "- required module not found") - -LedControl = arista_leds.getLedControl() diff --git a/device/arista/x86_64-arista_7050_qx32/plugins/psuutil.py b/device/arista/x86_64-arista_7050_qx32/plugins/psuutil.py deleted file mode 100644 index 1a8682ae3c67..000000000000 --- a/device/arista/x86_64-arista_7050_qx32/plugins/psuutil.py +++ /dev/null @@ -1,12 +0,0 @@ -# psuutil.py -# -# Platform-specific PSU interface for SONiC -# - -try: - import arista.utils.sonic_psu as arista_psuutil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -PsuUtil = arista_psuutil.getPsuUtil() diff --git a/device/arista/x86_64-arista_7050_qx32/plugins/sfputil.py b/device/arista/x86_64-arista_7050_qx32/plugins/sfputil.py deleted file mode 100644 index 9a6d770d460b..000000000000 --- a/device/arista/x86_64-arista_7050_qx32/plugins/sfputil.py +++ /dev/null @@ -1,12 +0,0 @@ -# sfputil.py -# -# Platform-specific SFP transceiver interface for SONiC -# - -try: - import arista.utils.sonic_sfputil as arista_sfputil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -SfpUtil = arista_sfputil.getSfpUtil() diff --git a/device/arista/x86_64-arista_7050_qx32s/plugins b/device/arista/x86_64-arista_7050_qx32s/plugins new file mode 120000 index 000000000000..5fbbf98a6284 --- /dev/null +++ b/device/arista/x86_64-arista_7050_qx32s/plugins @@ -0,0 +1 @@ +../x86_64-arista_common/plugins/ \ No newline at end of file diff --git a/device/arista/x86_64-arista_7050_qx32s/plugins/eeprom.py b/device/arista/x86_64-arista_7050_qx32s/plugins/eeprom.py deleted file mode 100644 index d1c6212219d4..000000000000 --- a/device/arista/x86_64-arista_7050_qx32s/plugins/eeprom.py +++ /dev/null @@ -1,13 +0,0 @@ -#!/usr/bin/env python - -""" -Arista 7050QX-32S eeprom plugin -Uses the arista driver library to obtain the TlvInfoDecoder -""" - -try: - import arista.utils.sonic_eeprom as arista_eeprom -except ImportError, e: - raise ImportError (str(e) + "- required module not found") - -board = arista_eeprom.getTlvInfoDecoder() diff --git a/device/arista/x86_64-arista_7050_qx32s/plugins/led_control.py b/device/arista/x86_64-arista_7050_qx32s/plugins/led_control.py deleted file mode 100644 index 8d387e513c6c..000000000000 --- a/device/arista/x86_64-arista_7050_qx32s/plugins/led_control.py +++ /dev/null @@ -1,6 +0,0 @@ -try: - import arista.utils.sonic_leds as arista_leds -except ImportError, e: - raise ImportError (str(e) + "- required module not found") - -LedControl = arista_leds.getLedControl() diff --git a/device/arista/x86_64-arista_7050_qx32s/plugins/psuutil.py b/device/arista/x86_64-arista_7050_qx32s/plugins/psuutil.py deleted file mode 100644 index 1a8682ae3c67..000000000000 --- a/device/arista/x86_64-arista_7050_qx32s/plugins/psuutil.py +++ /dev/null @@ -1,12 +0,0 @@ -# psuutil.py -# -# Platform-specific PSU interface for SONiC -# - -try: - import arista.utils.sonic_psu as arista_psuutil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -PsuUtil = arista_psuutil.getPsuUtil() diff --git a/device/arista/x86_64-arista_7050_qx32s/plugins/sfputil.py b/device/arista/x86_64-arista_7050_qx32s/plugins/sfputil.py deleted file mode 100644 index 9a6d770d460b..000000000000 --- a/device/arista/x86_64-arista_7050_qx32s/plugins/sfputil.py +++ /dev/null @@ -1,12 +0,0 @@ -# sfputil.py -# -# Platform-specific SFP transceiver interface for SONiC -# - -try: - import arista.utils.sonic_sfputil as arista_sfputil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -SfpUtil = arista_sfputil.getSfpUtil() diff --git a/device/arista/x86_64-arista_7060_cx32s/plugins b/device/arista/x86_64-arista_7060_cx32s/plugins new file mode 120000 index 000000000000..5fbbf98a6284 --- /dev/null +++ b/device/arista/x86_64-arista_7060_cx32s/plugins @@ -0,0 +1 @@ +../x86_64-arista_common/plugins/ \ No newline at end of file diff --git a/device/arista/x86_64-arista_7060_cx32s/plugins/eeprom.py b/device/arista/x86_64-arista_7060_cx32s/plugins/eeprom.py deleted file mode 100644 index 0cfe5109a300..000000000000 --- a/device/arista/x86_64-arista_7060_cx32s/plugins/eeprom.py +++ /dev/null @@ -1,13 +0,0 @@ -#!/usr/bin/env python - -""" -Arista 7060CX-32S eeprom plugin -Uses the arista driver library to obtain the TlvInfoDecoder -""" - -try: - import arista.utils.sonic_eeprom as arista_eeprom -except ImportError, e: - raise ImportError (str(e) + "- required module not found") - -board = arista_eeprom.getTlvInfoDecoder() diff --git a/device/arista/x86_64-arista_7060_cx32s/plugins/led_control.py b/device/arista/x86_64-arista_7060_cx32s/plugins/led_control.py deleted file mode 100644 index 8d387e513c6c..000000000000 --- a/device/arista/x86_64-arista_7060_cx32s/plugins/led_control.py +++ /dev/null @@ -1,6 +0,0 @@ -try: - import arista.utils.sonic_leds as arista_leds -except ImportError, e: - raise ImportError (str(e) + "- required module not found") - -LedControl = arista_leds.getLedControl() diff --git a/device/arista/x86_64-arista_7060_cx32s/plugins/psuutil.py b/device/arista/x86_64-arista_7060_cx32s/plugins/psuutil.py deleted file mode 100644 index 1a8682ae3c67..000000000000 --- a/device/arista/x86_64-arista_7060_cx32s/plugins/psuutil.py +++ /dev/null @@ -1,12 +0,0 @@ -# psuutil.py -# -# Platform-specific PSU interface for SONiC -# - -try: - import arista.utils.sonic_psu as arista_psuutil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -PsuUtil = arista_psuutil.getPsuUtil() diff --git a/device/arista/x86_64-arista_7060_cx32s/plugins/sfputil.py b/device/arista/x86_64-arista_7060_cx32s/plugins/sfputil.py deleted file mode 100644 index 9a6d770d460b..000000000000 --- a/device/arista/x86_64-arista_7060_cx32s/plugins/sfputil.py +++ /dev/null @@ -1,12 +0,0 @@ -# sfputil.py -# -# Platform-specific SFP transceiver interface for SONiC -# - -try: - import arista.utils.sonic_sfputil as arista_sfputil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -SfpUtil = arista_sfputil.getSfpUtil() diff --git a/device/arista/x86_64-arista_7060px4_32/plugins b/device/arista/x86_64-arista_7060px4_32/plugins new file mode 120000 index 000000000000..5fbbf98a6284 --- /dev/null +++ b/device/arista/x86_64-arista_7060px4_32/plugins @@ -0,0 +1 @@ +../x86_64-arista_common/plugins/ \ No newline at end of file diff --git a/device/arista/x86_64-arista_7170_64c/plugins b/device/arista/x86_64-arista_7170_64c/plugins new file mode 120000 index 000000000000..5fbbf98a6284 --- /dev/null +++ b/device/arista/x86_64-arista_7170_64c/plugins @@ -0,0 +1 @@ +../x86_64-arista_common/plugins/ \ No newline at end of file diff --git a/device/arista/x86_64-arista_7170_64c/plugins/eeprom.py b/device/arista/x86_64-arista_7170_64c/plugins/eeprom.py deleted file mode 100644 index d439e442ee33..000000000000 --- a/device/arista/x86_64-arista_7170_64c/plugins/eeprom.py +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env python - -try: - import arista.utils.sonic_eeprom as arista_eeprom -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - -board = arista_eeprom.getTlvInfoDecoder() diff --git a/device/arista/x86_64-arista_7170_64c/plugins/led_control.py b/device/arista/x86_64-arista_7170_64c/plugins/led_control.py deleted file mode 100644 index fae2d504beb6..000000000000 --- a/device/arista/x86_64-arista_7170_64c/plugins/led_control.py +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env python - -try: - import arista.utils.sonic_leds as arista_leds -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - -LedControl = arista_leds.getLedControl() diff --git a/device/arista/x86_64-arista_7170_64c/plugins/psuutil.py b/device/arista/x86_64-arista_7170_64c/plugins/psuutil.py deleted file mode 100644 index 1a8682ae3c67..000000000000 --- a/device/arista/x86_64-arista_7170_64c/plugins/psuutil.py +++ /dev/null @@ -1,12 +0,0 @@ -# psuutil.py -# -# Platform-specific PSU interface for SONiC -# - -try: - import arista.utils.sonic_psu as arista_psuutil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -PsuUtil = arista_psuutil.getPsuUtil() diff --git a/device/arista/x86_64-arista_7170_64c/plugins/sfputil.py b/device/arista/x86_64-arista_7170_64c/plugins/sfputil.py deleted file mode 100644 index 1357ad786434..000000000000 --- a/device/arista/x86_64-arista_7170_64c/plugins/sfputil.py +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env python - -try: - import arista.utils.sonic_sfputil as arista_sfputil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - -SfpUtil = arista_sfputil.getSfpUtil() diff --git a/device/arista/x86_64-arista_7260cx3_64/plugins b/device/arista/x86_64-arista_7260cx3_64/plugins new file mode 120000 index 000000000000..5fbbf98a6284 --- /dev/null +++ b/device/arista/x86_64-arista_7260cx3_64/plugins @@ -0,0 +1 @@ +../x86_64-arista_common/plugins/ \ No newline at end of file diff --git a/device/arista/x86_64-arista_7260cx3_64/plugins/eeprom.py b/device/arista/x86_64-arista_7260cx3_64/plugins/eeprom.py deleted file mode 100644 index c4485e895948..000000000000 --- a/device/arista/x86_64-arista_7260cx3_64/plugins/eeprom.py +++ /dev/null @@ -1,13 +0,0 @@ -#!/usr/bin/env python - -""" -Arista 7260CX3-64 eeprom plugin -Uses the arista driver library to obtain the TlvInfoDecoder -""" - -try: - import arista.utils.sonic_eeprom as arista_eeprom -except ImportError, e: - raise ImportError (str(e) + "- required module not found") - -board = arista_eeprom.getTlvInfoDecoder() diff --git a/device/arista/x86_64-arista_7260cx3_64/plugins/led_control.py b/device/arista/x86_64-arista_7260cx3_64/plugins/led_control.py deleted file mode 100644 index 8d387e513c6c..000000000000 --- a/device/arista/x86_64-arista_7260cx3_64/plugins/led_control.py +++ /dev/null @@ -1,6 +0,0 @@ -try: - import arista.utils.sonic_leds as arista_leds -except ImportError, e: - raise ImportError (str(e) + "- required module not found") - -LedControl = arista_leds.getLedControl() diff --git a/device/arista/x86_64-arista_7260cx3_64/plugins/psuutil.py b/device/arista/x86_64-arista_7260cx3_64/plugins/psuutil.py deleted file mode 100644 index 1a8682ae3c67..000000000000 --- a/device/arista/x86_64-arista_7260cx3_64/plugins/psuutil.py +++ /dev/null @@ -1,12 +0,0 @@ -# psuutil.py -# -# Platform-specific PSU interface for SONiC -# - -try: - import arista.utils.sonic_psu as arista_psuutil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -PsuUtil = arista_psuutil.getPsuUtil() diff --git a/device/arista/x86_64-arista_7260cx3_64/plugins/sfputil.py b/device/arista/x86_64-arista_7260cx3_64/plugins/sfputil.py deleted file mode 100644 index 9a6d770d460b..000000000000 --- a/device/arista/x86_64-arista_7260cx3_64/plugins/sfputil.py +++ /dev/null @@ -1,12 +0,0 @@ -# sfputil.py -# -# Platform-specific SFP transceiver interface for SONiC -# - -try: - import arista.utils.sonic_sfputil as arista_sfputil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - - -SfpUtil = arista_sfputil.getSfpUtil() diff --git a/device/arista/x86_64-arista_7280cr3_32p4/plugins b/device/arista/x86_64-arista_7280cr3_32p4/plugins new file mode 120000 index 000000000000..5fbbf98a6284 --- /dev/null +++ b/device/arista/x86_64-arista_7280cr3_32p4/plugins @@ -0,0 +1 @@ +../x86_64-arista_common/plugins/ \ No newline at end of file diff --git a/device/arista/x86_64-arista_7280cr3_32p4/plugins/eeprom.py b/device/arista/x86_64-arista_7280cr3_32p4/plugins/eeprom.py deleted file mode 100644 index d439e442ee33..000000000000 --- a/device/arista/x86_64-arista_7280cr3_32p4/plugins/eeprom.py +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env python - -try: - import arista.utils.sonic_eeprom as arista_eeprom -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - -board = arista_eeprom.getTlvInfoDecoder() diff --git a/device/arista/x86_64-arista_7280cr3_32p4/plugins/led_control.py b/device/arista/x86_64-arista_7280cr3_32p4/plugins/led_control.py deleted file mode 100644 index fae2d504beb6..000000000000 --- a/device/arista/x86_64-arista_7280cr3_32p4/plugins/led_control.py +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env python - -try: - import arista.utils.sonic_leds as arista_leds -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - -LedControl = arista_leds.getLedControl() diff --git a/device/arista/x86_64-arista_7280cr3_32p4/plugins/psuutil.py b/device/arista/x86_64-arista_7280cr3_32p4/plugins/psuutil.py deleted file mode 100644 index d5ff3063dd8c..000000000000 --- a/device/arista/x86_64-arista_7280cr3_32p4/plugins/psuutil.py +++ /dev/null @@ -1,8 +0,0 @@ -# psuutil.py - -try: - import arista.utils.sonic_psu as arista_psuutil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - -PsuUtil = arista_psuutil.getPsuUtil() diff --git a/device/arista/x86_64-arista_7280cr3_32p4/plugins/sfputil.py b/device/arista/x86_64-arista_7280cr3_32p4/plugins/sfputil.py deleted file mode 100644 index 1357ad786434..000000000000 --- a/device/arista/x86_64-arista_7280cr3_32p4/plugins/sfputil.py +++ /dev/null @@ -1,8 +0,0 @@ -#!/usr/bin/env python - -try: - import arista.utils.sonic_sfputil as arista_sfputil -except ImportError as e: - raise ImportError("%s - required module not found" % str(e)) - -SfpUtil = arista_sfputil.getSfpUtil() diff --git a/device/arista/x86_64-arista_7060px4_32/plugins/eeprom.py b/device/arista/x86_64-arista_common/plugins/eeprom.py similarity index 66% rename from device/arista/x86_64-arista_7060px4_32/plugins/eeprom.py rename to device/arista/x86_64-arista_common/plugins/eeprom.py index 02c7bc84bc13..5c0286979056 100644 --- a/device/arista/x86_64-arista_7060px4_32/plugins/eeprom.py +++ b/device/arista/x86_64-arista_common/plugins/eeprom.py @@ -1,5 +1,10 @@ #!/usr/bin/env python +# +# Arista eeprom processing for SONiC +# Uses the arista driver library to obtain the TlvInfoDecoder +# + try: import arista.utils.sonic_eeprom as arista_eeprom except ImportError as e: diff --git a/device/arista/x86_64-arista_7060px4_32/plugins/led_control.py b/device/arista/x86_64-arista_common/plugins/led_control.py similarity index 75% rename from device/arista/x86_64-arista_7060px4_32/plugins/led_control.py rename to device/arista/x86_64-arista_common/plugins/led_control.py index e1fb4f26181d..febb04ad1616 100644 --- a/device/arista/x86_64-arista_7060px4_32/plugins/led_control.py +++ b/device/arista/x86_64-arista_common/plugins/led_control.py @@ -1,3 +1,9 @@ +#!/usr/bin/env python + +# +# Arista LED controls for SONiC +# + try: import arista.utils.sonic_leds as arista_leds except ImportError as e: diff --git a/device/arista/x86_64-arista_7060px4_32/plugins/psuutil.py b/device/arista/x86_64-arista_common/plugins/psuutil.py similarity index 76% rename from device/arista/x86_64-arista_7060px4_32/plugins/psuutil.py rename to device/arista/x86_64-arista_common/plugins/psuutil.py index 075f0e049a2c..46ec6b32e2e4 100644 --- a/device/arista/x86_64-arista_7060px4_32/plugins/psuutil.py +++ b/device/arista/x86_64-arista_common/plugins/psuutil.py @@ -1,6 +1,7 @@ -# psuutil.py +#!/usr/bin/env python + # -# Platform-specific PSU interface for SONiC +# Arista PSU interface for SONiC # try: diff --git a/device/arista/x86_64-arista_7060px4_32/plugins/sfputil.py b/device/arista/x86_64-arista_common/plugins/sfputil.py similarity index 73% rename from device/arista/x86_64-arista_7060px4_32/plugins/sfputil.py rename to device/arista/x86_64-arista_common/plugins/sfputil.py index de4de867f0e5..5e02eef69aef 100644 --- a/device/arista/x86_64-arista_7060px4_32/plugins/sfputil.py +++ b/device/arista/x86_64-arista_common/plugins/sfputil.py @@ -1,6 +1,7 @@ -# sfputil.py +#!/usr/bin/env python + # -# Platform-specific SFP transceiver interface for SONiC +# Arista SFP transceiver interface for SONiC # try: diff --git a/platform/barefoot/sonic-platform-modules-arista b/platform/barefoot/sonic-platform-modules-arista index 0ed1df5a7d6c..7b7c79ee463b 160000 --- a/platform/barefoot/sonic-platform-modules-arista +++ b/platform/barefoot/sonic-platform-modules-arista @@ -1 +1 @@ -Subproject commit 0ed1df5a7d6c88319ce41b10ce604c2727afab69 +Subproject commit 7b7c79ee463b43e570c48915215cdbf6ec250225 diff --git a/platform/broadcom/sonic-platform-modules-arista b/platform/broadcom/sonic-platform-modules-arista index 0ed1df5a7d6c..7b7c79ee463b 160000 --- a/platform/broadcom/sonic-platform-modules-arista +++ b/platform/broadcom/sonic-platform-modules-arista @@ -1 +1 @@ -Subproject commit 0ed1df5a7d6c88319ce41b10ce604c2727afab69 +Subproject commit 7b7c79ee463b43e570c48915215cdbf6ec250225