summaryrefslogtreecommitdiffstats
path: root/arch/mips/lib/kbd-no.c
blob: c94e8c000648aa066d2a9634894b546cb97b6a86 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
/* $Id: kbd-no.c,v 1.1 1998/10/28 12:38:14 ralf Exp $
 *
 * This file is subject to the terms and conditions of the GNU General Public
 * License.  See the file "COPYING" in the main directory of this archive
 * for more details.
 *
 * Stub keyboard and psaux routines to keep Linux from crashing on machines
 * without a keyboard.
 *
 * Copyright (C) 1998 by Ralf Baechle
 */
#include <linux/sched.h>
#include <asm/keyboard.h>

static void no_kbd_request_region(void)
{
	/* No I/O ports are being used on the Indy.  */
}

static int no_kbd_request_irq(void (*handler)(int, void *, struct pt_regs *))
{
	return -ENODEV;
}

static int no_aux_request_irq(void (*handler)(int, void *, struct pt_regs *))
{
	return -ENODEV;
}

static void no_aux_free_irq(void)
{
}

static unsigned char no_kbd_read_input(void)
{
	return 0;
}

static void no_kbd_write_output(unsigned char val)
{
}

static void no_kbd_write_command(unsigned char val)
{
}

static unsigned char no_kbd_read_status(void)
{
	return 0;
}

struct kbd_ops no_kbd_ops = {
	no_kbd_request_region,
	no_kbd_request_irq,

	no_aux_request_irq,
	no_aux_free_irq,

	no_kbd_read_input,
	no_kbd_write_output,
	no_kbd_write_command,
	no_kbd_read_status
};