Index: console/console.c
===================================================================
--- console/console.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ console/console.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -37,8 +37,7 @@
 #include <stdio.h>
 
-
-#include <kbd.h>
 #include <fb.h>
 #include <ipc/ipc.h>
+#include <keys.h>
 #include <ipc/fb.h>
 #include <ipc/services.h>
Index: fb/ega.c
===================================================================
--- fb/ega.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ fb/ega.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -50,4 +50,5 @@
 #include <ipc/ns.h>
 #include <ipc/services.h>
+#include <libarch/ddi.h>
 
 #include "ega.h"
@@ -71,9 +72,4 @@
 #define EGA_STYLE(fg,bg) ((fg) > (bg) ? NORMAL_COLOR : INVERTED_COLOR)
 
-typedef unsigned char u8;
-typedef unsigned short u16;
-typedef unsigned int u32;
-
-
 /* Allow only 1 connection */
 static int client_connected = 0;
@@ -84,46 +80,4 @@
 
 static unsigned int style = NORMAL_COLOR;
-
-static inline void outb(u16 port, u8 b)
-{
-	asm volatile ("outb %0, %1\n" :: "a" (b), "d" (port));
-}
-
-static inline void outw(u16 port, u16 w)
-{
-	asm volatile ("outw %0, %1\n" :: "a" (w), "d" (port));
-}
-
-static inline void outl(u16 port, u32 l)
-{
-	asm volatile ("outl %0, %1\n" :: "a" (l), "d" (port));
-}
-
-static inline u8 inb(u16 port)
-{
-	u8 val;
-
-	asm volatile ("inb %1, %0 \n" : "=a" (val) : "d"(port));
-	return val;
-}
-
-static inline u16 inw(u16 port)
-{
-	u16 val;
-
-	asm volatile ("inw %1, %0 \n" : "=a" (val) : "d"(port));
-	return val;
-}
-
-static inline u32 inl(u16 port)
-{
-	u32 val;
-
-	asm volatile ("inl %1, %0 \n" : "=a" (val) : "d"(port));
-	return val;
-}
-
-
-
 
 static void clrscr(void)
@@ -151,5 +105,6 @@
 static void cursor_disable(void)
 {
-	u8 stat;
+	uint8_t stat;
+
 	outb(EGA_IO_ADDRESS , 0xa);
 	stat=inb(EGA_IO_ADDRESS + 1);
@@ -160,5 +115,6 @@
 static void cursor_enable(void)
 {
-	u8 stat;
+	uint8_t stat;
+
 	outb(EGA_IO_ADDRESS , 0xa);
 	stat=inb(EGA_IO_ADDRESS + 1);
Index: kbd/arch/ia32/include/kbd.h
===================================================================
--- kbd/arch/ia32/include/kbd.h	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/arch/ia32/include/kbd.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -28,5 +28,5 @@
 
 /** @addtogroup kbdamd64 amd64
- * @brief	HelenOS ia32 / amd64 arch dependent parts of uspace keyboard handler.
+ * @brief	HelenOS ia32 / amd64 arch dependent parts of uspace keyboard and mouse handler.
  * @ingroup  kbd
  * @{
@@ -41,7 +41,38 @@
 
 #include <key_buffer.h>
+#include <ddi.h>
+#include <libarch/ddi.h>
+
+#define KBD_IRQ      1
+#define MOUSE_IRQ    12
+
+#define i8042_DATA      0x60
+#define i8042_STATUS    0X64
+
+
+typedef unsigned char u8;
+typedef short u16;
+
+static inline void i8042_data_write(u8 data)
+{
+	outb(i8042_DATA, data);
+}
+
+static inline u8 i8042_data_read(void)
+{
+	return inb(i8042_DATA);
+}
+
+static inline u8 i8042_status_read(void)
+{
+	return inb(i8042_STATUS);
+}
+
+static inline void i8042_command_write(u8 command)
+{
+	outb(i8042_STATUS, command);
+}
 
 int kbd_arch_init(void);
-int kbd_arch_process(keybuffer_t *keybuffer, int scan_code);
 
 #endif
Index: kbd/arch/ia32/src/kbd.c
===================================================================
--- kbd/arch/ia32/src/kbd.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/arch/ia32/src/kbd.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -39,4 +39,28 @@
 #include <arch/kbd.h>
 #include <ipc/ipc.h>
+#include <unistd.h>
+#include <kbd.h>
+#include <keys.h>
+
+/* Interesting bits for status register */
+#define i8042_OUTPUT_FULL  0x1
+#define i8042_INPUT_FULL   0x2
+#define i8042_MOUSE_DATA   0x20
+
+/* Command constants */
+#define i8042_CMD_KBD 0x60
+#define i8042_CMD_MOUSE  0xd4
+
+/* Keyboard cmd byte */
+#define i8042_KBD_IE        0x1
+#define i8042_MOUSE_IE      0x2
+#define i8042_KBD_DISABLE   0x10
+#define i8042_MOUSE_DISABLE 0x20
+#define i8042_KBD_TRANSLATE 0x40
+
+/* Mouse constants */
+#define MOUSE_OUT_INIT  0xf4
+#define MOUSE_ACK       0xfa
+
 
 #define SPECIAL		255
@@ -232,10 +256,11 @@
 };
 
-irq_cmd_t i8042_cmds[1] = {
-	{ CMD_PORT_READ_1, (void *)0x60, 0 }
+irq_cmd_t i8042_cmds[2] = {
+	{ CMD_PORT_READ_1, (void *)0x64, 0, 1 },
+	{ CMD_PORT_READ_1, (void *)0x60, 0, 2 }
 };
 
 irq_code_t i8042_kbd = {
-	1,
+	2,
 	i8042_cmds
 };
@@ -355,4 +380,10 @@
 }
 
+
+static void wait_ready(void) {
+	while (i8042_status_read() & i8042_INPUT_FULL)
+		;
+}
+
 /** Register uspace irq handler
  * @return 
@@ -360,14 +391,74 @@
 int kbd_arch_init(void)
 {
-	return !(ipc_register_irq(1, &i8042_kbd));
+	int rc1, i;
+	int mouseenabled = 0;
+
+	iospace_enable(task_get_id(),(void *)i8042_DATA, 5);
+	/* Disable kbd, enable mouse */
+	i8042_command_write(i8042_CMD_KBD);
+	wait_ready();
+	i8042_command_write(i8042_CMD_KBD);
+	wait_ready();
+	i8042_data_write(i8042_KBD_DISABLE);
+	wait_ready();
+
+	/* Flush all current IO */
+	while (i8042_status_read() & i8042_OUTPUT_FULL)
+		i8042_data_read();
+	/* Initialize mouse */
+	i8042_command_write(i8042_CMD_MOUSE);
+	wait_ready();
+	i8042_data_write(MOUSE_OUT_INIT);
+	wait_ready();
+	
+	int mouseanswer = 0;
+	for (i=0;i < 1000; i++) {
+		int status = i8042_status_read();
+		if (status & i8042_OUTPUT_FULL) {
+			int data = i8042_data_read();
+			if (status & i8042_MOUSE_DATA) {
+				mouseanswer = data;
+				break;
+			}
+		}
+		usleep(1000);
+	}
+	if (mouseanswer == MOUSE_ACK) {
+		/* enable mouse */
+		mouseenabled = 1;
+
+		ipc_register_irq(MOUSE_IRQ, &i8042_kbd);
+	}
+	/* Enable kbd */
+	ipc_register_irq(KBD_IRQ, &i8042_kbd);
+
+	int newcontrol = i8042_KBD_IE | i8042_KBD_TRANSLATE;
+	if (mouseenabled)
+		newcontrol |= i8042_MOUSE_IE;
+	
+	i8042_command_write(i8042_CMD_KBD);
+	wait_ready();
+	i8042_data_write(newcontrol);
+	wait_ready();
+	
+	return 0;
 }
 
-int kbd_arch_process(keybuffer_t *keybuffer, int scan_code)
+/** Process keyboard & mouse events */
+int kbd_arch_process(keybuffer_t *keybuffer, ipc_call_t *call)
 {
-	if (scan_code != IGNORE_CODE) {
-		if (scan_code & KEY_RELEASE)
-			key_released(keybuffer, scan_code ^ KEY_RELEASE);
-		else
-			key_pressed(keybuffer, scan_code);
+	int status = IPC_GET_ARG1(*call);
+
+	if ((status & i8042_MOUSE_DATA)) {
+		;
+	} else {
+		int scan_code = IPC_GET_ARG2(*call);
+		
+		if (scan_code != IGNORE_CODE) {
+			if (scan_code & KEY_RELEASE)
+				key_released(keybuffer, scan_code ^ KEY_RELEASE);
+			else
+				key_pressed(keybuffer, scan_code);
+		}
 	}
 	return 	1;
Index: kbd/arch/ia64/include/kbd.h
===================================================================
--- kbd/arch/ia64/include/kbd.h	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/arch/ia64/include/kbd.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -42,5 +42,4 @@
 
 int kbd_arch_init(void);
-int kbd_arch_process(keybuffer_t *keybuffer, int scan_code);
 
 #endif
Index: kbd/arch/ia64/src/kbd.c
===================================================================
--- kbd/arch/ia64/src/kbd.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/arch/ia64/src/kbd.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -38,4 +38,6 @@
 #include <ipc/ipc.h>
 #include <sysinfo.h>
+#include <kbd.h>
+#include <keys.h>
 
 #define KEY_F1 0x504f1b
@@ -56,5 +58,5 @@
 
 irq_cmd_t ski_cmds[1] = {
-	{ CMD_IA64_GETCHAR, 0, 0 }
+	{ CMD_IA64_GETCHAR, 0, 0, 2 }
 };
 
@@ -68,7 +70,7 @@
 	if(sysinfo_value("kbd")) {
 		ipc_register_irq(sysinfo_value("kbd.irq"), &ski_kbd);
-		return 1;
+		return 0;
 	}	
-	
+	return 1;
 }
 
@@ -82,9 +84,10 @@
 */
 
-int kbd_arch_process(keybuffer_t *keybuffer, int scan_code) 
+int kbd_arch_process(keybuffer_t *keybuffer, ipc_call_t *call) 
 {
 	static unsigned long long buf=0;
 	static int count=0;	
 	static int esc_count=0;
+	int scan_code = IPC_GET_ARG2(*call);
 
 
Index: kbd/arch/mips32/include/kbd.h
===================================================================
--- kbd/arch/mips32/include/kbd.h	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/arch/mips32/include/kbd.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -41,5 +41,4 @@
 
 int kbd_arch_init(void);
-int kbd_arch_process(keybuffer_t *keybuffer, int scan_code);
 
 #endif
Index: kbd/arch/mips32/src/kbd.c
===================================================================
--- kbd/arch/mips32/src/kbd.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/arch/mips32/src/kbd.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -37,5 +37,6 @@
 #include <ipc/ipc.h>
 #include <sysinfo.h>
-
+#include <kbd.h>
+#include <keys.h>
 
 #define MSIM_KEY_F1 0x504f1bL
@@ -71,5 +72,5 @@
 
 irq_cmd_t msim_cmds[1] = {
-	{ CMD_MEM_READ_1, (void *)0xB0000000, 0 }
+	{ CMD_MEM_READ_1, (void *)0xB0000000, 0, 2 }
 };
 
@@ -86,5 +87,5 @@
 	msim=sysinfo_value("machine.msim");
 	gxemul=sysinfo_value("machine.lgxemul");
-	return 1;
+	return 0;
 }
 
@@ -374,7 +375,7 @@
 }
 
-int kbd_arch_process(keybuffer_t *keybuffer, int scan_code)
+int kbd_arch_process(keybuffer_t *keybuffer, ipc_call_t *call)
 {
-
+	int scan_code = IPC_GET_ARG2(*call);
 	static int esc_count=0;
 
Index: kbd/arch/ppc32/include/kbd.h
===================================================================
--- kbd/arch/ppc32/include/kbd.h	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/arch/ppc32/include/kbd.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -41,5 +41,4 @@
 
 int kbd_arch_init(void);
-int kbd_arch_process(keybuffer_t *keybuffer, int scan_code);
 
 #endif
Index: kbd/arch/ppc32/src/kbd.c
===================================================================
--- kbd/arch/ppc32/src/kbd.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/arch/ppc32/src/kbd.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -38,7 +38,9 @@
 #include <ipc/ipc.h>
 #include <sysinfo.h>
+#include <kbd.h>
+#include <keys.h>
 
 irq_cmd_t cuda_cmds[1] = {
-	{ CMD_PPC32_GETCHAR, 0, 0 }
+	{ CMD_PPC32_GETCHAR, 0, 0, 2 }
 };
 
@@ -182,12 +184,14 @@
 int kbd_arch_init(void)
 {
-	return (!ipc_register_irq(sysinfo_value("cuda.irq"), &cuda_kbd));
+	return ipc_register_irq(sysinfo_value("cuda.irq"), &cuda_kbd);
 }
 
 
-int kbd_arch_process(keybuffer_t *keybuffer, int scan_code) 
+int kbd_arch_process(keybuffer_t *keybuffer, ipc_call_t *call) 
 {
-	if (scan_code != -1) {
-		uint8_t scancode = (uint8_t) scan_code;
+	int param = IPC_GET_ARG2(*call);
+
+	if (param != -1) {
+		uint8_t scancode = (uint8_t) param;
 	
 		if ((scancode & 0x80) != 0x80) {
Index: kbd/generic/kbd.c
===================================================================
--- kbd/generic/kbd.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/generic/kbd.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -53,4 +53,5 @@
 #include <key_buffer.h>
 #include <async.h>
+#include <keys.h>
 
 #define NAME "KBD"
@@ -63,8 +64,8 @@
 {
 	int chr;
-	
+
 	if (cons_connected && phone2cons != -1) {
 		/* recode to ASCII - one interrupt can produce more than one code so result is stored in fifo */
-		kbd_arch_process(&keybuffer, IPC_GET_ARG2(*call));
+		kbd_arch_process(&keybuffer, call);
 		
 		while (!keybuffer_empty(&keybuffer)) {
@@ -124,7 +125,6 @@
 	
 	/* Initialize arch dependent parts */
-	if (!(res = kbd_arch_init())) {
-			return -1;
-			};
+	if (kbd_arch_init())
+		return -1;
 	
 	/* Initialize key buffer */
Index: kbd/include/kbd.h
===================================================================
--- kbd/include/kbd.h	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ kbd/include/kbd.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -38,18 +38,6 @@
 #define __KBD_H__
 
-#define KBD_PUSHCHAR 1024
 
-#define KBD_KEY_F1	0x3b
-#define KBD_KEY_F2	0x3c
-#define KBD_KEY_F3	0x3d
-#define KBD_KEY_F4	0x3e
-#define KBD_KEY_F5	0x3f
-#define KBD_KEY_F6	0x40
-#define KBD_KEY_F7	0x41
-#define KBD_KEY_F8	0x42
-#define KBD_KEY_F9	0x43
-#define KBD_KEY_F10	0x44
-#define KBD_KEY_F11	0x45
-#define KBD_KEY_F12	0x46
+int kbd_arch_process(keybuffer_t *keybuffer, ipc_call_t *call);
 
 #endif
Index: kbd/include/keys.h
===================================================================
--- kbd/include/keys.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
+++ kbd/include/keys.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -0,0 +1,48 @@
+/*
+ * Copyright (C) 2006 Josef Cejka
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * - Redistributions of source code must retain the above copyright
+ *   notice, this list of conditions and the following disclaimer.
+ * - Redistributions in binary form must reproduce the above copyright
+ *   notice, this list of conditions and the following disclaimer in the
+ *   documentation and/or other materials provided with the distribution.
+ * - The name of the author may not be used to endorse or promote products
+ *   derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+
+#ifndef _KBD_KEYS_H_
+#define _KBD_KEYS_H_
+
+#define KBD_PUSHCHAR 1024
+
+#define KBD_KEY_F1	0x3b
+#define KBD_KEY_F2	0x3c
+#define KBD_KEY_F3	0x3d
+#define KBD_KEY_F4	0x3e
+#define KBD_KEY_F5	0x3f
+#define KBD_KEY_F6	0x40
+#define KBD_KEY_F7	0x41
+#define KBD_KEY_F8	0x42
+#define KBD_KEY_F9	0x43
+#define KBD_KEY_F10	0x44
+#define KBD_KEY_F11	0x45
+#define KBD_KEY_F12	0x46
+
+#endif
Index: klog/klog.c
===================================================================
--- klog/klog.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ klog/klog.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -50,6 +50,6 @@
 	
 	async_serialize_start();
-	for (i=0; klog[i + IPC_GET_ARG2(*call)] && i < IPC_GET_ARG3(*call); i++)
-		putchar(klog[i + IPC_GET_ARG2(*call)]);
+	for (i=0; klog[i + IPC_GET_ARG1(*call)] && i < IPC_GET_ARG2(*call); i++)
+		putchar(klog[i + IPC_GET_ARG1(*call)]);
 	putchar('\n');
 	async_serialize_end();
Index: libc/arch/amd64/include/ddi.h
===================================================================
--- libc/arch/amd64/include/ddi.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
+++ libc/arch/amd64/include/ddi.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -0,0 +1,1 @@
+../../ia32/include/ddi.h
Index: libc/arch/ia32/include/ddi.h
===================================================================
--- libc/arch/ia32/include/ddi.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
+++ libc/arch/ia32/include/ddi.h	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -0,0 +1,72 @@
+/*
+ * Copyright (C) 2006 Ondrej Palkovsky
+ * All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ *
+ * - Redistributions of source code must retain the above copyright
+ *   notice, this list of conditions and the following disclaimer.
+ * - Redistributions in binary form must reproduce the above copyright
+ *   notice, this list of conditions and the following disclaimer in the
+ *   documentation and/or other materials provided with the distribution.
+ * - The name of the author may not be used to endorse or promote products
+ *   derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#ifndef __ia32_libc_DDI_H_
+#define __ia32_libc_DDI_H_
+
+static inline void outb(int16_t port, uint8_t b)
+{
+	asm volatile ("outb %0, %1\n" :: "a" (b), "d" (port));
+}
+
+static inline void outw(int16_t port, int16_t w)
+{
+	asm volatile ("outw %0, %1\n" :: "a" (w), "d" (port));
+}
+
+static inline void outl(int16_t port, uint32_t l)
+{
+	asm volatile ("outl %0, %1\n" :: "a" (l), "d" (port));
+}
+
+static inline uint8_t inb(int16_t port)
+{
+	uint8_t val;
+
+	asm volatile ("inb %1, %0 \n" : "=a" (val) : "d"(port));
+	return val;
+}
+
+static inline int16_t inw(int16_t port)
+{
+	int16_t val;
+
+	asm volatile ("inw %1, %0 \n" : "=a" (val) : "d"(port));
+	return val;
+}
+
+static inline uint32_t inl(int16_t port)
+{
+	uint32_t val;
+
+	asm volatile ("inl %1, %0 \n" : "=a" (val) : "d"(port));
+	return val;
+}
+
+
+#endif
Index: libc/generic/async.c
===================================================================
--- libc/generic/async.c	(revision 290c0db22c21cebdb9432aceb7a3931b06f45126)
+++ libc/generic/async.c	(revision 15039b6701d041636bc9aaa20ee0cd202b7473dc)
@@ -449,10 +449,12 @@
 {
 	/* Unrouted call - do some default behaviour */
-	switch (IPC_GET_METHOD(*call)) {
-	case IPC_M_INTERRUPT:
+	if ((callid & IPC_CALLID_NOTIFICATION)) {
 		in_interrupt_handler = 1;
 		(*interrupt_received)(callid,call);
 		in_interrupt_handler = 0;
 		return;
+	}		
+
+	switch (IPC_GET_METHOD(*call)) {
 	case IPC_M_CONNECT_ME_TO:
 		/* Open new connection with thread etc. */
