Lines Matching refs:list

49 	struct evdev_list *list;  member
66 struct evdev_list *list = evdev->list; in evdev_event() local
68 while (list) { in evdev_event()
70 do_gettimeofday(&list->buffer[list->head].time); in evdev_event()
71 list->buffer[list->head].type = type; in evdev_event()
72 list->buffer[list->head].code = code; in evdev_event()
73 list->buffer[list->head].value = value; in evdev_event()
74 list->head = (list->head + 1) & (EVDEV_BUFFER_SIZE - 1); in evdev_event()
76 kill_fasync(&list->fasync, SIGIO, POLL_IN); in evdev_event()
78 list = list->next; in evdev_event()
87 struct evdev_list *list = file->private_data; in evdev_fasync() local
88 retval = fasync_helper(fd, file, on, &list->fasync); in evdev_fasync()
94 struct evdev_list *list = file->private_data; in evdev_release() local
98 listptr = &list->evdev->list; in evdev_release()
101 while (*listptr && (*listptr != list)) in evdev_release()
105 if (!--list->evdev->open) { in evdev_release()
106 if (list->evdev->exist) { in evdev_release()
107 input_close_device(&list->evdev->handle); in evdev_release()
109 input_unregister_minor(list->evdev->devfs); in evdev_release()
110 evdev_table[list->evdev->minor] = NULL; in evdev_release()
111 kfree(list->evdev); in evdev_release()
115 kfree(list); in evdev_release()
123 struct evdev_list *list; in evdev_open() local
129 if (!(list = kmalloc(sizeof(struct evdev_list), GFP_KERNEL))) in evdev_open()
131 memset(list, 0, sizeof(struct evdev_list)); in evdev_open()
133 list->evdev = evdev_table[i]; in evdev_open()
134 list->next = evdev_table[i]->list; in evdev_open()
135 evdev_table[i]->list = list; in evdev_open()
137 file->private_data = list; in evdev_open()
139 if (!list->evdev->open++) in evdev_open()
140 if (list->evdev->exist) in evdev_open()
141 input_open_device(&list->evdev->handle); in evdev_open()
148 struct evdev_list *list = file->private_data; in evdev_write() local
156 input_event(list->evdev->handle.dev, event.type, event.code, event.value); in evdev_write()
166 struct evdev_list *list = file->private_data; in evdev_read() local
169 if (list->head == list->tail) { in evdev_read()
171 add_wait_queue(&list->evdev->wait, &wait); in evdev_read()
174 while (list->head == list->tail) { in evdev_read()
176 if (!list->evdev->exist) { in evdev_read()
193 remove_wait_queue(&list->evdev->wait, &wait); in evdev_read()
199 while (list->head != list->tail && retval + sizeof(struct input_event) <= count) { in evdev_read()
200 if (copy_to_user(buffer + retval, list->buffer + list->tail, in evdev_read()
202 list->tail = (list->tail + 1) & (EVDEV_BUFFER_SIZE - 1); in evdev_read()
212 struct evdev_list *list = file->private_data; in evdev_poll() local
213 poll_wait(file, &list->evdev->wait, wait); in evdev_poll()
214 if (list->head != list->tail) in evdev_poll()
221 struct evdev_list *list = file->private_data; in evdev_ioctl() local
222 struct evdev *evdev = list->evdev; in evdev_ioctl()