Lines Matching refs:hidraw
31 #include <linux/hidraw.h>
36 static struct hidraw *hidraw_table[HIDRAW_MAX_DEVICES];
49 add_wait_queue(&list->hidraw->wait, &wait);
57 if (!list->hidraw->exist) {
74 remove_wait_queue(&list->hidraw->wait, &wait);
252 __poll_t mask = EPOLLOUT | EPOLLWRNORM; /* hidraw is always writable */
254 poll_wait(file, &list->hidraw->wait, wait);
257 if (!list->hidraw->exist)
265 struct hidraw *dev;
297 list->hidraw = hidraw_table[minor];
319 static void drop_ref(struct hidraw *hidraw, int exists_bit)
322 hidraw->exist = 0;
323 if (hidraw->open) {
324 hid_hw_close(hidraw->hid);
325 wake_up_interruptible(&hidraw->wait);
328 MKDEV(hidraw_major, hidraw->minor));
330 --hidraw->open;
332 if (!hidraw->open) {
333 if (!hidraw->exist) {
334 hidraw_table[hidraw->minor] = NULL;
335 kfree(hidraw);
338 hid_hw_close(hidraw->hid);
339 hid_hw_power(hidraw->hid, PM_HINT_NORMAL);
372 struct hidraw *dev;
490 struct hidraw *dev = hid->hidraw;
520 struct hidraw *dev;
524 dev = kzalloc(sizeof(struct hidraw), GFP_KERNEL);
547 NULL, "%s%d", "hidraw", minor);
565 hid->hidraw = dev;
576 struct hidraw *hidraw = hid->hidraw;
580 drop_ref(hidraw, 1);
592 HIDRAW_MAX_DEVICES, "hidraw");
600 hidraw_class = class_create(THIS_MODULE, "hidraw");