diff options
author | Samuel Jiang <Samuel.Jiang@quantatw.com> | 2019-10-18 03:56:58 +0300 |
---|---|---|
committer | Brad Bishop <bradleyb@fuzziesquirrel.com> | 2019-11-18 22:12:20 +0300 |
commit | aa2b3f294df9126d5b6044e7a6e1b64514974a16 (patch) | |
tree | 317cc3359a34d76e6f0791f66996941f3b31b065 /meta-quanta/meta-olympus-nuvoton/recipes-bsp | |
parent | 782fc3530aa3f0f0efbf2217841956c3f301767d (diff) | |
download | openbmc-aa2b3f294df9126d5b6044e7a6e1b64514974a16.tar.xz |
meta-quanta: meta-runbmc-nuvoton: rename meta-olympus-nuvoton
For avoid confusing this layer only with RUNBMC module
(https://www.opencompute.org/documents/ocp-runbmc-daughterboard-card-
design-specification-v1-4-1-pdf)
The meta-runbmc-nuvoton will rename meta-olympus-nuvoton.
That means the Quanta Olympus product with RUNBMC module which based on
Nuvoton SoC.
The layer configuration will binding Olympus product hardware design.
(From meta-quanta rev: f4a8e7ae48dc788fa7e52f024578c67f164c8620)
Change-Id: I6faa1bfbb3b8f033239fea3c41e8b8ed18fc492d
Signed-off-by: Samuel Jiang <Samuel.Jiang@quantatw.com>
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
Diffstat (limited to 'meta-quanta/meta-olympus-nuvoton/recipes-bsp')
5 files changed, 400 insertions, 0 deletions
diff --git a/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/files/BootBlockAndHeader_olympus.xml b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/files/BootBlockAndHeader_olympus.xml new file mode 100644 index 000000000..58723e60e --- /dev/null +++ b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/files/BootBlockAndHeader_olympus.xml @@ -0,0 +1,166 @@ +<!-- SPDX-License-Identifier: GPL-2.0 +# +# Nuvoton IGPS: Image Generation And Programming Scripts For Poleg BMC +# +# Copyright (C) 2018 Nuvoton Technologies, All Rights Reserved +#---------------------------------------------------------------------------> + +<?xml version="1.0" encoding="UTF-8"?> + +<Bin_Ecc_Map> + <!-- BMC mandatory fields --> + <ImageProperties> + <BinSize>0</BinSize> <!-- If 0 the binary size will be calculated by the tool --> + <PadValue>0xFF</PadValue> <!-- Byte value to pad the empty areas, default is 0 --> + </ImageProperties> + + <BinField> + <!-- BootBlock tag (0x50 0x07 0x55 0xAA 0x54 0x4F 0x4F 0x42) or + uboot tag (0x55 0x42 0x4F 0x4F 0x54 0x42 0x4C 0x4B) --> + <name>StartTag</name> <!-- name of field --> + <config> + <offset>0</offset> <!-- offset in the header --> + <size>0x8</size> <!-- size in the header --> + </config> + <content format='bytes'>0x50 0x07 0x55 0xAA 0x54 0x4F 0x4F 0x42</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Code destination address, 32-bit aligned: for BootBlock should be 0xFFFD5E00 so code will run in 0xFFFD6000 as linked for --> + <name>DestAddr</name> <!-- name of field --> + <config> + <offset>0x140</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0xFFFD5E00</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- BootBlock or u-boot Code size --> + <name>CodeSize</name> <!-- name of field --> + <config> + <offset>0x144</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='FileSize'>Poleg_bootblock.bin</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- The BootBlock or u-boot binary file --> + <name>Code</name> <!-- name of field --> + <config> + <offset>0x200</offset> <!-- offset in the header --> + <size format='FileSize'>Poleg_bootblock.bin</size> <!-- size in the header calculated by tool--> + </config> + <content format='FileContent'>Poleg_bootblock.bin</content> <!-- content the user should fill --> + </BinField> + + <!-- BMC optional fields --> + <BinField> + <!-- Word contents copied by ROM code to FIU0 FIU_DRD_CFG register --> + <name>FIU0_DRD_CFG_Set</name> <!-- name of field --> + <config> + <offset>0x108</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0x030011BB</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines the clock divide ratio from AHB to FIU0 clock --> + <name>FIU_Clk_Divider</name> <!-- name of field --> + <config> + <offset>0x10C</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>4</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Version (Major.Minor) --> + <name>Version</name> <!-- name of field --> + <config> + <offset>0x148</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0x0201</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Board manufaturer ( Dell = 0, Nuvoton = 100, Google = 1, MS = 2) --> + <name>BOARD_VENDOR</name> <!-- name of field --> + <config> + <offset>0x124</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>100</content> <!--Board_manufacturer: Nuvoton--> + </BinField> + <BinField> + <!-- Board type ( DRB = 0, SVB = 1, EB = 2,HORIZON = 3, SANDSTORM = 4, ROCKAWAY = 100 RunBMC = 10) --> + <!-- WARNING: Currently this value is only printed to serial. Set BOARD_VENDOR to 1 get Dell specific customization. --> + <name>BOARD_TYPE</name> <!-- name of field --> + <config> + <offset>0x120</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0x0A</content> <!--Board_type: SVB--> + </BinField> + + <!-- the next two fields are available since version 10.7.0 --> + <BinField> + <!-- supported values: 333,444,500,600,666,700,720,750,775,787,800,825,850,900,950,1000,1060 --> + <name>MC_FREQ_IN_MHZ</name> <!-- name of field --> + <config> + <offset>0x128</offset> <!-- offset in the header --> + <size>0x2</size> <!-- size in the header --> + </config> + <content format='32bit'>800</content> + </BinField> + <BinField> + <!-- supporeted values: 333,500,600,666,700,720,750,800,825,850,900,950,1000,1060 --> + <name>CPU_FREQ_IN_MHZ</name> <!-- name of field --> + <config> + <offset>0x12A</offset> <!-- offset in the header --> + <size>0x2</size> <!-- size in the header --> + </config> + <content format='32bit'>800</content> + </BinField> + + <BinField> + <!-- MC_CONFIG. + Bit 0: MC_DISABLE_CAPABILITY_INPUT_DQS_ENHANCE_TRAINING (0x01) + Bit 1: MC_CAPABILITY_IGNORE_ECC_DEVICE (0x02) --> + <name>MC_CONFIG</name> <!-- name of field --> + <config> + <offset>0x12C</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='32bit'>0x01</content> + </BinField> + + <BinField> + <!-- HOST_IF. + 0xFF: LPC backward compatible + 0x00: LPC. + 0x01: eSPI + 0x02: GPIOs TRIS. --> + <name>HOST_IF</name> <!-- name of field --> + <config> + <offset>0x12D</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='32bit'>0x00</content> + </BinField> + + <!-- reserved fields --> + <BinField> + <!-- reserved field for sample --> + <name>My_reserved</name> <!-- name of field --> + <config> + <offset>0x110</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='bytes'>0xFF 0xFF 0xFF 0xFF</content> <!-- content the user should fill --> + </BinField> + +</Bin_Ecc_Map> diff --git a/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/files/UbootHeader_olympus.xml b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/files/UbootHeader_olympus.xml new file mode 100644 index 000000000..1612a8368 --- /dev/null +++ b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/files/UbootHeader_olympus.xml @@ -0,0 +1,191 @@ +<!-- SPDX-License-Identifier: GPL-2.0 +# +# Nuvoton IGPS: Image Generation And Programming Scripts For Poleg BMC +# +# Copyright (C) 2018 Nuvoton Technologies, All Rights Reserved +#---------------------------------------------------------------------------> + +<?xml version="1.0" encoding="UTF-8"?> + +<Bin_Ecc_Map> + <!-- BMC mandatory fields --> + <ImageProperties> + <BinSize>0</BinSize> <!-- If 0 the binary size will be calculated by the tool --> + <PadValue>0xFF</PadValue> <!-- Byte value to pad the empty areas, default is 0 --> + </ImageProperties> + + <BinField> + <!-- BootBlock tag (0x50 0x07 0x55 0xAA 0x54 0x4F 0x4F 0x42) or + uboot tag (0x55 0x42 0x4F 0x4F 0x54 0x42 0x4C 0x4B) --> + <name>StartTag</name> <!-- name of field --> + <config> + <offset>0</offset> <!-- offset in the header --> + <size>0x8</size> <!-- size in the header --> + </config> + <content format='bytes'>0x55 0x42 0x4F 0x4F 0x54 0x42 0x4C 0x4B</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Code destination address, 32-bit aligned: for u-boot should be 0x80005000 so code will run in 0x80005200 as linked for --> + <name>DestAddr</name> <!-- name of field --> + <config> + <offset>0x140</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0x8000</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- BootBlock or u-boot Code size --> + <name>CodeSize</name> <!-- name of field --> + <config> + <offset>0x144</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='FileSize'>u-boot.bin</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- The BootBlock or u-boot binary file --> + <name>Code</name> <!-- name of field --> + <config> + <offset>0x200</offset> <!-- offset in the header --> + <size format='FileSize'>u-boot.bin</size> <!-- size in the header calculated by tool--> + </config> + <content format='FileContent'>u-boot.bin</content> <!-- content the user should fill --> + </BinField> + + <!-- BMC optional fields --> + <BinField> + <!-- Word contents copied by ROM code to FIU0 FIU_DRD_CFG register --> + <name>FIU0_DRD_CFG_Set</name> <!-- name of field --> + <config> + <offset>0x108</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0x030111BC</content> <!-- content the user should fill 0x030032EB --> + </BinField> + + <BinField> + <!-- Defines the clock divide ratio from AHB to FIU0 clock --> + <name>FIU0_Clk_Divider</name> <!-- name of field --> + <config> + <offset>0x10C</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines if FIU0 CS1 is enabled --> + <name>fiu0_cs1_en</name> <!-- name of field --> + <config> + <offset>0x10D</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0x0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines if FIU0 CS2 is enabled --> + <name>fiu0_cs2_en</name> <!-- name of field --> + <config> + <offset>0x10E</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0x0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines if FIU0 CS3 is enabled --> + <name>fiu0_cs3_en</name> <!-- name of field --> + <config> + <offset>0x10F</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0x0</content> <!-- content the user should fill --> + </BinField> + + <!-- BMC optional fields --> + <BinField> + <!-- Word contents copied by ROM code to FIU3 FIU_DRD_CFG register --> + <name>FIU3_DRD_CFG_Set</name> <!-- name of field --> + <config> + <offset>0x110</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0x030011BB</content> <!-- content the user should fill --> + </BinField> + + <!-- BMC optional fields --> + <BinField> + <!-- Word contents copied by ROM code to FIU3 FIU_DRD_CFG register --> + <name>FIU3_DWR_CFG_Set</name> <!-- name of field --> + <config> + <offset>0x114</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0x0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines the clock divide ratio from AHB to FIU3 clock --> + <name>FIU3_Clk_Divider</name> <!-- name of field --> + <config> + <offset>0x118</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0x0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines if FIU3 CS0 is enabled --> + <name>fiu3_cs0_en</name> <!-- name of field --> + <config> + <offset>0x119</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0x0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines if FIU3 CS1 is enabled --> + <name>fiu3_cs1_en</name> <!-- name of field --> + <config> + <offset>0x11A</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0x0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines if FIU3 CS2 is enabled --> + <name>fiu3_cs2_en</name> <!-- name of field --> + <config> + <offset>0x11B</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0x0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Defines if FIU3 CS3 is enabled --> + <name>fiu3_cs3_en</name> <!-- name of field --> + <config> + <offset>0x11C</offset> <!-- offset in the header --> + <size>0x1</size> <!-- size in the header --> + </config> + <content format='bytes'>0x0</content> <!-- content the user should fill --> + </BinField> + + <BinField> + <!-- Version (Major.Minor) --> + <name>Version</name> <!-- name of field --> + <config> + <offset>0x148</offset> <!-- offset in the header --> + <size>0x4</size> <!-- size in the header --> + </config> + <content format='32bit'>0x0201</content> <!-- content the user should fill --> + </BinField> + +</Bin_Ecc_Map> diff --git a/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/npcm7xx-bingo-native_%.bbappend b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/npcm7xx-bingo-native_%.bbappend new file mode 100644 index 000000000..4de20b2da --- /dev/null +++ b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/images/npcm7xx-bingo-native_%.bbappend @@ -0,0 +1,12 @@ +FILESEXTRAPATHS_prepend := "${THISDIR}/files:" +SRC_URI_remove = "file://BootBlockAndHeader_EB.xml" +SRC_URI_remove = "file://UbootHeader_EB.xml" +SRC_URI_append += " file://BootBlockAndHeader_olympus.xml" +SRC_URI_append += " file://UbootHeader_olympus.xml" + + +do_install_append() { + install ${WORKDIR}/BootBlockAndHeader_olympus.xml ${D}${bindir}/BootBlockAndHeader_EB.xml + install ${WORKDIR}/UbootHeader_olympus.xml ${D}${bindir}/UbootHeader_EB.xml +} + diff --git a/meta-quanta/meta-olympus-nuvoton/recipes-bsp/u-boot/u-boot-fw-utils-nuvoton/fw_env.config b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/u-boot/u-boot-fw-utils-nuvoton/fw_env.config new file mode 100644 index 000000000..0c384273f --- /dev/null +++ b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/u-boot/u-boot-fw-utils-nuvoton/fw_env.config @@ -0,0 +1,24 @@ +# Configuration file for fw_(printenv/setenv) utility. +# Up to two entries are valid, in this case the redundant +# environment sector is assumed present. +# Notice, that the "Number of sectors" is not required on NOR and SPI-dataflash. +# Futhermore, if the Flash sector size is ommitted, this value is assumed to +# be the same as the Environment size, which is valid for NOR and SPI-dataflash + +# NOR example +# MTD device name Device offset Env. size Flash sector size Number of sectors +/dev/mtd2 0x0000 0x40000 0x4000 + +# MTD SPI-dataflash example +# MTD device name Device offset Env. size Flash sector size Number of sectors +#/dev/mtd5 0x4200 0x4200 +#/dev/mtd6 0x4200 0x4200 + +# NAND example +#/dev/mtd0 0x4000 0x4000 0x20000 2 + +# Block device example +#/dev/mmcblk0 0xc0000 0x20000 + +# VFAT example +#/boot/uboot.env 0x0000 0x4000 diff --git a/meta-quanta/meta-olympus-nuvoton/recipes-bsp/u-boot/u-boot-fw-utils-nuvoton_%.bbappend b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/u-boot/u-boot-fw-utils-nuvoton_%.bbappend new file mode 100644 index 000000000..91518decf --- /dev/null +++ b/meta-quanta/meta-olympus-nuvoton/recipes-bsp/u-boot/u-boot-fw-utils-nuvoton_%.bbappend @@ -0,0 +1,7 @@ +FILESEXTRAPATHS_prepend := "${THISDIR}/${PN}:" + +SRC_URI += "file://fw_env.config" + +do_install_append () { + install -m 644 ${WORKDIR}/fw_env.config ${D}${sysconfdir}/fw_env.config +} |