Index: kernel/arch/ia32/src/ia32.c
===================================================================
--- kernel/arch/ia32/src/ia32.c	(revision 0e0490bd48ae43cfc5d71d6ee75ebaafa5e6f20e)
+++ kernel/arch/ia32/src/ia32.c	(revision a2a2a34a30c500db7cc8308839952d3f014a1e19)
@@ -114,5 +114,5 @@
 		
 #ifdef CONFIG_FB
-		if (vesa_present()) 
+		if (vesa_present())
 			vesa_init();
 		else
@@ -152,15 +152,17 @@
 void arch_post_smp_init(void)
 {
+#ifdef CONFIG_PC_KBD
 	devno_t devno = device_assign_devno();
-
+	
 	/*
-	 * Initialize the keyboard module and conect it to stdin. Then
-	 * initialize the i8042 controller and connect it to kbrdin. Enable
-	 * keyboard interrupts.
+	 * Initialize the i8042 controller. Then initialize the keyboard
+	 * module and connect it to i8042. Enable keyboard interrupts.
 	 */
-	kbrd_init(stdin);
-	(void) i8042_init((i8042_t *) I8042_BASE, devno, IRQ_KBD, &kbrdin);
-	trap_virtual_enable_irqs(1 << IRQ_KBD);
-
+	indev_t *kbrdin = i8042_init((i8042_t *) I8042_BASE, devno, IRQ_KBD);
+	if (kbrdin) {
+		kbrd_init(kbrdin);
+		trap_virtual_enable_irqs(1 << IRQ_KBD);
+	}
+	
 	/*
 	 * This is the necessary evil until the userspace driver is entirely
@@ -174,4 +176,5 @@
 	sysinfo_set_item_val("kbd.address.kernel", NULL,
 	    (uintptr_t) I8042_BASE);
+#endif
 }
 
@@ -207,7 +210,12 @@
 {
 #ifdef CONFIG_FB
-	vesa_redraw();
+	if (vesa_present())
+		vesa_redraw();
+	else
+#endif
+#ifdef CONFIG_EGA
+		ega_redraw();
 #else
-	ega_redraw();
+		{}
 #endif
 }
