Lines Matching refs:xtkbd
57 struct xtkbd {
67 struct xtkbd *xtkbd = serio_get_drvdata(serio);
75 if (xtkbd->keycode[data & XTKBD_KEY]) {
76 input_report_key(xtkbd->dev, xtkbd->keycode[data & XTKBD_KEY], !(data & XTKBD_RELEASE));
77 input_sync(xtkbd->dev);
79 printk(KERN_WARNING "xtkbd.c: Unknown key (scancode %#x) %s.\n",
88 struct xtkbd *xtkbd;
93 xtkbd = kmalloc(sizeof(struct xtkbd), GFP_KERNEL);
95 if (!xtkbd || !input_dev)
98 xtkbd->serio = serio;
99 xtkbd->dev = input_dev;
100 snprintf(xtkbd->phys, sizeof(xtkbd->phys), "%s/input0", serio->phys);
101 memcpy(xtkbd->keycode, xtkbd_keycode, sizeof(xtkbd->keycode));
104 input_dev->phys = xtkbd->phys;
112 input_dev->keycode = xtkbd->keycode;
117 set_bit(xtkbd->keycode[i], input_dev->keybit);
120 serio_set_drvdata(serio, xtkbd);
126 err = input_register_device(xtkbd->dev);
135 kfree(xtkbd);
141 struct xtkbd *xtkbd = serio_get_drvdata(serio);
145 input_unregister_device(xtkbd->dev);
146 kfree(xtkbd);
163 .name = "xtkbd",