[centec][arm64] support multi-platform device tree (#12846)
Why I did it support multi-platform device tree for default dtb may not suitable on all vender hardware designs. How I did it use onie_platform variable to load device tree blob
This commit is contained in:
parent
cb354a5af2
commit
c154b68b61
@ -19,7 +19,7 @@ bootloader_menu_config() {
|
||||
fw_setenv -f linuxargs "${extra_cmdline_linux}"
|
||||
fw_setenv -f nos_bootcmd "test -n \$boot_once && setenv do_boot_once \$boot_once && setenv boot_once && saveenv && run do_boot_once; run boot_next"
|
||||
|
||||
fw_setenv -f sonic_image_1 "ext4load mmc 0:1 \$loadaddr \$sonic_dir_1/boot/sonic_arm64.fit && setenv bootargs quiet console=\$consoledev,\$baudrate root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 loopfstype=squashfs loop=\$sonic_dir_1/fs.squashfs systemd.unified_cgroup_hierarchy=0 \${linuxargs} && bootm \$loadaddr"
|
||||
fw_setenv -f sonic_image_1 "ext4load mmc 0:1 \$loadaddr \$sonic_dir_1/boot/sonic_arm64.fit && setenv bootargs quiet console=\$consoledev,\$baudrate root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 loopfstype=squashfs loop=\$sonic_dir_1/fs.squashfs systemd.unified_cgroup_hierarchy=0 \${linuxargs} && bootm \$loadaddr#\$onie_platform"
|
||||
fw_setenv -f sonic_image_2 "NONE"
|
||||
fw_setenv -f sonic_dir_1 $image_dir
|
||||
fw_setenv -f sonic_dir_2 "NONE"
|
||||
@ -41,7 +41,7 @@ bootloader_menu_config() {
|
||||
fw_setenv linuxargs "${extra_cmdline_linux}"
|
||||
fw_setenv nos_bootcmd "test -n \$boot_once && setenv do_boot_once \$boot_once && setenv boot_once && saveenv && run do_boot_once; run boot_next"
|
||||
|
||||
fw_setenv sonic_image_$idx "ext4load mmc 0:1 \$loadaddr \$sonic_dir_$idx/boot/sonic_arm64.fit && setenv bootargs quiet console=\$consoledev,\$baudrate root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 loopfstype=squashfs loop=\$sonic_dir_$idx/fs.squashfs systemd.unified_cgroup_hierarchy=0 \${linuxargs} && bootm \$loadaddr"
|
||||
fw_setenv sonic_image_$idx "ext4load mmc 0:1 \$loadaddr \$sonic_dir_$idx/boot/sonic_arm64.fit && setenv bootargs quiet console=\$consoledev,\$baudrate root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4 loopfstype=squashfs loop=\$sonic_dir_$idx/fs.squashfs systemd.unified_cgroup_hierarchy=0 \${linuxargs} && bootm \$loadaddr#\$onie_platform"
|
||||
fw_setenv sonic_dir_$idx $image_dir
|
||||
fw_setenv sonic_version_$idx `echo $image_dir | sed "s/^image-/SONiC-OS-/g"`
|
||||
|
||||
|
@ -50,13 +50,34 @@
|
||||
};
|
||||
};
|
||||
configurations {
|
||||
default = "e530-ctc5236";
|
||||
default = "arm64-centec_e530_24x2c-r0";
|
||||
|
||||
e530-ctc5236 {
|
||||
description = "config for tm_ctc5236";
|
||||
kernel = "kernel_ctc";
|
||||
ramdisk = "initramfs";
|
||||
fdt = "ctc_fdt";
|
||||
arm64-centec_e530_24x2c-r0 {
|
||||
description = "config for arm64-centec_e530_24x2c-r0";
|
||||
kernel = "kernel_ctc";
|
||||
ramdisk = "initramfs";
|
||||
fdt = "ctc_fdt";
|
||||
};
|
||||
|
||||
arm64-centec_e530_24x2q-r0 {
|
||||
description = "config for arm64-centec_e530_24x2q-r0";
|
||||
kernel = "kernel_ctc";
|
||||
ramdisk = "initramfs";
|
||||
fdt = "ctc_fdt";
|
||||
};
|
||||
|
||||
arm64-centec_e530_48s4x-r0 {
|
||||
description = "config for arm64-centec_e530_48s4x-r0";
|
||||
kernel = "kernel_ctc";
|
||||
ramdisk = "initramfs";
|
||||
fdt = "ctc_fdt";
|
||||
};
|
||||
|
||||
arm64-centec_e530_48t4x_p-r0 {
|
||||
description = "config for arm64-centec_e530_48t4x_p-r0";
|
||||
kernel = "kernel_ctc";
|
||||
ramdisk = "initramfs";
|
||||
fdt = "ctc_fdt";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user