summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorPatrick Georgi <patrick@georgi-clan.de>2012-08-16 15:39:35 +0200
committerStefan Reinauer <stefan.reinauer@coreboot.org>2012-10-05 22:02:59 +0200
commitf3a163a1274de16771ed84d51119457ba3a2881d (patch)
tree3731da75d5eab65a8c0178f69cefafc0ea0bf266 /src
parent1ee8b45740a2c888742cb5917ca71cd0ed86cec2 (diff)
downloadcoreboot-f3a163a1274de16771ed84d51119457ba3a2881d.tar.xz
YABEL: Common API to register interrupt handlers
Provide (mostly) the same API for registering interrupt handlers as with x86emu. Change-Id: I1364b08d9043039550786a1758508ae088813aa3 Signed-off-by: Patrick Georgi <patrick@georgi-clan.de> Reviewed-on: http://review.coreboot.org/1558 Tested-by: build bot (Jenkins) Reviewed-by: Stefan Reinauer <stefan.reinauer@coreboot.org>
Diffstat (limited to 'src')
-rw-r--r--src/devices/oprom/yabel/biosemu.c6
-rw-r--r--src/devices/oprom/yabel/biosemu.h1
2 files changed, 7 insertions, 0 deletions
diff --git a/src/devices/oprom/yabel/biosemu.c b/src/devices/oprom/yabel/biosemu.c
index 8d7795971f..2a2ca312cb 100644
--- a/src/devices/oprom/yabel/biosemu.c
+++ b/src/devices/oprom/yabel/biosemu.c
@@ -44,6 +44,12 @@ static X86EMU_pioFuncs my_pio_funcs = {
/* interrupt function override array (see biosemu.h) */
yabel_handleIntFunc yabel_intFuncArray[256];
+void
+mainboard_interrupt_handlers(int interrupt, yabel_handleIntFunc func)
+{
+ yabel_intFuncArray[interrupt] = func;
+}
+
/* main entry into YABEL biosemu, arguments are:
* *biosmem = pointer to virtual memory
* biosmem_size = size of the virtual memory
diff --git a/src/devices/oprom/yabel/biosemu.h b/src/devices/oprom/yabel/biosemu.h
index 39cc0a9b0e..4f5c4aaa5b 100644
--- a/src/devices/oprom/yabel/biosemu.h
+++ b/src/devices/oprom/yabel/biosemu.h
@@ -45,6 +45,7 @@
* the function pointer is NULL */
typedef int (* yabel_handleIntFunc)(void);
extern yabel_handleIntFunc yabel_intFuncArray[256];
+void mainboard_interrupt_handlers(int, yabel_handleIntFunc);
struct device;