Changeset 797ab95 in mainline for uspace/drv/char/i8042/i8042.c


Ignore:
Timestamp:
2025-03-07T22:35:36Z (3 days ago)
Author:
Jiri Svoboda <jiri@…>
Branches:
master
Children:
0ae9e18
Parents:
b9cc81c6
Message:

Implement quiesce in i8042.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/char/i8042/i8042.c

    rb9cc81c6 r797ab95  
    11/*
     2 * Copyright (c) 2025 Jiri Svoboda
    23 * Copyright (c) 2001-2004 Jakub Jermar
    34 * Copyright (c) 2006 Josef Cejka
    4  * Copyright (c) 2021 Jiri Svoboda
    55 * Copyright (c) 2011 Jan Vesely
    66 * All rights reserved.
     
    346346}
    347347
     348/** Quiesce i8042.
     349 *
     350 * @param dev i8042 instance.
     351 */
     352void i8042_quiesce(i8042_t *dev)
     353{
     354        /* Disable port interrupts. */
     355        wait_ready(dev);
     356        pio_write_8(&dev->regs->status, i8042_CMD_WRITE_CMDB);
     357        wait_ready(dev);
     358        pio_write_8(&dev->regs->data, i8042_KBD_TRANSLATE);
     359}
     360
    348361/** Write data to i8042 port.
    349362 *
Note: See TracChangeset for help on using the changeset viewer.