aboutsummaryrefslogtreecommitdiff
path: root/external
diff options
context:
space:
mode:
authorJeremy Kerr <jk@ozlabs.org>2017-05-26 12:54:26 +1000
committerStewart Smith <stewart@linux.vnet.ibm.com>2017-06-06 17:59:45 +1000
commit252356c13e05defa6d1724d8747256af761146e9 (patch)
tree09f6e8ba112e4518a87a754d9c893da56b5d4017 /external
parente72db6e03ca2e2759b98b4f9fefa5221eb2981bd (diff)
downloadskiboot-252356c13e05defa6d1724d8747256af761146e9.zip
skiboot-252356c13e05defa6d1724d8747256af761146e9.tar.gz
skiboot-252356c13e05defa6d1724d8747256af761146e9.tar.bz2
opal-prd: use get_ipoll_mask() callback
This change hooks-up the get_ipoll_mask callback, and use a HBRT-provided mask if it's present. Signed-off-by: Jeremy Kerr <jk@ozlabs.org> Reviewed-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com> Tested-by: Vasant Hegde <hegdevasant@linux.vnet.ibm.com> Signed-off-by: Stewart Smith <stewart@linux.vnet.ibm.com>
Diffstat (limited to 'external')
-rw-r--r--external/opal-prd/opal-prd.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/external/opal-prd/opal-prd.c b/external/opal-prd/opal-prd.c
index 7113a35..02ce185 100644
--- a/external/opal-prd/opal-prd.c
+++ b/external/opal-prd/opal-prd.c
@@ -120,7 +120,7 @@ static const char *opal_prd_devnode = "/dev/opal-prd";
static const char *opal_prd_socket = "/run/opal-prd-control";
static const char *hbrt_code_region_name = "ibm,hbrt-code-image";
static const int opal_prd_version = 1;
-static const uint64_t opal_prd_ipoll = 0xf000000000000000;
+static uint64_t opal_prd_ipoll = 0xf000000000000000;
static const char *ipmi_devnode = "/dev/ipmi0";
static const int ipmi_timeout_ms = 5000;
@@ -267,6 +267,7 @@ extern int call_mfg_htmgt_pass_thru(uint16_t i_cmdLength, uint8_t *i_cmdData,
uint16_t *o_rspLength, uint8_t *o_rspData);
extern int call_apply_attr_override(uint8_t *i_data, size_t size);
extern int call_run_command(int argc, const char **argv, char **o_outString);
+extern uint64_t call_get_ipoll_events(void);
void hservice_puts(const char *str)
{
@@ -1535,6 +1536,13 @@ static int run_attn_loop(struct opal_prd_ctx *ctx)
}
}
+ if (hservice_runtime->get_ipoll_events) {
+ pr_debug("HBRT: calling get_ipoll_events");
+ opal_prd_ipoll = call_get_ipoll_events();
+ }
+
+ pr_debug("HBRT: enabling IPOLL events 0x%016lx", opal_prd_ipoll);
+
/* send init message, to unmask interrupts */
msg.hdr.type = OPAL_PRD_MSG_TYPE_INIT;
msg.hdr.size = htobe16(sizeof(msg));