diff options
author | Doug Gilbert <dgilbert@us.ibm.com> | 2012-05-14 17:13:24 -0500 |
---|---|---|
committer | Douglas R. Gilbert <dgilbert@us.ibm.com> | 2012-05-21 15:50:06 -0500 |
commit | 1257ee668b165ce17a07f94c5d5deb8d361bd010 (patch) | |
tree | 752188bb47447762bcf70590f619d5b409417232 /src/usr/intr | |
parent | 487669b2da18343f648b4984765c36bb11f59b14 (diff) | |
download | talos-hostboot-1257ee668b165ce17a07f94c5d5deb8d361bd010.tar.gz talos-hostboot-1257ee668b165ce17a07f94c5d5deb8d361bd010.zip |
Register service with initservice to get notified on shutdown
RTC: 41263
Change-Id: Ic44026c55453d41e1e5e0921339ec126dc665566
Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/1061
Tested-by: Jenkins Server
Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/usr/intr')
-rw-r--r-- | src/usr/intr/intrrp.C | 21 | ||||
-rw-r--r-- | src/usr/intr/intrrp.H | 7 |
2 files changed, 14 insertions, 14 deletions
diff --git a/src/usr/intr/intrrp.C b/src/usr/intr/intrrp.C index d05c6c44e..61f537932 100644 --- a/src/usr/intr/intrrp.C +++ b/src/usr/intr/intrrp.C @@ -29,6 +29,7 @@ #include <trace/interface.H> #include <errno.h> #include <initservice/taskargs.H> +#include <initservice/initserviceif.H> #include <util/singleton.H> #include <intr/intr_reasoncodes.H> #include <sys/mmio.h> @@ -155,6 +156,11 @@ errlHndl_t IntrRp::_init() msg_q_register(iv_msgQ, INTR_MSGQ); task_create(IntrRp::msg_handler, NULL); + + // Register event to be called on shutdown + INITSERVICE::registerShutdownEvent(iv_msgQ, + MSG_INTR_SHUTDOWN, + INITSERVICE::LOWEST_PRIORITY); } return err; @@ -380,6 +386,14 @@ void IntrRp::msgHandler() } break; + case MSG_INTR_SHUTDOWN: + { + TRACFCOMP(g_trac_intr,"Shutdown event received"); + // TODO rtc story 39878 for content + msg_respond(iv_msgQ, msg); + } + break; + default: msg->data[1] = -EINVAL; msg_respond(iv_msgQ, msg); @@ -566,13 +580,6 @@ errlHndl_t IntrRp::checkAddress(uint64_t i_addr) return err; } -// TODO rtc story 39878 -errlHndl_t IntrRp::shutDown() -{ - errlHndl_t err = NULL; - return err; -} - // Register a message queue with a particular intr type errlHndl_t INTR::registerMsgQ(msg_q_t i_msgQ, ext_intr_t i_type) { diff --git a/src/usr/intr/intrrp.H b/src/usr/intr/intrrp.H index 2900c5276..646d0761d 100644 --- a/src/usr/intr/intrrp.H +++ b/src/usr/intr/intrrp.H @@ -51,13 +51,6 @@ namespace INTR */ static void init( errlHndl_t &io_rtaskRetErrl ); - /** - * This function is registered with init for shutdown - * processing of the interrupt presenter. - * TODO Story 39878 - */ - static errlHndl_t shutDown(); - protected: /** |