-
Notifications
You must be signed in to change notification settings - Fork 1.5k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Backport ethtool to support QSFP-DD (#5725)
Backport ethtool debian package version 5.9 to support QSFP-DD cable parsing. Signed-off-by: Shlomi Bitton <shlomibi@nvidia.com>
- Loading branch information
1 parent
1f7d9e2
commit 43d4d45
Showing
6 changed files
with
42 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -22,7 +22,6 @@ RUN apt-get update && \ | |
rrdtool \ | ||
python-smbus \ | ||
python3-smbus \ | ||
ethtool \ | ||
dmidecode \ | ||
i2c-tools | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
SPATH := $($(ETHTOOL)_SRC_PATH) | ||
DEP_FILES := $(SONIC_COMMON_FILES_LIST) rules/ethtool.mk rules/ethtool.dep | ||
DEP_FILES += $(SONIC_COMMON_BASE_FILES_LIST) | ||
DEP_FILES += $(shell git ls-files $(SPATH)) | ||
|
||
$(ETHTOOL)_CACHE_MODE := GIT_CONTENT_SHA | ||
$(ETHTOOL)_DEP_FLAGS := $(SONIC_COMMON_FLAGS_LIST) | ||
$(ETHTOOL)_DEP_FILES := $(DEP_FILES) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
# ethtool | ||
|
||
ETHTOOL_VERSION_BASE = 5.9 | ||
export ETHTOOL_VERSION_BASE | ||
|
||
ETHTOOL = ethtool_$(ETHTOOL_VERSION_BASE)-1_amd64.deb | ||
$(ETHTOOL)_SRC_PATH = $(SRC_PATH)/ethtool | ||
SONIC_MAKE_DEBS += $(ETHTOOL) | ||
|
||
ETHTOOL_DBG = ethtool-dbgsym_$(ETHTOOL_VERSION_BASE)-1_amd64.deb | ||
$(eval $(call add_extra_package,$(ETHTOOL),$(ETHTOOL_DBG))) | ||
|
||
export ETHTOOL ETHTOOL_DBG |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
.ONESHELL: | ||
SHELL = /bin/bash | ||
.SHELLFLAGS += -e | ||
|
||
MAIN_TARGET = $(ETHTOOL) | ||
DERIVED_TARGET = $(ETHTOOL_DBG) | ||
|
||
$(addprefix $(DEST)/, $(MAIN_TARGET)): $(DEST)/% : | ||
# Obtaining the ethtool debian package | ||
rm -rf ethtool* | ||
git clone https://salsa.debian.org/kernel-team/ethtool/ | ||
pushd ethtool | ||
git checkout tags/debian/1%$(ETHTOOL_VERSION_BASE)-1 | ||
# Build package | ||
dpkg-buildpackage -rfakeroot -b -us -uc -j$(SONIC_CONFIG_MAKE_JOBS) --admindir $(SONIC_DPKG_ADMINDIR) | ||
popd | ||
mv $(DERIVED_TARGET) $* $(DEST)/ | ||
|
||
$(addprefix $(DEST)/, $(DERIVED_TARGET)): $(DEST)/% : $(DEST)/$(MAIN_TARGET) |