Skip to content

Commit

Permalink
[devices]: Fix error parsing to idt_int for accton as7726 (#2349)
Browse files Browse the repository at this point in the history
  • Loading branch information
jostar-yang authored and lguohan committed Dec 6, 2018
1 parent 4750a87 commit 8a4e779
Showing 1 changed file with 5 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,13 @@
if [ -s /usr/local/bin/done_idt_init ];then
echo "There is a done_idt_init file"
else

cat /etc/init.d/opennsl-modules-3.16.0-5-amd64|grep mac_handle.sh
cat /etc/init.d/opennsl-modules-4.9.0-7-amd64|grep idt_init.sh
if [ $? -ne 0 ];then
echo "Add idt_init.sh to opennsl-modules for TD3 MAC"
sed -i '/modprobe linux-kernel-bde/i sleep 1' /etc/init.d/opennsl-modules-3.16.0-5-amd64
sed -i '/sleep/i /usr/local/bin/idt_init.sh' /etc/init.d/opennsl-modules-3.16.0-5-amd64
sed -i '/idt_init/i echo "IDT init" ' /etc/init.d/opennsl-modules-3.16.0-5-amd64
sed -i '/IDT init/i echo 1 > /usr/local/bin/done_idt_init' /etc/init.d/opennsl-modules-3.16.0-5-amd64

sed -i '/modprobe linux-kernel-bde/i sleep 1' /etc/init.d/opennsl-modules-4.9.0-7-amd64
sed -i '/sleep/i /usr/local/bin/idt_init.sh' /etc/init.d/opennsl-modules-4.9.0-7-amd64
sed -i '/idt_init/i echo "IDT init" ' /etc/init.d/opennsl-modules-4.9.0-7-amd64
sed -i '/IDT init/i echo 1 > /usr/local/bin/done_idt_init' /etc/init.d/opennsl-modules-4.9.0-7-amd64
fi

fi
Expand Down

0 comments on commit 8a4e779

Please sign in to comment.