summaryrefslogtreecommitdiffstats
path: root/src/occ_405/dimm/dimm.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/occ_405/dimm/dimm.h')
-rw-r--r--src/occ_405/dimm/dimm.h69
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
OpenPOWER on IntegriCloud