Remove ps2kbdev dev functions in favour of MBus

This commit is contained in:
2025-11-11 23:50:24 +01:00
parent a530304e18
commit ef7a45e7cf
2 changed files with 0 additions and 23 deletions

View File

@ -155,24 +155,6 @@ int32_t ps2kb_intr(void) {
IpcMBus *PS2KB_MBUS;
int32_t ps2kbdev_readch(struct Dev *dev, uint8_t *buffer, size_t len, uint64_t pid) {
(void)dev; (void)buffer; (void)len;
uint8_t b;
int32_t r = ipc_mbusconsume("ps2kb", &b, pid);
if (r > 0) {
return b;
} else {
return E_NOTYET;
}
}
int32_t ps2kbdev_attchcons(struct Dev *dev, uint8_t *buffer, size_t len, uint64_t pid) {
(void)dev; (void)buffer; (void)len;
return ipc_mbusattch("ps2kb", pid);
}
void ps2kbdev_intr(void) {
int32_t c = ps2kb_intr();
if (c >= 0) {
@ -188,6 +170,4 @@ void ps2kbdev_init(void) {
HSHTB_ALLOC(DEVTABLE.devs, ident, "ps2kbdev", ps2kbdev);
spinlock_init(&ps2kbdev->spinlock);
PS2KB_MBUS = ipc_mbusmake("ps2kb", 1, 0x100);
ps2kbdev->fns[DEV_PS2KBDEV_READCH] = &ps2kbdev_readch;
ps2kbdev->fns[DEV_PS2KBDEV_ATTCHCONS] = &ps2kbdev_attchcons;
}

View File

@ -6,9 +6,6 @@
#define DEV_TERMDEV_PUTCH 0
#define DEV_PS2KBDEV_READCH 0
#define DEV_PS2KBDEV_ATTCHCONS 1
#define DEV_SERIALDEV_SENDB 0
#define DEV_SERIALDEV_SENDREADY 1
#define DEV_SERIALDEV_RECVB 2