Changeset 973be64e in mainline for generic/src/console/chardev.c


Ignore:
Timestamp:
2005-12-10T00:19:57Z (19 years ago)
Author:
Ondrej Palkovsky <ondrap@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
fcfac420
Parents:
705b4149
Message:

Added generic exc_register/exc_dispatch functions,
copied from ia32 architecture. Currently only mips32 uses them.

The chardev_t can now be both input & output device (was
needed for serial driver).

Broken other architectures - ia64, sparc, powerpc will not compile.

Mips32 supports input on all msim, gxemul, indy(tested emulation
in gxemul, loses characters), simics. Simics serial line
is done using polling, I was unable to make it produce
an interrupt when the key was pressed.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • generic/src/console/chardev.c

    r705b4149 r973be64e  
    3737 * @param op Implementation of character device operations.
    3838 */
    39 void chardev_initialize(chardev_t *chardev, chardev_operations_t *op)
     39void chardev_initialize(char *name,chardev_t *chardev,
     40                        chardev_operations_t *op)
    4041{
     42        chardev->name = name;
     43
    4144        waitq_initialize(&chardev->wq);
    4245        spinlock_initialize(&chardev->lock, "chardev");
     
    5760        if (chardev->counter == CHARDEV_BUFLEN - 1) {
    5861                /* buffer full => disable device interrupt */
    59                 chardev->op->suspend();
     62                chardev->op->suspend(chardev);
    6063        }
    6164
Note: See TracChangeset for help on using the changeset viewer.