diff options
author | Chris Cain <cjcain@us.ibm.com> | 2015-11-19 12:27:03 -0600 |
---|---|---|
committer | William A. Bryan <wilbryan@us.ibm.com> | 2016-01-27 16:27:07 -0600 |
commit | 1cdc7f74cf7303b2d2e7e172b0e269928def09de (patch) | |
tree | bc88add88943f8389626a04c5219d0efc3d08f17 /src/occ_405/dimm/dimm.h | |
parent | 476a284b52f50c1d0f5a8fc637cc28a22c714185 (diff) | |
download | talos-occ-1cdc7f74cf7303b2d2e7e172b0e269928def09de.tar.gz talos-occ-1cdc7f74cf7303b2d2e7e172b0e269928def09de.zip |
Implement code to read DIMM temperatures
Change-Id: I98fc83ab1c78bd40241fe6e47a9ddeae24f78c38
RTC: 140093
Reviewed-on: http://gfw160.aus.stglabs.ibm.com:8080/gerrit/22770
Reviewed-by: William A. Bryan <wilbryan@us.ibm.com>
Tested-by: FSP CI Jenkins
Reviewed-by: Martha Broyles <mbroyles@us.ibm.com>
Reviewed-by: Christopher Cain <cjcain@us.ibm.com>
Diffstat (limited to 'src/occ_405/dimm/dimm.h')
-rw-r--r-- | src/occ_405/dimm/dimm.h | 69 |
1 files changed, 69 insertions, 0 deletions
diff --git a/src/occ_405/dimm/dimm.h b/src/occ_405/dimm/dimm.h new file mode 100644 index 0000000..cfbb898 --- /dev/null +++ b/src/occ_405/dimm/dimm.h @@ -0,0 +1,69 @@ +/* IBM_PROLOG_BEGIN_TAG */ +/* This is an automatically generated prolog. */ +/* */ +/* $Source: src/occ_405/dimm/dimm.h $ */ +/* */ +/* OpenPOWER OnChipController Project */ +/* */ +/* Contributors Listed Below - COPYRIGHT 2011,2015 */ +/* [+] 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 _DIMM_H +#define _DIMM_H + +#include <occ_common.h> +#include <trac_interface.h> +#include <errl.h> +#include <rtls.h> + +#define WORD_HIGH(data) ((uint32_t)(((uint64_t)data)>>32)) +#define WORD_LOW(data) ((uint32_t)(((uint64_t)data)&0xFFFFFFFF)) + +#define NUM_DIMM_PORTS 2 + +typedef enum +{ + DIMM_READ_SUCCESS = 0x00, + DIMM_READ_IN_PROGRESS = 0x01, + DIMM_READ_SCHEDULE_FAILED = 0xFA, + DIMM_READ_NOT_COMPLETE = 0xFF, +} readStatus_e; + +typedef enum +{ + PIB_I2C_ENGINE_C = 0x01, + PIB_I2C_ENGINE_D = 0x02, + PIB_I2C_ENGINE_E = 0x03, +} PIB_I2C_ENGINE; + +typedef enum +{ + MEM_TYPE_CUMULUS = 0x00, + MEM_TYPE_NIMBUS = 0xFF +} MEMORY_TYPE; + +// Generic memory initialization to handle init for all memory types +void memory_init(); + +// Nimbus specific init +void memory_nimbus_init(); + +// DIMM I2C state machine (for NIMBUS) +void task_dimm_sm(struct task *i_self); + +#endif //_DIMM_H |