Path: blob/master/drivers/input/serio/i8042-ppcio.h
15111 views
#ifndef _I8042_PPCIO_H1#define _I8042_PPCIO_H23/*4* This program is free software; you can redistribute it and/or modify it5* under the terms of the GNU General Public License version 2 as published by6* the Free Software Foundation.7*/89#if defined(CONFIG_WALNUT)1011#define I8042_KBD_IRQ 2512#define I8042_AUX_IRQ 261314#define I8042_KBD_PHYS_DESC "walnutps2/serio0"15#define I8042_AUX_PHYS_DESC "walnutps2/serio1"16#define I8042_MUX_PHYS_DESC "walnutps2/serio%d"1718extern void *kb_cs;19extern void *kb_data;2021#define I8042_COMMAND_REG (*(int *)kb_cs)22#define I8042_DATA_REG (*(int *)kb_data)2324static inline int i8042_read_data(void)25{26return readb(kb_data);27}2829static inline int i8042_read_status(void)30{31return readb(kb_cs);32}3334static inline void i8042_write_data(int val)35{36writeb(val, kb_data);37}3839static inline void i8042_write_command(int val)40{41writeb(val, kb_cs);42}4344static inline int i8042_platform_init(void)45{46i8042_reset = 1;47return 0;48}4950static inline void i8042_platform_exit(void)51{52}5354#else5556#include "i8042-io.h"5758#endif5960#endif /* _I8042_PPCIO_H */616263