Changeset a7fdfe1 in mainline


Ignore:
Timestamp:
2005-11-22T21:32:11Z (19 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
2677758
Parents:
1bdaa3f
Message:

Basic keyboard support for mips32 (msim).

Files:
2 added
6 edited

Legend:

Unmodified
Added
Removed
  • arch/ia32/src/drivers/i8042.c

    r1bdaa3f ra7fdfe1  
    5252#define LOCKED_CAPSLOCK         (1<<0)
    5353
    54 static spinlock_t keylock;      /**< keylock protects keyflags and lockflags. */
     54static spinlock_t keylock;              /**< keylock protects keyflags and lockflags. */
    5555static volatile int keyflags;           /**< Tracking of multiple keypresses. */
    56 static volatile int lockflags;          /**< Tracking of multiple lock keys keypresses. */
     56static volatile int lockflags;          /**< Tracking of multiple keys lockings. */
    5757
    5858/** Primary meaning of scancodes. */
  • arch/mips32/Makefile.inc

    r1bdaa3f ra7fdfe1  
    127127        arch/$(ARCH)/src/fpu_context.c \
    128128        arch/$(ARCH)/src/fmath.c \
    129         arch/$(ARCH)/src/drivers/arc.c
     129        arch/$(ARCH)/src/drivers/arc.c \
     130        arch/$(ARCH)/src/drivers/keyboard.c
  • arch/mips32/include/interrupt.h

    r1bdaa3f ra7fdfe1  
    3232#include <arch/exception.h>
    3333
    34 #define TIMER_INTERRUPT   7
     34#define IRQ3    3
     35#define IRQ7    7
     36
     37#define KEYBOARD_IRQ    IRQ3
     38#define TIMER_IRQ       IRQ7
    3539
    3640extern void interrupt(struct exception_regdump *pstate);
  • arch/mips32/src/interrupt.c

    r1bdaa3f ra7fdfe1  
    3636#include <symtab.h>
    3737#include <arch/drivers/arc.h>
     38#include <arch/drivers/keyboard.h>
    3839
    3940static void print_regdump(struct exception_regdump *pstate)
     
    111112                                        break;
    112113                                case 2: /* IRQ0 */
    113                                 case 3: /* IRQ1 */
     114                                case KEYBOARD_IRQ:
     115                                        keyboard();
     116                                        break;
    114117                                case 4: /* IRQ2 */
    115118                                case 5: /* IRQ3 */
     
    119122                                        panic("unhandled interrupt %d\n", i);
    120123                                        break;
    121                                 case TIMER_INTERRUPT:
     124                                case TIMER_IRQ:
    122125                                        /* clear timer interrupt & set new */
    123126                                        cp0_compare_write(cp0_count_read() + cp0_compare_value);
  • arch/mips32/src/mips32.c

    r1bdaa3f ra7fdfe1  
    7575         * Unmask hardware clock interrupt.
    7676         */
    77         cp0_unmask_int(TIMER_INTERRUPT);
     77        cp0_unmask_int(TIMER_IRQ);
    7878
    7979        /*
  • contrib/conf/msim.conf

    r1bdaa3f ra7fdfe1  
    1111
    1212add dprinter printer 0x10000000
     13add dkeyboard keyboard 0x10000004 3
Note: See TracChangeset for help on using the changeset viewer.