summaryrefslogtreecommitdiffstats
path: root/src/runtime
Commit message (Collapse)AuthorAgeFilesLines
* Always send NV_STATUS to Opal when opal-prd startsCorey Swenson2019-12-121-1/+6
| | | | | | | | | | | | | | | Opal does not persist NVDIMM status state so HBRT must send this info to Opal when opal-prd starts. Change-Id: I0771c63ff2857f9b70fbfad5760267e3da463009 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/87541 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Roland Veloz <rveloz@us.ibm.com> Reviewed-by: Matt Derksen <mderkse1@us.ibm.com> Reviewed-by: Daniel M Crowell <dcrowell@us.ibm.com>
* Developer Improvement: Get code coverage tool working with HostbootZach Clark2019-05-131-1/+7
| | | | | | | | | | | | | | | This commit fixes GCOV code coverage for P9 with GCC 4.9.2 Change-Id: Ie1e7c35f67414531dbd6e7a771ac1529a9ebd59d RTC: 208351 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/76812 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Reviewed-by: Nicholas E. Bofferding <bofferdn@us.ibm.com> Reviewed-by: Ilya Smirnov <ismirno@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Fix bug that was scrambling traces in errorlogs during HBRTChristian Geddes2019-03-261-0/+12
| | | | | | | | | | | | | | | | | | | | | There was a bug in how HB was interpreting the clock time that PHYP returned in response to a get_clocktime request. The nsec member of the struct returned was getting the first 32bits filled in and Hostboot was expecting the value to be in the last 32bits. This change will shift the nsec value down 4 bytes if we find the back half of the nsec value to be all 0's. I believe the reason the wrong bits were filled in is because PHYP is returning a packed struct whose 2nd member is a 32 bit value so it does not get filled in correctly. Change-Id: I71f1c2cb672b9979e0b6bdc8b1852544f230b885 CQ: SW448397 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/74823 Reviewed-by: Matt Derksen <mderkse1@us.ibm.com> Reviewed-by: Corey V. Swenson <cswenson@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Support thread local storageJaymes Wilks2019-03-111-1/+34
| | | | | | | | | | | | | | | | | | | | | | | Generally adds support to declare variables as thread_local - Add support in HBRT start assembly to skip adjusting TLS relocations - Add support in linker to generate tagged TLS entries - Update linker to process TLS relocations correctly - Update TLS code to ignore top half of module ID - Update module images to hold a "module ID" - Update custome linker to update module ID during binary link - Update TLS code to track TLS sections via module ID Change-Id: I1589550d7787beb08827ca24a728397dedf0373b RTC: 147599 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/71709 Reviewed-by: Ilya Smirnov <ismirno@us.ibm.com> Reviewed-by: Michael Baiocchi <mbaiocch@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Attribute support for recursive mutexesMatt Raybuck2018-11-121-1/+7
| | | | | | | | | | | | | | | | Added a new recursive mutex attribute, new test cases, and initializers for recursive mutex attributes. Change-Id: I49e6bc4fc2fd84e5c46e5d4c5ec125270347bde5 RTC: 196793 Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/67939 Reviewed-by: Nicholas E. Bofferding <bofferdn@us.ibm.com> Reviewed-by: Ilya Smirnov <ismirno@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* assert: Include file name in assert outputAndrew Jeffery2018-10-021-4/+7
| | | | | | | | | | | | | | | Printing the line number without an associated file is almost meaningless; add the file name to improve debug ergonomics. Change-Id: I454876ccc567cb58066362caced7efbaf92cfe62 Signed-off-by: Andrew Jeffery <andrewrj@au1.ibm.com> Reviewed-on: http://rchgit01.rchland.ibm.com/gerrit1/66117 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Corey V. Swenson <cswenson@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* HBRT Reserved Mem Trace Buffer implementation.Sakethan R Kotta2018-06-191-1/+14
| | | | | | | | | | | | | | | | | | | | | | -Hostboot master Drawer will create TRACEBUF section in the HB Rsvd Mem and HBRT, while booting, gets the TRACEBUF section details and initializes the circual buffer, if available. -If a valid data is present in the buffer, HBRT will create an info log ERRL, otherwise initializes the buffer. -Traces from all components are serialized and stored in the single TRACEBUF in the same format (fsp-binary Trace). When buffer is full, it deletes the oldest entry/entries to store the new ones. -ERRL->collectTrace() works similar to other buffers. -A new test case is added to dump the traces from TRACEBUF. Change-Id: I4ce943231a2ba30e3a13ca34d1c40ff68464a994 RTC:188726 RTC:191302 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/56450 Reviewed-by: Prachi Gupta <pragupta@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Tested-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Check for pending OCC messages on HBRT start in OpenPOWERBrian Bakke2018-04-171-0/+11
| | | | | | | | | | | | | | | | | | | The OCC will set an interrupt for the Host to look for a pending message/action. If opal-prd is not running at the time that this interrupt happens, HTMGT will never see the message. Therefore we need to have HTMGT explicitly check for anything pending any time HBRT starts up. Change-Id: Iaae075ae6828a9de5a7bd5afe55c541b0076f2d2 RTC: 187912 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/57175 Reviewed-by: Christopher J. Cain <cjcain@us.ibm.com> Reviewed-by: Matt Derksen <mderkse1@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Initialize FIRDATA section and ErrlManager just incase BMC resetsMatt Derksen2018-03-071-0/+7
| | | | | | | | | | | | | | | | | | | PRD needs to read the PNOR to tell OCC where to write in the pnor. This will cache the PNOR section so PRD will not fail the read call. If an error is created with pnor inaccessible, errl manager could get stuck unless it was initialized first. Change-Id: Ia7212bf99e947a1016423b37aff6f13ddfc7190a CQ:SW412798 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/54990 Reviewed-by: Martin Gloff <mgloff@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Reviewed-by: Roland Veloz <rveloz@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> CI-Ready: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Initialize SBE message communication on HBRT startMatt Derksen2018-02-071-1/+4
| | | | | | | | | | | | | | | | | | | Need to clear first 2 bits in CFAM register 0x283B. This basically resets our SBE communication stream just incase HBRT restarts after processing SBE interrupt. Clearing these bits tells the sender to resend the command. Change-Id: I1a1c5b80cc99414649d38c06b93428c87299f242 RTC:186334 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/53225 Reviewed-by: Martin Gloff <mgloff@us.ibm.com> Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Reviewed-by: Brian E. Bakke <bbakke@us.ibm.com> Reviewed-by: Roland Veloz <rveloz@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Create runtime_utils so both IPL and runtime can use common functionsStephen Cprek2017-11-191-1/+5
| | | | | | | | | | | | | | Change-Id: I130f87acdcb841640de7768f1c0abe38e45ce677 RTC: 180063 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/49754 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP Build CI <op-jenkins+hostboot@us.ibm.com> Tested-by: Jenkins OP HW <op-hw-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Nicholas E. Bofferding <bofferdn@us.ibm.com> Reviewed-by: Marshall J. Wilks <mjwilks@us.ibm.com> Reviewed-by: Michael Baiocchi <mbaiocch@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Convert cmpi to cmpwi to fix build for modern binutilsJoel Stanley2017-06-261-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | From Linux 80f23935cadb ("powerpc: Convert cmp to cmpd in idle enter sequence"): PowerPC's "cmp" instruction has four operands. Normally people write "cmpw" or "cmpd" for the second cmp operand 0 or 1. But, frequently people forget, and write "cmp" with just three operands. With older binutils this is silently accepted as if this was "cmpw", while often "cmpd" is wanted. With newer binutils GAS will complain about this for 64-bit code. For 32-bit code it still silently assumes "cmpw" is what is meant. In this instance the code comes directly from ISA v2.07, including the cmp, but cmpd is correct. Backport to stable so that new toolchains can build old kernels. This is change is a noop with the existing toolchain. We change from implicitly generating the cmpwi to explicitly stating in for compatibility with newer toolchains. With gcc 4.9.3, binutils 2.25.2: $ cat asm-test.S .text .global test cmpi 0, 8, 1 $ powerpc64-linux-gcc -c asm-test.S $ objdump -d asm-test.o 0000000000000000 <.text>: 2c 08 00 01 cmpwi r8,1 Old compiler, updated instruction: $ cat asm-test.S .text .global test cmpwi 0, 8, 1 $ powerpc64-linux-gcc -c asm-test.S $ objdump -d asm-test.o 0000000000000000 <.text>: 2c 08 00 01 cmpwi r8,1 And then the new toolchain (gcc 6.3.0, binutils 2.28) with the updated asm: $ cat asm-test.S .text .global test cmpwi 0, 8, 1 $ powerpc64-linux-gnu-gcc -c asm-test.S $ objdump -d asm-test.o 0000000000000000 <.text>: 2c 08 00 01 cmpwi r8,1 Change-Id: If981e20a578ec98ede68a31eee2888c27d5c3d10 Signed-off-by: Joel Stanley <joel@jms.id.au> Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/42259 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: STEWART E. SMITH <stewart@linux.vnet.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Updates to HBRT runtime interfacesDan Crowell2017-06-081-1/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reconciling P9 function table with P8 table to make opal-prd work. Added new entries for: - firmware_request - get_ipoll_events - firmware_notify Added in entries for P8 functions: - get_interface_capabilities Added deprecated placeholders for P8 functions: - occ_load - occ_start - occ_stop Moved entries for: - load_pm_complex - start_pm_complex - reset_pm_complex Change-Id: I1892b4465a6e5901aa9eaa6a49e139a4bc4c5b56 CMVC-Prereq: 1026011 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/40467 Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com> Tested-by: FSP CI Jenkins <fsp-CI-jenkins+hostboot@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Removed temp workaround to load ATTR_TMPZane Shelley2016-05-191-6/+1
| | | | | | | | | | | | Change-Id: Ibac4cb5a4d742b8c7e2e57265ee0af29a9a53415 RTC: 134050 Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/24341 Tested-by: Jenkins Server Tested-by: FSP CI Jenkins Reviewed-by: Matthew A. Ploetz <maploetz@us.ibm.com> Reviewed-by: William G. Hoffa <wghoffa@us.ibm.com> Reviewed-by: William H. Schwartz <whs@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
* Propagate ATTR_TMP overrides into HBRTBill Schwartz2015-08-251-1/+18
| | | | | | | | | | Load ATTR_TMP overrides at host boot runtime RTC: 129055 Change-Id: Id01889b6a1498af05732cee7c797d3e18af10f8d Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/19951 Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com> Tested-by: Jenkins Server
* clock_gettime support for HBRTPrachi Gupta2014-12-151-0/+9
| | | | | | | | | Change-Id: Iab8d113c00609d7b92fb2fd943b57c9a21671f11 RTC: 119002 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/14668 Tested-by: Jenkins Server Reviewed-by: STEPHEN M. CPREK <smcprek@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Add nanosleep to hbrt.Patrick Williams2014-11-062-1/+39
| | | | | | | | | | | Change-Id: Ia89c6839ed9b0e184516aeffcf873fd7baaec9a5 RTC: 118022 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/14381 Tested-by: Jenkins Server Reviewed-by: Christopher Cain <cjcain@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Change copyright prolog for all files to Apache.Patrick Williams2014-05-219-94/+94
| | | | | | | Change-Id: I5664587b4f889099290ef50d50fa9ce5e580e1eb Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/11167 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Update makefiles & included .mk files to use += convention.Brian Silver2014-05-211-3/+9
| | | | | | | | Change-Id: I4148bc4c770b7c3c10fe25aa18d57d1a4301e5a9 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/11194 Tested-by: Jenkins Server Reviewed-by: Christopher T. Phan <cphan@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* HBRT: Defer indirect scoms to Sapphire.Patrick Williams2014-02-111-7/+1
| | | | | | | | | Change-Id: I252016d0bfe3fea15deba5968d0d8a6ff044cb22 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/8213 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* HBRT: Add version to interface struct.Patrick Williams2014-02-063-6/+25
| | | | | | | | | Change-Id: Ifd02f285b97f6177e3ff8ed8d62f47fada28ab8b Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/8144 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* IBSCOM Enablement and Error HandlingDan Crowell2013-12-121-0/+6
| | | | | | | | | | | | | | | | | Enable IBSCOM for Centaur DD2.x chips Add appropriate error handling Flip scom to FSI after IBSCOM fail Enable reconfig loop cleanup Code verified on hardware Change-Id: I394789b900e5779dded78dd5fbcc9b9257e856fb RTC: 69115 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/7410 Tested-by: Jenkins Server Reviewed-by: Michael Baiocchi <baiocchi@us.ibm.com> Reviewed-by: ADAM R. MUHLE <armuhle@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* hbirt increase number of modules allowedDoug Gilbert2013-11-131-1/+2
| | | | | | | | Change-Id: I64a05ac460d75a8328a326d808e906dc0751a8d8 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/7166 Tested-by: Jenkins Server Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Runtime LidMgr.Patrick Williams2013-11-073-23/+26
| | | | | | | | | | Change-Id: Ib456f3a41d79775a2af027e0bf80e36ce1d49232 RTC: 76679 Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/6971 Tested-by: Jenkins Server Reviewed-by: Douglas R. Gilbert <dgilbert@us.ibm.com> Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com> Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
* Initial Hostboot Runtime image support.Patrick Williams2013-09-178-0/+514
RTC: 76675 Change-Id: Ibd21cf5b555e6dcee182a2f1a292b47d4f384ba0 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/6127 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
OpenPOWER on IntegriCloud