Changeset 6a44ee4 in mainline for uspace/srv/hid/input/ctl/gxe_fb.c


Ignore:
Timestamp:
2011-07-20T15:26:21Z (13 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
efcebe1
Parents:
25bef0ff (diff), a701812 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Merge mainline changes.

File:
1 moved

Legend:

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

    r25bef0ff r6a44ee4  
    11/*
    2  * Copyright (c) 2009 Jiri Svoboda
     2 * Copyright (c) 2011 Jiri Svoboda
    33 * All rights reserved.
    44 *
     
    2828
    2929/** @addtogroup kbd_ctl
    30  * @ingroup kbd
     30 * @ingroup input
    3131 * @{
    3232 */
     
    4040#include <io/keycode.h>
    4141#include <kbd_ctl.h>
     42#include <kbd_port.h>
    4243#include <gsp.h>
    4344#include <stroke.h>
    4445
     46static void gxe_fb_ctl_parse(sysarg_t);
     47static int gxe_fb_ctl_init(kbd_dev_t *);
     48static void gxe_fb_ctl_set_ind(kbd_dev_t *, unsigned int);
     49
     50kbd_ctl_ops_t gxe_fb_ctl = {
     51        .parse = gxe_fb_ctl_parse,
     52        .init = gxe_fb_ctl_init,
     53        .set_ind = gxe_fb_ctl_set_ind
     54};
     55
     56static kbd_dev_t *kbd_dev;
     57
    4558/** Scancode parser */
    4659static gsp_t sp;
     
    5164#include <stdio.h>
    5265
    53 int seq_defs[] = {
     66static int seq_defs[] = {
    5467        /* Not shifted */
    5568
     
    207220};
    208221
    209 int kbd_ctl_init(void)
     222static int gxe_fb_ctl_init(kbd_dev_t *kdev)
    210223{
     224        kbd_dev = kdev;
    211225        ds = 0;
    212226
     
    215229}
    216230
    217 void kbd_ctl_parse_scancode(int scancode)
     231static void gxe_fb_ctl_parse(sysarg_t scancode)
    218232{
    219233        unsigned mods, key;
     
    221235        ds = gsp_step(&sp, ds, scancode, &mods, &key);
    222236        if (key != 0) {
    223                 stroke_sim(mods, key);
     237                stroke_sim(kbd_dev, mods, key);
    224238        }
    225239}
    226240
    227 void kbd_ctl_set_ind(unsigned mods)
     241static void gxe_fb_ctl_set_ind(kbd_dev_t *kdev, unsigned mods)
    228242{
    229243        (void) mods;
Note: See TracChangeset for help on using the changeset viewer.