From f4f47d5e09c0465ae2c92fc81a1f99a8df51d58a Mon Sep 17 00:00:00 2001 From: "simon.ji" Date: Fri, 16 Mar 2018 03:13:51 -0700 Subject: [PATCH 1/2] add fast-reboot support for nephos platform by stop kernel modules --- scripts/fast-reboot | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/scripts/fast-reboot b/scripts/fast-reboot index d16af72fd4..fc908106f9 100755 --- a/scripts/fast-reboot +++ b/scripts/fast-reboot @@ -63,6 +63,12 @@ then systemctl stop "$service_name" fi +# Stop kernel modules for Nephos platform +if [ "$sonic_asic_type" = 'nephos' ]; +then + systemctl stop nps-modules-`uname -r`.service +fi + # Wait until all buffers synced with disk sync sleep 1 From ea21c77a4b3a7bdc371b8708433f2e5511b73374 Mon Sep 17 00:00:00 2001 From: "simon.ji" Date: Sun, 18 Mar 2018 22:23:52 -0700 Subject: [PATCH 2/2] use [[ ]] instead of [ ] --- scripts/fast-reboot | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/fast-reboot b/scripts/fast-reboot index fc908106f9..ab37cc4966 100755 --- a/scripts/fast-reboot +++ b/scripts/fast-reboot @@ -64,7 +64,7 @@ then fi # Stop kernel modules for Nephos platform -if [ "$sonic_asic_type" = 'nephos' ]; +if [[ "$sonic_asic_type" = 'nephos' ]]; then systemctl stop nps-modules-`uname -r`.service fi