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

[image]: load platform specific settings in sonic-to-sonic upgrade #710

Merged
merged 2 commits into from
Jun 16, 2017
Merged
Show file tree
Hide file tree
Changes from all 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
4 changes: 4 additions & 0 deletions device/dell/x86_64-dell_s6000_s1220-r0/installer.conf
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
ONIE_PLATFORM_EXTRA_CMDLINE_LINUX="processor.max_cstate=1 intel_idle.max_cstate=0"

if [ "$install_env" = "onie" ]; then

echo "Replace ONIE reboot with Dell reset commands"

# set I2C GPIO mux
Expand All @@ -21,3 +23,5 @@ i2cset -y 0 0x31 1 0xfd
EOF

chmod a+x /sbin/reboot

fi
Copy link
Contributor

Choose a reason for hiding this comment

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

add indentations to the code block?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

let's just keep this as it is.

12 changes: 10 additions & 2 deletions installer/x86_64/install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,14 @@ if [ $(id -u) -ne 0 ]
fi

# get running machine from conf file
[ -r /etc/machine.conf ] && . /etc/machine.conf
if [ -r /etc/machine.conf ]; then
. /etc/machine.conf
elif [ -r /host/machine.conf ]; then
. /host/machine.conf
else
echo "cannot find machine.conf"
exit 1
fi

echo "onie_platform: $onie_platform"

Expand All @@ -57,9 +64,10 @@ if [ -d "/etc/sonic" ]; then
else
echo "Installing SONiC in ONIE"
install_env="onie"
[ -r platforms/$onie_platform ] && source platforms/$onie_platform
fi

[ -r platforms/$onie_platform ] && . platforms/$onie_platform

# Install demo on same block device as ONIE
onie_dev=$(blkid | grep ONIE-BOOT | head -n 1 | awk '{print $1}' | sed -e 's/:.*$//')
blk_dev=$(echo $onie_dev | sed -e 's/[1-9][0-9]*$//' | sed -e 's/\([0-9]\)\(p\)/\1/')
Expand Down