Changeset 1875a0c in mainline for uspace/srv/hid/input/ctl/sun.c


Ignore:
Timestamp:
2011-06-21T19:10:20Z (13 years ago)
Author:
Martin Decky <martin@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
022d9f67
Parents:
a9d85df
Message:

input server improvements

  • integrate legacy port mouse drivers (PS/2, ADB) into the input server (to be on par with the legacy keyboard drivers)
  • create generic port/protocol layers for the mouse in the input server
  • rename the "hid_in" namespace to "hid" namespace (hid_in/input was rather redundant)
  • rename the mouse event IPC messages to be more consistent with the keyboard event messages
  • rename input server ops structure members to be more generic (parse_scancode → parse)
  • cstyle changes (newlines, comments, printouts)
File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/srv/hid/input/ctl/sun.c

    ra9d85df r1875a0c  
    3434/**
    3535 * @file
    36  * @brief       Sun keyboard controller driver.
     36 * @brief Sun keyboard controller driver.
    3737 */
    3838
     
    4343#include <kbd_port.h>
    4444
    45 static void sun_ctl_parse_scancode(int);
     45static void sun_ctl_parse(sysarg_t);
    4646static int sun_ctl_init(kbd_dev_t *);
    47 static void sun_ctl_set_ind(kbd_dev_t *, unsigned);
     47static void sun_ctl_set_ind(kbd_dev_t *, unsigned int);
    4848
    4949kbd_ctl_ops_t sun_ctl = {
    50         .parse_scancode = sun_ctl_parse_scancode,
     50        .parse = sun_ctl_parse,
    5151        .init = sun_ctl_init,
    5252        .set_ind = sun_ctl_set_ind
     
    6666}
    6767
    68 static void sun_ctl_parse_scancode(int scancode)
     68static void sun_ctl_parse(sysarg_t scancode)
    6969{
    7070        kbd_event_type_t type;
    7171        unsigned int key;
    7272
    73         if (scancode < 0 || scancode >= 0x100)
     73        if (scancode >= 0x100)
    7474                return;
    7575
     
    8686        key = scanmap_simple[scancode];
    8787        if (key != 0)
    88                 kbd_push_ev(kbd_dev, type, key);
     88                kbd_push_event(kbd_dev, type, key);
    8989}
    9090
Note: See TracChangeset for help on using the changeset viewer.