diff options
-rw-r--r-- | external/opal-prd/hostboot-interface.h | 16 | ||||
-rw-r--r-- | external/opal-prd/opal-prd.c | 5 | ||||
-rw-r--r-- | external/opal-prd/thunk.S | 3 |
3 files changed, 22 insertions, 2 deletions
diff --git a/external/opal-prd/hostboot-interface.h b/external/opal-prd/hostboot-interface.h index 05fe052..36d53a6 100644 --- a/external/opal-prd/hostboot-interface.h +++ b/external/opal-prd/hostboot-interface.h @@ -41,6 +41,11 @@ enum MemoryError_t MEMORY_ERROR_UE = 1, }; +/* Capability sets, for get_interface_capabilities */ +#define HBRT_CAPS_SET0_COMMON 0 +#define HBRT_CAPS_SET1_OPAL 1 +#define HBRT_CAPS_SET2_PHYP 2 + struct host_interfaces { /** Interface version. */ uint64_t interface_version; @@ -277,8 +282,17 @@ struct host_interfaces { int (*memory_error)( uint64_t i_startAddr, uint64_t i_endAddr, enum MemoryError_t i_errorType ); + /** + * @brief Query the prd infrastructure for interface capabilities. + * @param[in] i_set The set of capabilites to retrieve + * + * @return a bitmask containing the relevant HBRT_CAPS_* for + * this implementation and the specified set. + */ + uint64_t (*get_interface_capabilities)(uint64_t i_set); + /* Reserve some space for future growth. */ - void (*reserved[32])(void); + void (*reserved[31])(void); }; struct runtime_interfaces { diff --git a/external/opal-prd/opal-prd.c b/external/opal-prd/opal-prd.c index 18c6e49..245c957 100644 --- a/external/opal-prd/opal-prd.c +++ b/external/opal-prd/opal-prd.c @@ -649,6 +649,11 @@ int hservice_memory_error(uint64_t i_start_addr, uint64_t i_endAddr, return 0; } +uint64_t hservice_get_interface_capabilities(uint64_t set) +{ + return 0; +} + int hservices_init(struct opal_prd_ctx *ctx, void *code) { uint64_t *s, *d; diff --git a/external/opal-prd/thunk.S b/external/opal-prd/thunk.S index f25afde..f355158 100644 --- a/external/opal-prd/thunk.S +++ b/external/opal-prd/thunk.S @@ -186,10 +186,11 @@ hinterface: CALLBACK_THUNK(hservice_i2c_write) CALLBACK_THUNK(hservice_ipmi_msg) CALLBACK_THUNK(hservice_memory_error) + CALLBACK_THUNK(hservice_get_interface_capabilities) .globl __hinterface_pad __hinterface_pad: /* Reserved space for future growth */ - .space 32*8,0 + .space 31*8,0 .globl __hinterface_end __hinterface_end: /* Eye catcher for debugging */ |