lkml.org 
[lkml]   [2002]   [Dec]   [9]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [PATCH] Re: pc_keyb.c #define kbd_controller_present()
Date
You should only need this:

+#ifndef CONFIG_PSKEYBOARD
+#define kbd_controller_present() 0
+#endif

I think the following hunk should be superfluous:

+#ifdef CONFIG_PSKEYBOARD
#define kbd_read_input() inb(KBD_DATA_REG)
#define kbd_read_status() inb(KBD_STATUS_REG)
#define kbd_write_output(val) outb(val, KBD_DATA_REG)
#define kbd_write_command(val) outb(val, KBD_CNTL_REG)
+#else
+#define kbd_read_input() 0
+#define kbd_read_status() 0
+#define kbd_write_output(val)
+#define kbd_write_command(val)
+#endif

Or is there some case where pc_keyb will use kbd_read_input() and
friends even if kbd_controller_present() is false?

We have the equivalent of the first hunk in asm-ia64/keyboard.h, and
the kbd_controller_present() hook should be used consistently to
avoid breakage. For example, if you include the second hunk, and
pc_keyb.c changes to use kbd_read_input() even when kbd_controller_present()
is false, i386 might still work but ia64 would break.

Bjorn

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:31    [W:0.872 / U:0.092 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site