diff options
| author | Brian Bakke <bbakke@us.ibm.com> | 2018-05-22 11:30:26 -0500 |
|---|---|---|
| committer | Daniel M. Crowell <dcrowell@us.ibm.com> | 2018-06-07 13:37:46 -0400 |
| commit | e364f91be1727019dd594c57d496e5ce43e8f5f0 (patch) | |
| tree | 3515d4777d5ca4705fc232b02110d6c480151eff /src/include/sys | |
| parent | 0c6d58230e615000dee1a1940bf4bc84ad5c1798 (diff) | |
| download | blackbird-hostboot-e364f91be1727019dd594c57d496e5ce43e8f5f0.tar.gz blackbird-hostboot-e364f91be1727019dd594c57d496e5ce43e8f5f0.zip | |
Fixes to node IPC messaging to handle non-zero base addresses
Current code has each Node calculate each Remote Node's IPC area
remote address by performing a fixed format calculation.
This change has each Node calculating its IPC area Remote address
and posting this value to a local SCOM register. A Node reads
a Remote Node's SCOM register to acquire the Remote IPC area
address.
Change-Id: I25260ce180e0d07e5e81990d4c1f99e249912491
RTC:191463
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/59177
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Reviewed-by: William G. Hoffa <wghoffa@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: Prachi Gupta <pragupta@us.ibm.com>
Reviewed-by: Daniel M. Crowell <dcrowell@us.ibm.com>
Diffstat (limited to 'src/include/sys')
| -rw-r--r-- | src/include/sys/internode.h | 2 | ||||
| -rw-r--r-- | src/include/sys/mmio.h | 8 | ||||
| -rw-r--r-- | src/include/sys/msg.h | 29 |
3 files changed, 36 insertions, 3 deletions
diff --git a/src/include/sys/internode.h b/src/include/sys/internode.h index 5581c1e6d..8db0252f6 100644 --- a/src/include/sys/internode.h +++ b/src/include/sys/internode.h @@ -26,7 +26,7 @@ #define __INTERNODE_H // Memory area preserved on MPIPL -#include <vmmconst.h> +#include <usr/vmmconst.h> enum internode_info_vals_t { diff --git a/src/include/sys/mmio.h b/src/include/sys/mmio.h index 71340973a..75d923e41 100644 --- a/src/include/sys/mmio.h +++ b/src/include/sys/mmio.h @@ -93,8 +93,12 @@ enum MMIO_Scratch_Register /** Identifies where hostboot currently resides and how large the * space is */ MMIO_SCRATCH_MEMORY_STATE = 0x08, - /** Spare scratch reg */ - MMIO_SCRATCH_SPARE = 0x10, + /** The address of the Local Node's ipc_data_area buffer in + * the Remote Node's radix. + * The Local Node and the Remote Node use different absolute + * 64 bit values to access the same ipc_data_area buffer. + * This register contains the value the Remote Node needs to use. */ + MMIO_SCRATCH_IPC_DATA_ADDR = 0x10, /** Identifies if Hostboot is active after host_start_payload. */ MMIO_SCRATCH_HOSTBOOT_ACTIVE = 0x18, }; diff --git a/src/include/sys/msg.h b/src/include/sys/msg.h index 2b7f2a8f4..94fda6891 100644 --- a/src/include/sys/msg.h +++ b/src/include/sys/msg.h @@ -284,6 +284,35 @@ int msg_respond(msg_q_t q, msg_t* msg); msg_t* msg_wait(msg_q_t q); +/** @fn updateRemoteIpcAddr + * @brief Update a Remote Node's IPC buffer address + * + * @param[in] i_node - node + * @param[in] i_remoteAddr - Remote Node's IPC buffer address + * + * @return Result of update. + * @retval 0 - Success + * @retval EINVAL - Invalid Node. + */ + // low nibble is remote node number +#define IPC_INVALID_REMOTE_ADDR_MASK 0xFFFFFFFFFFFFFFF0ull +#define IPC_INVALID_REMOTE_ADDR 0x00000000deadadd0ull + +int updateRemoteIpcAddr(uint64_t i_node, uint64_t i_remoteAddr); + + +/** @fn qryLocalIpcInfo + * @brief Query the local Node's node number and IPC bfr address + * + * @param[out] o_node - returned Node + * @param[out] o_addr - returned Local Node's IPC bfr address + * + * @return Result of query. + * @retval 0 - Success + */ +int qryLocalIpcInfo( uint64_t & o_node, uint64_t & o_addr); + + /** @fn msg_is_async * @brief Indicates if message is asynchronous. * |

