diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2006-08-14 15:56:03 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2006-08-14 15:56:03 +0000 |
commit | 36168e0c0a3fa926f246b660ba6601488c1a02fb (patch) | |
tree | 0386123e8c25a66ab815a4b7727839934f2abefc /sys/dev/wscons/wskbd.c | |
parent | ae27946c0e74d5cec3d1def58ae50b39cfcd1f12 (diff) |
Add an attribute to the keyboard devices which can produce the keys the
wskbd hotkey thread knows about, and make this code conditional on this
attribute. No functional change, simply smaller kernels on a few platforms.
Diffstat (limited to 'sys/dev/wscons/wskbd.c')
-rw-r--r-- | sys/dev/wscons/wskbd.c | 20 |
1 files changed, 11 insertions, 9 deletions
diff --git a/sys/dev/wscons/wskbd.c b/sys/dev/wscons/wskbd.c index 304db699084..7c39a8bff9f 100644 --- a/sys/dev/wscons/wskbd.c +++ b/sys/dev/wscons/wskbd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: wskbd.c,v 1.51 2006/08/06 11:36:35 miod Exp $ */ +/* $OpenBSD: wskbd.c,v 1.52 2006/08/14 15:56:02 miod Exp $ */ /* $NetBSD: wskbd.c,v 1.80 2005/05/04 01:52:16 augustss Exp $ */ /* @@ -79,12 +79,6 @@ * to `wscons_events' and passes them up to the appropriate reader. */ -#ifndef SMALL_KERNEL -#define BURNER_SUPPORT -#define SCROLLBACK_SUPPORT -#define HOTKEY_SUPPORT -#endif - #include <sys/param.h> #include <sys/conf.h> #include <sys/device.h> @@ -113,8 +107,16 @@ #include "audio.h" /* NAUDIO (mixer tuning) */ #include "wsdisplay.h" +#include "wskbd.h" #include "wsmux.h" +#ifndef SMALL_KERNEL +#define BURNER_SUPPORT +#define SCROLLBACK_SUPPORT +#undef NWSKBD_HOTKEY +#define NWSKBD_HOTKEY 0 +#endif + #ifdef WSKBD_DEBUG #define DPRINTF(x) if (wskbddebug) printf x int wskbddebug = 0; @@ -449,7 +451,7 @@ wskbd_attach(struct device *parent, struct device *self, void *aux) } #endif -#ifdef HOTKEY_SUPPORT +#if NWSKBD_HOTKEY > 0 wskbd_hotkey_init(); #endif } @@ -1640,7 +1642,7 @@ wskbd_translate(struct wskbd_internal *id, u_int type, int value) } } -#ifdef HOTKEY_SUPPORT +#if NWSKBD_HOTKEY > 0 /* Submit Audio keys for hotkey processing */ if (KS_GROUP(ksym) == KS_GROUP_Function) { switch (ksym) { |