[Pdbg] [PATCH 2/2] libpdbg: Add apis for mpipl related chip-ops
Amitay Isaacs
amitay at ozlabs.org
Wed Mar 4 17:16:19 AEDT 2020
From: Dhruvaraj Subhashchandran <dhruvaraj at in.ibm.com>
Signed-off-by: Dhruvaraj Subhashchandran <dhruvaraj at in.ibm.com>
Reviewed-by: Amitay Isaacs <amitay at ozlabs.org>
---
libpdbg/libpdbg.h | 18 ++++++++++++++++++
libpdbg/target.c | 22 ++++++++++++++++++++++
2 files changed, 40 insertions(+)
diff --git a/libpdbg/libpdbg.h b/libpdbg/libpdbg.h
index 1fc7ef4..fbc32b6 100644
--- a/libpdbg/libpdbg.h
+++ b/libpdbg/libpdbg.h
@@ -1161,6 +1161,24 @@ int sbe_istep(struct pdbg_target *target, uint32_t major, uint32_t minor);
*/
uint32_t sbe_ffdc_get(struct pdbg_target *target, const uint8_t **ffdc, uint32_t *ffdc_len);
+/**
+ * @brief Execute enter mpipl on the pib
+ *
+ * @param[in] target pib target to operate on
+ *
+ * @return 0 on success, -1 on failure
+ */
+int sbe_mpipl_enter(struct pdbg_target *target);
+
+/**
+ * @brief Execute continue mpipl on the pib
+ *
+ * @param[in] target pib target to operate on
+ *
+ * @return 0 on success, -1 on failure
+ */
+int sbe_mpipl_continue(struct pdbg_target *target);
+
/**
* @brief Type for specifying a progress callback for long running
* operations
diff --git a/libpdbg/target.c b/libpdbg/target.c
index 5906ce7..1b54660 100644
--- a/libpdbg/target.c
+++ b/libpdbg/target.c
@@ -308,6 +308,28 @@ int sbe_istep(struct pdbg_target *target, uint32_t major, uint32_t minor)
return chipop->istep(chipop, major, minor);
}
+int sbe_mpipl_enter(struct pdbg_target *target)
+{
+ struct chipop *chipop;
+
+ chipop = pib_to_chipop(target);
+ if (!chipop)
+ return -1;
+
+ return chipop->mpipl_enter(chipop);
+}
+
+int sbe_mpipl_continue(struct pdbg_target *target)
+{
+ struct chipop *chipop;
+
+ chipop = pib_to_chipop(target);
+ if (!chipop)
+ return -1;
+
+ return chipop->mpipl_continue(chipop);
+}
+
uint32_t sbe_ffdc_get(struct pdbg_target *target, const uint8_t **ffdc, uint32_t *ffdc_len)
{
struct chipop *chipop;
--
2.24.1
More information about the Pdbg
mailing list