Lines Matching refs:interact
37 struct interact { struct
114 struct interact *interact = gameport_get_drvdata(gameport); in interact_poll() local
115 struct input_dev *dev = interact->dev; in interact_poll()
119 interact->reads++; in interact_poll()
121 if (interact_read_packet(interact->gameport, interact->length, data) < interact->length) { in interact_poll()
122 interact->bads++; in interact_poll()
126 data[i] <<= INTERACT_MAX_LENGTH - interact->length; in interact_poll()
128 switch (interact->type) { in interact_poll()
169 struct interact *interact = input_get_drvdata(dev); in interact_open() local
171 gameport_start_polling(interact->gameport); in interact_open()
181 struct interact *interact = input_get_drvdata(dev); in interact_close() local
183 gameport_stop_polling(interact->gameport); in interact_close()
192 struct interact *interact; in interact_connect() local
198 interact = kzalloc(sizeof(struct interact), GFP_KERNEL); in interact_connect()
200 if (!interact || !input_dev) { in interact_connect()
205 interact->gameport = gameport; in interact_connect()
206 interact->dev = input_dev; in interact_connect()
208 gameport_set_drvdata(gameport, interact); in interact_connect()
235 snprintf(interact->phys, sizeof(interact->phys), "%s/input0", gameport->phys); in interact_connect()
237 interact->type = i; in interact_connect()
238 interact->length = interact_type[i].length; in interact_connect()
241 input_dev->phys = interact->phys; in interact_connect()
248 input_set_drvdata(input_dev, interact); in interact_connect()
255 for (i = 0; (t = interact_type[interact->type].abs[i]) >= 0; i++) { in interact_connect()
256 if (i < interact_type[interact->type].b8) in interact_connect()
262 for (i = 0; (t = interact_type[interact->type].btn[i]) >= 0; i++) in interact_connect()
265 err = input_register_device(interact->dev); in interact_connect()
274 kfree(interact); in interact_connect()
280 struct interact *interact = gameport_get_drvdata(gameport); in interact_disconnect() local
282 input_unregister_device(interact->dev); in interact_disconnect()
285 kfree(interact); in interact_disconnect()