diff options
| author | Yue Du <daviddu@us.ibm.com> | 2017-01-22 00:02:26 -0600 |
|---|---|---|
| committer | Joshua Hunsberger <jahunsbe@us.ibm.com> | 2017-10-23 18:00:49 -0500 |
| commit | bed4c8cd7e1a9338f631426aeb3e19451b0bc641 (patch) | |
| tree | 3959e6e1e4b11bc0e9d146c2fb1f95e3463d71aa /import/chips/p9/common/pmlib/include | |
| parent | ffa811767e629eb9a53f85d6c498ab1505fa8861 (diff) | |
| download | talos-hcode-bed4c8cd7e1a9338f631426aeb3e19451b0bc641.tar.gz talos-hcode-bed4c8cd7e1a9338f631426aeb3e19451b0bc641.zip | |
STOP: block wakeup (+ block entry since patch 15)
Change-Id: I6636b7f77842e9a5e07fffa0f908fb4d46e7d763
Reviewed-on: http://ralgit01.raleigh.ibm.com/gerrit1/35205
Tested-by: Jenkins Server <pfd-jenkins+hostboot@us.ibm.com>
Tested-by: Hostboot CI <hostboot-ci+hostboot@us.ibm.com>
Reviewed-by: BRIAN D. VICTOR <brian.d.victor1@ibm.com>
Reviewed-by: Brian T. Vanderpool <vanderp@us.ibm.com>
Reviewed-by: Gregory S. Still <stillgs@us.ibm.com>
Diffstat (limited to 'import/chips/p9/common/pmlib/include')
| -rw-r--r-- | import/chips/p9/common/pmlib/include/stop_sgpe_cme_api.h | 65 | ||||
| -rw-r--r-- | import/chips/p9/common/pmlib/include/wof_sgpe_pgpe_api.h | 157 |
2 files changed, 222 insertions, 0 deletions
diff --git a/import/chips/p9/common/pmlib/include/stop_sgpe_cme_api.h b/import/chips/p9/common/pmlib/include/stop_sgpe_cme_api.h new file mode 100644 index 00000000..fb7fb201 --- /dev/null +++ b/import/chips/p9/common/pmlib/include/stop_sgpe_cme_api.h @@ -0,0 +1,65 @@ +/* IBM_PROLOG_BEGIN_TAG */ +/* This is an automatically generated prolog. */ +/* */ +/* $Source: import/chips/p9/common/pmlib/include/stop_sgpe_cme_api.h $ */ +/* */ +/* OpenPOWER HCODE Project */ +/* */ +/* COPYRIGHT 2015,2017 */ +/* [+] International Business Machines Corp. */ +/* */ +/* */ +/* Licensed under the Apache License, Version 2.0 (the "License"); */ +/* you may not use this file except in compliance with the License. */ +/* You may obtain a copy of the License at */ +/* */ +/* http://www.apache.org/licenses/LICENSE-2.0 */ +/* */ +/* Unless required by applicable law or agreed to in writing, software */ +/* distributed under the License is distributed on an "AS IS" BASIS, */ +/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */ +/* implied. See the License for the specific language governing */ +/* permissions and limitations under the License. */ +/* */ +/* IBM_PROLOG_END_TAG */ +#ifndef __STOP_SGPE_CME_API_H__ +#define __STOP_SGPE_CME_API_H__ + + +enum SGPE_STOP_IRQ_PAYLOAD_MASKS +{ + + TYPE2_PAYLOAD_SUSPEND_OP_MASK = 0x400, + TYPE2_PAYLOAD_SUSPEND_EXIT_MASK = 0x200, + TYPE2_PAYLOAD_SUSPEND_ENTRY_MASK = 0x100, + TYPE2_PAYLOAD_SUSPEND_BOTH_MASK = 0x300, + TYPE2_PAYLOAD_SUSPEND_ACK_MASK = 0x080, + + TYPE2_PAYLOAD_HARDWARE_WAKEUP = 0x800, + TYPE2_PAYLOAD_EXIT_EVENT = 0xC00, + TYPE2_PAYLOAD_STOP_LEVEL = 0x00F, + TYPE3_PAYLOAD_EXIT_EVENT = 0xC00, + TYPE6_PAYLOAD_EXIT_EVENT = 0x00F +}; + + +/// PIG TYPEs used by CME +enum CME_STOP_PIG_TYPES +{ + PIG_TYPE2 = 2, + PIG_TYPE3 = 3 +}; + +/// Numberical Doorbell Message IDs(used by CME check) +enum CME_DOORBELL_MESSAGE_IDS +{ + MSGID_DB1_UNSUSPEND_STOP_ENTRIES = 0x01, + MSGID_DB1_UNSUSPEND_STOP_EXITS = 0x02, + MSGID_DB1_UNSUSPEND_STOP_ENTRIES_EXITS = 0x03, + MSGID_DB1_WAKEUP_GRANTED = 0x04, + MSGID_DB1_SUSPEND_STOP_ENTRIES = 0x05, + MSGID_DB1_SUSPEND_STOP_EXITS = 0x06, + MSGID_DB1_SUSPEND_STOP_ENTRIES_EXITS = 0x07 +}; + +#endif /* __STOP_SGPE_CME_API_H__ */ diff --git a/import/chips/p9/common/pmlib/include/wof_sgpe_pgpe_api.h b/import/chips/p9/common/pmlib/include/wof_sgpe_pgpe_api.h new file mode 100644 index 00000000..9bd951fc --- /dev/null +++ b/import/chips/p9/common/pmlib/include/wof_sgpe_pgpe_api.h @@ -0,0 +1,157 @@ +/* IBM_PROLOG_BEGIN_TAG */ +/* This is an automatically generated prolog. */ +/* */ +/* $Source: import/chips/p9/common/pmlib/include/wof_sgpe_pgpe_api.h $ */ +/* */ +/* OpenPOWER HCODE Project */ +/* */ +/* COPYRIGHT 2016,2017 */ +/* [+] International Business Machines Corp. */ +/* */ +/* */ +/* Licensed under the Apache License, Version 2.0 (the "License"); */ +/* you may not use this file except in compliance with the License. */ +/* You may obtain a copy of the License at */ +/* */ +/* http://www.apache.org/licenses/LICENSE-2.0 */ +/* */ +/* Unless required by applicable law or agreed to in writing, software */ +/* distributed under the License is distributed on an "AS IS" BASIS, */ +/* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or */ +/* implied. See the License for the specific language governing */ +/* permissions and limitations under the License. */ +/* */ +/* IBM_PROLOG_END_TAG */ + +#ifndef __IPC_MESSAGES_H__ +#define __IPC_MESSAGES_H__ + +//--------------- +// IPC from SGPE to PGPE +//--------------- +enum MESSAGE_ID_IPI2HI_SGPE_PGPE +{ + MSGID_SGPE_PGPE_UPDATE_ACTIVE_CORES = 0x8, + MSGID_SGPE_PGPE_UPDATE_ACTIVE_QUADS = 0x9, + MSGID_SGPE_PGPE_SUSPEND_PSTATES = 0x10 +}; + +//--------------- +// IPC from PGPE to SGPE +//--------------- +enum MESSAGE_ID_IPI3HI_PGPE_SGPE +{ + MSGID_PGPE_SGPE_INVALID = 0, + MSGID_PGPE_SGPE_CONTROL_STOP_UPDATES = 1, + MSGID_PGPE_SGPE_SUSPEND_STOP = 2 +}; + +enum CTRL_STOP_UPDATES_ACTION +{ + CTRL_STOP_UPDT_RESERVED0 = 0x0, + CTRL_STOP_UPDT_ENABLE_CORE = 0x1, + CTRL_STOP_UPDT_ENABLE_QUAD = 0x2, + CTRL_STOP_UPDT_ENABLE_CORE_QUAD = 0x3, + CTRL_STOP_UPDT_RESERVED1 = 0x4, + CTRL_STOP_UPDT_DISABLE_CORE = 0x5, + CTRL_STOP_UPDT_DISABLE_QUAD = 0x6, + CTRL_STOP_UPDT_DISABLE_CORE_QUAD = 0x7 +}; + +enum UPDATE_ACTIVE_TYPES +{ + UPDATE_ACTIVE_TYPE_ENTRY = 0, + UPDATE_ACTIVE_TYPE_EXIT = 1 +}; + +enum IPC_SGPE_PGPE_RETURN_CODES +{ + IPC_SGPE_PGPE_RC_NULL = 0x00, + IPC_SGPE_PGPE_RC_SUCCESS = 0x01, + IPC_SGPE_PGPE_RC_REQ_WHILE_PENDING_ACK = 0x10, + IPC_SGPE_PGPE_RC_PM_COMPLEX_SUSPEND = 0x11 +}; + + +// Sgpe to Pgpe IPC message format + +typedef union +{ + uint64_t value; + struct + { + uint32_t msg_num : 4; + uint32_t update_type : 1; + uint32_t reserved : 3; + uint32_t return_code : 8; + uint32_t active_cores : 24; + uint32_t return_active_cores : 24; + } fields; +} ipcmsg_s2p_update_active_cores_t; + +typedef union +{ + uint64_t value; + struct + { + uint32_t msg_num : 4; + uint32_t update_type : 1; + uint32_t reserved : 3; + uint32_t return_code : 8; + uint32_t requested_quads : 6; + uint32_t reserved0 : 2; + uint32_t return_active_quads : 6; + uint32_t reserved1 : 2; + uint32_t pad : 32; + } fields; +} ipcmsg_s2p_update_active_quads_t; + +typedef union +{ + uint64_t value; + struct + { + uint32_t msg_num : 4; + uint32_t update_type : 1; + uint32_t reserved : 3; + uint32_t return_code : 8; + uint32_t requested_quads : 6; + uint32_t reserved0 : 2; + uint32_t return_active_quads : 6; + uint32_t reserved1 : 2; + uint32_t pad : 32; + } fields; +} ipcmsg_s2p_suspend_pstate_t; + + +// Pgpe to Sgpe IPC message format + +typedef union +{ + uint64_t value; + struct + { + uint32_t msg_num : 8; + uint32_t return_code : 8; + uint32_t action : 8; + uint32_t pad : 8; + uint32_t active_quads : 6; + uint32_t reserved : 2; + uint32_t active_cores : 24; + } fields; +} ipcmsg_p2s_ctrl_stop_updates_t; + +typedef union +{ + uint64_t value; + struct + { + uint32_t msg_num : 8; + uint32_t return_code : 8; + uint32_t reserved0 : 16; + uint32_t reserved1 : 32; + } fields; +} ipcmsg_p2s_suspend_stop_t; + + +#endif // __IPC_MESSAGES_H__ |

