summaryrefslogtreecommitdiff
path: root/meta-fii/meta-mori/recipes-mori
AgeCommit message (Collapse)AuthorFilesLines
2023-07-21meta-fii: meta-mori: Uniform syntax for recipesKyle Nieman7-111/+91
Update bitbake recipe format to make uniform with the following rules: 1) Generally bbappends should have layer(mori) overrides 2) Add uniform appending by using "append" instead of "+=" 3) bb files (excluding bbappends) typically should not have "append" phrase except for limited amount of variables (RDEPENDS,DEPENDS,FILES, ...) 4) Wrap lines greater than 80 chars when applicable 5) Switch syntax for long list values over multiple lines to use four-space indent In addition, oe-stylize.py was applied to further refine recipe syntax. Tested: Built successfully. Individual packages were tested for functionality with no notable change. Change-Id: I626c529373805aa696f7c574e10c1617493d4f61 Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com>
2023-07-01meta-fii: meta-mori: flock during flashing processJonico Eustaquio2-19/+30
Added flock during flashing process of BIOS, CPLDs, and power sequencer instead of using flock over the whole init_once script. Removed mori.sh rst hotswap to be replaced. Change-Id: I29bd364b307178abed19b542ce4737e4ef14d06d Signed-off-by: Jonico Eustaquio <jonico.eustaquio@fii-na.com>
2023-07-01meta-fii: meta-mori: Remove unused functions and variablesVincent Chou1-10/+0
Unused functions: - rst_bios_spi Unused variables: - I2C_STBUCK - I2C_HOTSWAP_CTRL Change-Id: I869825195825faaac8a9583a7b90922e0f3c26db Signed-off-by: Vincent Chou <vincent.chou@fii-na.com>
2023-07-01meta-fii: meta-mori: Update unit power behaviorKyle Nieman1-3/+2
1) Remove unwanted dependencies for the warm reboot targets. 2) Set the power policy to always on to prevent unwanted host power off. 3) Change user reset command to use ipmitool command Change-Id: Ie87296a48349219860c79f6275133595f3501e43 Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com>
2023-07-01meta-fii: meta-mori: Add BIOS accessing library functionsKyle Nieman2-17/+49
The BMC accesses the BIOS SPI during flashing, but the BMC will potentially need to access it while the host is running. Add library functions that performs a handshake to request access to it. Update current BIOS SPI access to use the functions. Also fix shellcheck error. Tested: Flashed BMC image on unit. Ensured that BIOS flash is still successful. Change-Id: Icc91802647a6967694fca3e57bbc56f2c1db9189 Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com>
2023-06-30meta-fii: meta-mori: Add setup for firmware verificationKyle Nieman3-1/+16
Firmware of an older stage board will not be allowed on a current stage board. During the flashing process, AC cycles are prevented. Overview of Changes: 1.)mori-lib.sh -Modify to add definitions that will be used for AC power cycle delay. 2.)init_once.sh -Modify to no longer use HPM_STBY_RST_N. 3.)mori-fw-ver.service -Modify to wait until fw verification process is finished to prevent failed version retrieval. Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com> Change-Id: Idd5a9613bc3e1086dd44e2579b5cb56108d430d0
2023-06-30meta-fii: meta-mori: Add installation check for firmware utilitiesKyle Nieman2-6/+20
Check that utilities used for flashing and version retrieval are installed prior to being used to prevent unintended behavior. Change-Id: I0d4547c43d78f03462e9e05ae465162cccb21f46 Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com>
2023-06-30meta-fii: meta-mori: Get BMC version from os-releaseCharles Boyer1-8/+6
This will parse the Major, sub-Major, and Minor versions from the /etc/os-release file VERSION_ID line. The version will be presented with the pattern <Major>.<sub-Major>.<Minor>. Signed-off-by: Charles Boyer <Charles.Boyer@fii-usa.com> Change-Id: I6cfebf16b840cb88216c3b8f3aeb4c295abc3e05
2023-06-30meta-fii: meta-mori: Relocate dependency on mori-bios-verifyKyle Nieman1-2/+0
Dependency on mori-bios-verify.service was set in host-powerctrl.service. Removed dependency as it should be set from mori-bios-verify.service in case of removal. Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com> Change-Id: Ibc9fec6ef8e5912ebc137e712b1ac595997dbb0a
2023-06-30meta-fii: meta-mori: Fix error checking for fw flashKyle Nieman1-18/+33
The return values for flashing cplds were incorrect when failure occurred as it was expecting a integer value, but instead received text output. To check for error, output is now searched for error messages. Tested: I flashed an incorrect version of CPLD verify and saw that flash message correctly stated failed. For bios flash, the output would hang for an excessive amount of time the flashing status. This is due to the output being stored to the variable prior to being output. Tested: I flashed the bios, and instantly saw a counter for the erase progress. Upon failing flash verification, the script output a failure message. Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com> Change-Id: Ie84418117ab4e712b4f5b5c15190044e2118a808
2023-04-27meta-fii: meta-mori: Support BMC_ALIVE led with led-managerJonico Eustaquio1-3/+0
LED_BMC_ALIVE is now managed by phosphor-led-manager instead of by init_once.sh. Asserting LED_BMC_ALIVE is removed from init_once.sh since the service obmc-led-group-start@bmc_booted.service now asserts the dbus property for LED_BMC_ALIVE's led.yaml group to be used. Signed-off-by: Jonico Eustaquio <jonico.eustaquio@fii-na.com> Change-Id: Ib68be05246a2dc66458330d99721848f86a1ed50
2023-04-27meta-fii: meta-mori: Remove hotswap-power-cycleJonico Eustaquio2-31/+0
Removes the hotswap-power-cycle recipe and service Change-Id: Iee2dcf508760f57ea5faedb40eee3d8cf48103d0 Signed-off-by: Jonico Eustaquio <jonico.eustaquio@fii-na.com>
2023-04-04meta-fii: meta-mori: Update script to retrieve BIOS versionJonico Eustaquio1-2/+3
An OpenBMC subtree update looks to have removed how dbus properties could be seen from just using busctl introspect. To get the actual value of the BIOS Version property, the script now uses busctl get-property instead. Change-Id: I3c6079026e9ea3193461fb86739892b178327fed Signed-off-by: Jonico Eustaquio <jonico.eustaquio@fii-na.com>
2023-03-29meta-fii/meta-mori: Remove entity map configurationCharles Boyer2-40/+0
Removes the entity association map that is no longer used. Signed-off-by: Charles Boyer <Charles.Boyer@fii-usa.com> Change-Id: I4cb1dffea598bd27bc1cbbf94ef94332a04af2f6
2023-03-29meta-fii: meta-mori: Rename BIOS partition to "hnor"Charles Boyer1-1/+1
The nvparm tool expects the BIOS partition to be named "hnor". Signed-off-by: Charles Boyer <Charles.Boyer@fii-usa.com> Change-Id: I472bd32b7c70a5a8189cf16fcbf430b3d1094361
2023-03-29meta-fii: meta-mori: Reset BIOS SPI before BIOS flashCharles Boyer2-1/+11
The host verification fails because the BIOS SPI is quad mode during the flash. We must reset the BIOS SPI for the host to be able to read the SPI for its verification stage. Signed-off-by: Charles Boyer <Charles.Boyer@fii-usa.com> Change-Id: I0bf38a10ca939f7fcab338fe3f654303a4dea9f9
2023-03-23meta-fii: meta-mori: Add command for controlling GPIOsKyle Nieman1-0/+24
Add command to allow user to control GPIOs using mori.sh instead of having to source mori-lib.sh and use functions. Change-Id: I3cce175a41ca13bf3e14cea49495cde561348980 Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com>
2023-03-02meta-fii: meta-mori: Fix mori-lib.sh gpio functionsKyle Nieman1-3/+30
The functions in mori-lib.sh return the wrong values for get_gpio_num and get_gpio_ctrl. get_gpio_num is not prepared to handle a device that has more than 1 gpiobank associated with it. get_gpio_ctrl is dependent on get_gpio_num to retrieve the correct identifying number for the gpio, and the path location of the gpio state differs for gpios added by some devices compared to the norm. mori-lib.sh is modify to account for these differences. Tested: I ran on real machine and checked that a gpio added by each type of device is capable of being read with get_gpio_ctrl without error. Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com> Change-Id: I212ae4f14bbb57b9643befd0aadd8ac5ef4726da
2023-03-01meta-fii: meta-mori: Add command for controlling host access to RTCKyle Nieman1-4/+39
Add command to allow user to enable or disable access for the host to the RTC. Change-Id: I0887cc18ed804191ffd80e5c6034d8ed1a0c3b66 Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com>
2022-11-09meta-fii: meta-mori: Generalize I2C bus for ADM1266Kyle Nieman2-2/+5
ADM1266 executables now take I2C bus as a command line argument instead of being hardcoded, so they can be utilized by additional projects. Overview of changes: 1.)mori-fw.sh - Modify call to ADM1266 to pass I2C bus 2.)mori.sh - Modify call to ADM1266 to pass I2C bus Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com> Change-Id: Id9d5e7d829557a30d929dad119326ac16e901c9b
2022-10-27meta-fii: meta-mori: Set up phosphor-led-managerVincent Chou3-0/+71
Summary of changes: 1. Create a yaml file to set up the action of SYSTEM BOOT STATUS LED 2. Add bb file to install yaml to phosphor led manager package 3. Add a script to control the SYSTEM BOOT STATUS LED corresponding to the OS status 4. Set up phosphor led sysfs so the physical led can be controlled 5. Set CHASSIS TARGET to none to remove unnecessary service call to obmc-led-group-start/stop@power_on/off. Signed-off-by: Vincent Chou <vincent.chou@fii-na.com> Change-Id: Ia7b136c52518a1e2af6662ffc42b4f72b3e15584
2022-09-21meta-fii: meta-mori: add phosphor console packageGrant Williams1-6/+0
Add phosphor console mori_uart_mux_ctrl script,obmc-console service files, and .conf files - Added console feature for host & mpro - Added mori_uart_mux_ctrl.sh to set gpio S0_UART0_BMC_SEL and S0_UART1_BMC_SEL allowing routing between host & mpro consoles to bmc - Added host_console_uart_configuration.service so that it runs before obmc-console. Set it to require multi-user.target, which is also required by obmc-console. Signed-off-by: Grant Williams <grant.williams@fii-na.com> Change-Id: I5d7002c20c5d1b87fa5c78e69b0885fc635c6145
2022-08-23meta-fii: meta-mori: Add I2C arrays of power regulators in mori-lib.shKyle Nieman1-0/+2
Defined I2C bus and address for ADM1272(HOTSWAP_CTRL) and PM6764(STBUCK). Added to prevent hardcoding and promote modularity. Signed-off-by: Kyle Nieman <kyle.nieman@fii-na.com> Change-Id: I6bd3e993d944e87b9242d6237850d2a4b0e30ada
2022-07-22meta-fii: meta-mori: Add Entity MapGrant Williams2-0/+40
Adding Mori Entity Association Map .bb and .json files. Signed-off-by: Grant Williams <grant.williams@fii-na.com> Change-Id: I3e090f9cc4258d0215a1af836ea8d85e7b852483
2022-07-22meta-fii: meta-mori: Add ipmi flash and firmware update servicesGrant Williams10-0/+201
Adding bios update, bmc update, cpld update, and phosphor ipmi flash packages Signed-off-by: Grant Williams <grant.williams@fii-na.com> Change-Id: I5543f520f710e065a476999991a48bdaf0544c0c
2022-07-20meta-fii: meta-mori: Add mori-boot and mori-cmdCharles Boyer5-0/+367
Summary of Changes: - Add basic mori.sh tool - Add mori-boot for host and switch initialization Signed-off-by: Charles Boyer <Charles.Boyer@fii-usa.com> Change-Id: I2cee6a2b6a15a1e2f9a53baf331fb452f73f080d
2022-07-15meta-fii: meta-mori: Add mori-fw-utility filesGrant Williams5-0/+283
Add the mori-fw file and package in packagegroup. Supports: CPLD, BIOS, and Bootstrap flashing. Signed-off-by: Grant Williams <grant.williams@fii-na.com> Change-Id: I5541af3d07c01a0602f7794c5f1b6610622e93ee
2022-06-30meta-fii: meta-mori: Adding hotswap power cycleGrant Williams2-0/+31
Adds hotswap power cycle features. Signed-off-by: Grant Williams <grant.williams@fii-na.com> Change-Id: Iadb9a312420a1fe70d5c2a31640b7cd2bda480a4