xref: /netbsd-src/sys/dev/wscons/wscons_callbacks.h (revision 96d14f097340c0fdd68e2aaf15e12aca01b6fa2d)
1*96d14f09Sdogcow /* $NetBSD: wscons_callbacks.h,v 1.19 2007/10/19 08:57:50 dogcow Exp $ */
2b31e6386Sdrochner 
3b31e6386Sdrochner /*
4b31e6386Sdrochner  * Copyright (c) 1996, 1997 Christopher G. Demetriou.  All rights reserved.
5b31e6386Sdrochner  *
6b31e6386Sdrochner  * Redistribution and use in source and binary forms, with or without
7b31e6386Sdrochner  * modification, are permitted provided that the following conditions
8b31e6386Sdrochner  * are met:
9b31e6386Sdrochner  * 1. Redistributions of source code must retain the above copyright
10b31e6386Sdrochner  *    notice, this list of conditions and the following disclaimer.
11b31e6386Sdrochner  * 2. Redistributions in binary form must reproduce the above copyright
12b31e6386Sdrochner  *    notice, this list of conditions and the following disclaimer in the
13b31e6386Sdrochner  *    documentation and/or other materials provided with the distribution.
14b31e6386Sdrochner  * 3. All advertising materials mentioning features or use of this software
15b31e6386Sdrochner  *    must display the following acknowledgement:
16b31e6386Sdrochner  *      This product includes software developed by Christopher G. Demetriou
17b31e6386Sdrochner  *	for the NetBSD Project.
18b31e6386Sdrochner  * 4. The name of the author may not be used to endorse or promote products
19b31e6386Sdrochner  *    derived from this software without specific prior written permission
20b31e6386Sdrochner  *
21b31e6386Sdrochner  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
22b31e6386Sdrochner  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
23b31e6386Sdrochner  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
24b31e6386Sdrochner  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
25b31e6386Sdrochner  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
26b31e6386Sdrochner  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27b31e6386Sdrochner  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28b31e6386Sdrochner  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29b31e6386Sdrochner  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30b31e6386Sdrochner  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31b31e6386Sdrochner  */
32b31e6386Sdrochner 
33*96d14f09Sdogcow #include <sys/device.h>
34*96d14f09Sdogcow 
352f1f0a17Saugustss struct wsevsrc;
362f1f0a17Saugustss 
37b31e6386Sdrochner /*
38b31e6386Sdrochner  * Calls to the display interface from the glue code.
39b31e6386Sdrochner  */
4048ea68d3Saugustss void wsdisplay_set_console_kbd(struct wsevsrc *);
41b31e6386Sdrochner 
42b31e6386Sdrochner /*
43b31e6386Sdrochner  * Calls to the display interface from the keyboard interface.
44b31e6386Sdrochner  */
45e4a56b25Sjoerg void	wsdisplay_kbdinput(device_t , keysym_t);
46e4a56b25Sjoerg int	wsdisplay_switch(device_t, int, int);
476424072cSdrochner enum wsdisplay_resetops {
486424072cSdrochner 	WSDISPLAY_RESETEMUL,
496424072cSdrochner 	WSDISPLAY_RESETCLOSE
506424072cSdrochner };
51e4a56b25Sjoerg void	wsdisplay_reset(device_t, enum wsdisplay_resetops);
52e4a56b25Sjoerg void	wsdisplay_kbdholdscreen(device_t, int);
53b31e6386Sdrochner 
5482e5e6abSaugustss void	wsdisplay_set_cons_kbd(int (*get)(dev_t),
55da4dc67dSthorpej 			       void (*poll)(dev_t, int),
5682e5e6abSaugustss 			       void (*bell)(dev_t, u_int, u_int, u_int));
5782e5e6abSaugustss void	wsdisplay_unset_cons_kbd(void);
58dcfcbaf8Stakemura struct wsdisplay_param;
59e4a56b25Sjoerg int	wsdisplay_param(device_t, u_long, struct wsdisplay_param *);
60b31e6386Sdrochner 
61b31e6386Sdrochner /*
62b31e6386Sdrochner  * Calls to the keyboard interface from the glue code.
63b31e6386Sdrochner  */
64e4a56b25Sjoerg struct wsevsrc *wskbd_set_console_display(device_t, struct wsevsrc *);
6582e5e6abSaugustss int wskbd_pickfree(void);
66