Lines Matching refs:stinger
33 struct stinger { struct
45 static void stinger_process_packet(struct stinger *stinger) in stinger_process_packet() argument
47 struct input_dev *dev = stinger->dev; in stinger_process_packet()
48 unsigned char *data = stinger->data; in stinger_process_packet()
50 if (!stinger->idx) return; in stinger_process_packet()
80 struct stinger *stinger = serio_get_drvdata(serio); in stinger_interrupt() local
84 if (stinger->idx < STINGER_MAX_LENGTH) in stinger_interrupt()
85 stinger->data[stinger->idx++] = data; in stinger_interrupt()
87 if (stinger->idx == 4) { in stinger_interrupt()
88 stinger_process_packet(stinger); in stinger_interrupt()
89 stinger->idx = 0; in stinger_interrupt()
101 struct stinger *stinger = serio_get_drvdata(serio); in stinger_disconnect() local
105 input_unregister_device(stinger->dev); in stinger_disconnect()
106 kfree(stinger); in stinger_disconnect()
117 struct stinger *stinger; in stinger_connect() local
121 stinger = kmalloc(sizeof(*stinger), GFP_KERNEL); in stinger_connect()
123 if (!stinger || !input_dev) in stinger_connect()
126 stinger->dev = input_dev; in stinger_connect()
127 snprintf(stinger->phys, sizeof(stinger->phys), "%s/serio0", serio->phys); in stinger_connect()
130 input_dev->phys = stinger->phys; in stinger_connect()
145 serio_set_drvdata(serio, stinger); in stinger_connect()
151 err = input_register_device(stinger->dev); in stinger_connect()
160 kfree(stinger); in stinger_connect()