Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Mellanox] Add phy debug tools for SN3800 #13

Closed
wants to merge 9 commits into from
Closed
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions files/build_templates/sonic_debian_extension.j2
Original file line number Diff line number Diff line change
Expand Up @@ -610,6 +610,8 @@ sudo cp $files_path/$ISSU_VERSION_FILE $FILESYSTEM_ROOT/etc/mlnx/issu-version
sudo cp $files_path/$MLNX_FFB_SCRIPT $FILESYSTEM_ROOT/usr/bin/mlnx-ffb.sh
sudo cp $files_path/$MLNX_ONIE_FW_UPDATE $FILESYSTEM_ROOT/usr/bin/$MLNX_ONIE_FW_UPDATE
sudo cp $files_path/$MLNX_SSD_FW_UPDATE $FILESYSTEM_ROOT/usr/bin/$MLNX_SSD_FW_UPDATE
sudo dpkg --root=$FILESYSTEM_ROOT -i $debs_path/$MLNX_PHY_DEBUG_TOOLS || \

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@noaOrMlnx can we avoid this? Looks like this should be enough:
$(SONIC_ONE_IMAGE)_INSTALLS += ... $(MLNX_PHY_DEBUG_TOOLS)

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@nazariig
removed

sudo LANG=C DEBIAN_FRONTEND=noninteractive chroot $FILESYSTEM_ROOT apt-get -y install -f
j2 platform/mellanox/mlnx-fw-upgrade.j2 | sudo tee $FILESYSTEM_ROOT/usr/bin/mlnx-fw-upgrade.sh
sudo chmod 755 $FILESYSTEM_ROOT/usr/bin/mlnx-fw-upgrade.sh

Expand Down
9 changes: 9 additions & 0 deletions platform/mellanox/mlnx-phy-debug-tools.mk
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Mellanox phy debug tools scripts

DEBUG_TOOLS_VERSION = 1.0.0
MLNX_PHY_DEBUG_TOOLS = mlnx-phy-debug-tools_$(DEBUG_TOOLS_VERSION)_amd64.deb
$(MLNX_PHY_DEBUG_TOOLS)_SRC_PATH = $(PLATFORM_PATH)/mlnx-phy-debug-tools

SONIC_DPKG_DEBS += $(MLNX_PHY_DEBUG_TOOLS)

export MLNX_PHY_DEBUG_TOOLS
6 changes: 6 additions & 0 deletions platform/mellanox/mlnx-phy-debug-tools/debian/changelog
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
mlnx-phy-debug-tools (1.0.0) unstable; urgency=low

* Initial Release

-- Noa Or <[email protected]> Tue, 24 Nov 2020 12:30:00 +0300

1 change: 1 addition & 0 deletions platform/mellanox/mlnx-phy-debug-tools/debian/compat
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
9
9 changes: 9 additions & 0 deletions platform/mellanox/mlnx-phy-debug-tools/debian/control
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
Source: mlnx-phy-debug-tools
Priority: optional
Maintainer: Noa Or <[email protected]>
Section: custom
Homepage: http://www.mellanox.com

Package: mlnx-phy-debug-tools
Architecture: any
Description: Mellanox Phy debug tools for MSN3800
13 changes: 13 additions & 0 deletions platform/mellanox/mlnx-phy-debug-tools/debian/copyright
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Copyright (C) 2020. Mellanox Technologies, Ltd. ALL RIGHTS RESERVED.

Licensed under the Apache License, Version 2.0 (the "License"); you may
not use this file except in compliance with the License. You may obtain
a copy of the License at http://www.apache.org/licenses/LICENSE-2.0

THIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR
CONDITIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT
LIMITATION ANY IMPLIED WARRANTIES OR CONDITIONS OF TITLE, FITNESS
FOR A PARTICULAR PURPOSE, MERCHANTABLITY OR NON-INFRINGEMENT.

See the Apache Version 2.0 License for specific language governing
permissions and limitations under the License.
1 change: 1 addition & 0 deletions platform/mellanox/mlnx-phy-debug-tools/debian/install
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
usr/* /usr/
5 changes: 5 additions & 0 deletions platform/mellanox/mlnx-phy-debug-tools/debian/rules
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/usr/bin/make -f


%:
dh $@
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
2 changes: 1 addition & 1 deletion platform/mellanox/one-image.mk
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
SONIC_ONE_IMAGE = sonic-mellanox.bin
$(SONIC_ONE_IMAGE)_MACHINE = mellanox
$(SONIC_ONE_IMAGE)_IMAGE_TYPE = onie
$(SONIC_ONE_IMAGE)_INSTALLS += $(SX_KERNEL) $(KERNEL_MFT) $(MFT_OEM) $(MFT) $(MLNX_HW_MANAGEMENT)
$(SONIC_ONE_IMAGE)_INSTALLS += $(SX_KERNEL) $(KERNEL_MFT) $(MFT_OEM) $(MFT) $(MLNX_HW_MANAGEMENT) $(MLNX_PHY_DEBUG_TOOLS)
$(SONIC_ONE_IMAGE)_INSTALLS += $(SYSTEMD_SONIC_GENERATOR)
ifeq ($(INSTALL_DEBUG_TOOLS),y)
$(SONIC_ONE_IMAGE)_DOCKERS += $(SONIC_INSTALL_DOCKER_DBG_IMAGES)
Expand Down
1 change: 1 addition & 0 deletions platform/mellanox/rules.mk
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ include $(PLATFORM_PATH)/mlnx-platform-api.mk
include $(PLATFORM_PATH)/docker-syncd-mlnx.mk
include $(PLATFORM_PATH)/docker-syncd-mlnx-rpc.mk
include $(PLATFORM_PATH)/docker-saiserver-mlnx.mk
include $(PLATFORM_PATH)/mlnx-phy-debug-tools.mk
include $(PLATFORM_PATH)/one-image.mk
include $(PLATFORM_PATH)/libsaithrift-dev.mk
include $(PLATFORM_PATH)/docker-ptf-mlnx.mk
Expand Down