[pcie.yaml] Move pcie configuration file path to platform directory (#6475)
- Why I did it The pcie configuration file location is under plugin directory not under platform directory. #6437 - How I did it Move all pcie.yaml configuration file from plugin to platform directory. Remove unnecessary timer to start pcie-check.service Move pcie-check.service to sonic-host-services - How to verify it Verify on the device
This commit is contained in:
parent
7fb5a72d23
commit
15aed52ef2
7
.gitignore
vendored
7
.gitignore
vendored
@ -56,6 +56,13 @@ platform/**/*-none-any.whl
|
|||||||
platform/**/.pybuild
|
platform/**/.pybuild
|
||||||
platform/**/debian/*
|
platform/**/debian/*
|
||||||
platform/**/build
|
platform/**/build
|
||||||
|
platform/**/*.ko
|
||||||
|
platform/**/*.mod.c
|
||||||
|
platform/**/*.mod.o
|
||||||
|
platform/**/*.o
|
||||||
|
platform/**/*.d
|
||||||
|
platform/**/*.cmd
|
||||||
|
platform/**/*.order
|
||||||
platform/broadcom/sonic-platform-modules-dell/s5232f/sonic_platform/ipmihelper.py
|
platform/broadcom/sonic-platform-modules-dell/s5232f/sonic_platform/ipmihelper.py
|
||||||
platform/broadcom/sonic-platform-modules-dell/s6100/modules/dell_ich.c
|
platform/broadcom/sonic-platform-modules-dell/s6100/modules/dell_ich.c
|
||||||
platform/broadcom/sonic-platform-modules-dell/s6100/modules/dell_s6100_lpc.c
|
platform/broadcom/sonic-platform-modules-dell/s6100/modules/dell_s6100_lpc.c
|
||||||
|
@ -1,9 +0,0 @@
|
|||||||
[Unit]
|
|
||||||
Description=Start the pcie-check.service 10 seconds after boot
|
|
||||||
|
|
||||||
[Timer]
|
|
||||||
OnBootSec=10sec
|
|
||||||
Unit=pcie-check.service
|
|
||||||
|
|
||||||
[Install]
|
|
||||||
WantedBy=timers.target
|
|
@ -506,10 +506,6 @@ sudo cp $IMAGE_CONFIGS/constants/constants.yml $FILESYSTEM_ROOT/etc/sonic/
|
|||||||
sudo cp $IMAGE_CONFIGS/sudoers/sudoers $FILESYSTEM_ROOT/etc/
|
sudo cp $IMAGE_CONFIGS/sudoers/sudoers $FILESYSTEM_ROOT/etc/
|
||||||
sudo cp $IMAGE_CONFIGS/sudoers/sudoers.lecture $FILESYSTEM_ROOT/etc/
|
sudo cp $IMAGE_CONFIGS/sudoers/sudoers.lecture $FILESYSTEM_ROOT/etc/
|
||||||
|
|
||||||
# Copy systemd timer configuration
|
|
||||||
sudo cp $BUILD_TEMPLATES/pcie-check.timer $FILESYSTEM_ROOT_USR_LIB_SYSTEMD_SYSTEM
|
|
||||||
sudo LANG=C chroot $FILESYSTEM_ROOT systemctl enable pcie-check.timer
|
|
||||||
|
|
||||||
# Copy pcie-check service files
|
# Copy pcie-check service files
|
||||||
sudo cp $IMAGE_CONFIGS/pcie-check/pcie-check.service $FILESYSTEM_ROOT_USR_LIB_SYSTEMD_SYSTEM
|
sudo cp $IMAGE_CONFIGS/pcie-check/pcie-check.service $FILESYSTEM_ROOT_USR_LIB_SYSTEMD_SYSTEM
|
||||||
echo "pcie-check.service" | sudo tee -a $GENERATED_SERVICE_FILE
|
echo "pcie-check.service" | sudo tee -a $GENERATED_SERVICE_FILE
|
||||||
|
@ -5,3 +5,6 @@ After=rc.local.service database.service
|
|||||||
[Service]
|
[Service]
|
||||||
Type=simple
|
Type=simple
|
||||||
ExecStart=/usr/bin/pcie-check.sh
|
ExecStart=/usr/bin/pcie-check.sh
|
||||||
|
|
||||||
|
[Install]
|
||||||
|
WantedBy=multi-user.target
|
||||||
|
@ -19,7 +19,7 @@ function check_and_rescan_pcie_devices()
|
|||||||
PCIE_CHK_CMD='sudo pcieutil check | grep "$RESULTS"'
|
PCIE_CHK_CMD='sudo pcieutil check | grep "$RESULTS"'
|
||||||
PLATFORM=$(sonic-cfggen -H -v DEVICE_METADATA.localhost.platform)
|
PLATFORM=$(sonic-cfggen -H -v DEVICE_METADATA.localhost.platform)
|
||||||
|
|
||||||
if [ ! -f /usr/share/sonic/device/$PLATFORM/plugins/pcie.yaml ]; then
|
if [ ! -f /usr/share/sonic/device/$PLATFORM/pcie.yaml ]; then
|
||||||
debug "pcie.yaml does not exist! Can't check PCIe status!"
|
debug "pcie.yaml does not exist! Can't check PCIe status!"
|
||||||
exit
|
exit
|
||||||
fi
|
fi
|
||||||
|
Loading…
Reference in New Issue
Block a user