summaryrefslogtreecommitdiffstats
path: root/src/include/usr/hwpf/fapi/fapiCollectFfdc.H
diff options
context:
space:
mode:
Diffstat (limited to 'src/include/usr/hwpf/fapi/fapiCollectFfdc.H')
-rw-r--r--src/include/usr/hwpf/fapi/fapiCollectFfdc.H50
1 files changed, 50 insertions, 0 deletions
diff --git a/src/include/usr/hwpf/fapi/fapiCollectFfdc.H b/src/include/usr/hwpf/fapi/fapiCollectFfdc.H
new file mode 100644
index 000000000..ccee96a93
--- /dev/null
+++ b/src/include/usr/hwpf/fapi/fapiCollectFfdc.H
@@ -0,0 +1,50 @@
+/**
+ * @file fapiCollectFfdc.H
+ *
+ * @brief Defines the fapiCollectFfdc function
+ */
+
+/*
+ * Change Log ******************************************************************
+ * Flag Defect/Feature User Date Description
+ * ------ -------------- ---------- ----------- ----------------------------
+ * mjjones 08/09/2011 Created.
+ */
+
+#ifndef FAPICOLLECTFFDC_H_
+#define FAPICOLLECTFFDC_H_
+
+#include <stdint.h>
+#include <fapiReturnCode.H>
+
+namespace fapi
+{
+
+/**
+ * @brief Collect FFDC
+ *
+ * Collect FFDC. This function should be called by PLAT when it is processing
+ * a ReturnCode generated by a HWP and the ErrorInfoRepository contains a record
+ * for the error indicating that FFDC should be collected. This function is
+ * implemented in the generated fapiCollectFfdc.C file (generated using data
+ * from the Error Information XML file)
+ *
+ * @param[in] i_token FFDC HWP token (retrieved from ErrorInfoRepository)
+ * @param[in] i_target Reference to Target to collect FFDC from
+ * @param[out] o_pFfdc Reference to uint8_t pointer. Set to point to a newly
+ * allocated array containing FFDC data
+ * @param[out] o_size Reference to uint32_t. Set to the size of the FFDC
+ * data
+ *
+ * @return ReturnCode
+ *
+ * @note Caller must delete the data with "delete [] o_pFfdc"
+ */
+ReturnCode fapiCollectFfdc(const FfdcHwpToken i_token,
+ const Target & i_target,
+ uint8_t * & o_pFfdc,
+ uint32_t & o_size);
+
+}
+
+#endif // FAPICOLLECTFFDC_H_
OpenPOWER on IntegriCloud