OpenCores
URL https://opencores.org/ocsvn/or1k/or1k/trunk

Subversion Repositories or1k

[/] [or1k/] [trunk/] [linux/] [linux-2.4/] [include/] [asm-sparc/] [keyboard.h] - Blame information for rev 1765

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 1275 phoenix
/* $Id: keyboard.h,v 1.1.1.1 2004-04-15 02:40:37 phoenix Exp $
2
 * linux/include/asm-sparc/keyboard.h
3
 *
4
 * sparc64 Created Aug 29 1997 by Eddie C. Dost (ecd@skynet.be)
5
 */
6
 
7
/*
8
 *  This file contains the Ultra/PCI architecture specific keyboard definitions
9
 */
10
 
11
#ifndef _SPARC_KEYBOARD_H
12
#define _SPARC_KEYBOARD_H 1
13
 
14
#ifdef __KERNEL__
15
 
16
#include <linux/config.h>
17
#include <linux/ioport.h>
18
#include <linux/kd.h>
19
#include <asm/io.h>
20
 
21
#define KEYBOARD_IRQ                    13
22
#define DISABLE_KBD_DURING_INTERRUPTS   0
23
 
24
extern int pcikbd_setkeycode(unsigned int scancode, unsigned int keycode);
25
extern int pcikbd_getkeycode(unsigned int scancode);
26
extern int pcikbd_translate(unsigned char scancode, unsigned char *keycode,
27
                            char raw_mode);
28
extern char pcikbd_unexpected_up(unsigned char keycode);
29
extern void pcikbd_leds(unsigned char leds);
30
extern void pcikbd_init_hw(void);
31
extern unsigned char pcikbd_sysrq_xlate[128];
32
 
33
#define kbd_setkeycode                  pcikbd_setkeycode
34
#define kbd_getkeycode                  pcikbd_getkeycode
35
#define kbd_translate                   pcikbd_translate
36
#define kbd_unexpected_up               pcikbd_unexpected_up
37
#define kbd_leds                        pcikbd_leds
38
#define kbd_init_hw                     pcikbd_init_hw
39
#define kbd_sysrq_xlate                 pcikbd_sysrq_xlate
40
#define kbd_init                        pcikbd_init
41
 
42
#define compute_shiftstate              pci_compute_shiftstate
43
#define getkeycode                      pci_getkeycode
44
#define setkeycode                      pci_setkeycode
45
#define getledstate                     pci_getledstate
46
#define setledstate                     pci_setledstate
47
#define register_leds                   pci_register_leds
48
 
49
/* #define SYSRQ_KEY 0x54 */    /* sparc64 */
50
#define SYSRQ_KEY 0x63          /* sparc */
51
 
52
/* resource allocation */
53
#define kbd_request_region() request_region(0x60, 16, "keyboard")
54
#define kbd_request_irq(handler) request_irq(KEYBOARD_IRQ, handler, 0, \
55
                                             "keyboard", NULL)
56
 
57
/* How to access the keyboard macros on this platform.  */
58
#define kbd_read_input() inb(KBD_DATA_REG)
59
#define kbd_read_status() inb(KBD_STATUS_REG)
60
#define kbd_write_output(val) outb(val, KBD_DATA_REG)
61
#define kbd_write_command(val) outb(val, KBD_CNTL_REG)
62
 
63
/* Some stoneage hardware needs delays after some operations.  */
64
#define kbd_pause() do { } while(0)
65
 
66
/*
67
 * Machine specific bits for the PS/2 driver
68
 */
69
 
70
#define AUX_IRQ 12
71
 
72
#define aux_request_irq(hand, dev_id)                                   \
73
        request_irq(AUX_IRQ, hand, SA_SHIRQ, "PS/2 Mouse", dev_id)
74
 
75
#define aux_free_irq(dev_id) free_irq(AUX_IRQ, dev_id)
76
 
77
#endif /* __KERNEL__ */
78
 
79
#endif /* !(_SPARC_KEYBOARD_H) */

powered by: WebSVN 2.1.0

© copyright 1999-2025 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.