Lines Matching refs:wacom_wac
75 memcpy(wacom->wacom_wac.data, raw_data, size); in wacom_raw_event()
77 wacom_wac_irq(&wacom->wacom_wac, size); in wacom_raw_event()
121 struct wacom_features *features = &wacom->wacom_wac.features; in wacom_feature_mapping()
122 struct hid_data *hid_data = &wacom->wacom_wac.hid_data; in wacom_feature_mapping()
164 wacom->wacom_wac.mode_report = field->report->id; in wacom_feature_mapping()
165 wacom->wacom_wac.mode_value = 0; in wacom_feature_mapping()
174 wacom->wacom_wac.mode_report = field->report->id; in wacom_feature_mapping()
175 wacom->wacom_wac.mode_value = 0; in wacom_feature_mapping()
217 struct wacom_features *features = &wacom->wacom_wac.features; in wacom_usage_mapping()
280 struct wacom_wac *wacom_wac = &wacom->wacom_wac; in wacom_post_parse_hid() local
285 input_mt_init_slots(wacom_wac->touch_input, wacom_wac->features.touch_max, in wacom_post_parse_hid()
332 struct hid_data *hid_data = &wacom->wacom_wac.hid_data; in wacom_hid_set_device_mode()
349 struct wacom_wac *wacom_wac) in wacom_set_device_mode() argument
357 if (wacom_wac->mode_report < 0) in wacom_set_device_mode()
361 r = re->report_id_hash[wacom_wac->mode_report]; in wacom_set_device_mode()
372 rep_data[0] = wacom_wac->mode_report; in wacom_set_device_mode()
373 rep_data[1] = wacom_wac->mode_value; in wacom_set_device_mode()
381 rep_data[1] != wacom_wac->mode_report && in wacom_set_device_mode()
411 wacom->wacom_wac.bt_high_speed = speed; in wacom_bt_query_tablet_data()
425 wacom->wacom_wac.bt_features &= ~0x20; in wacom_bt_query_tablet_data()
427 wacom->wacom_wac.bt_features |= 0x20; in wacom_bt_query_tablet_data()
430 rep_data[1] = wacom->wacom_wac.bt_features; in wacom_bt_query_tablet_data()
435 wacom->wacom_wac.bt_high_speed = speed; in wacom_bt_query_tablet_data()
453 struct wacom_wac *wacom_wac = &wacom->wacom_wac; in wacom_query_tablet_data() local
462 wacom_wac->mode_report = 3; in wacom_query_tablet_data()
463 wacom_wac->mode_value = 4; in wacom_query_tablet_data()
465 wacom_wac->mode_report = 18; in wacom_query_tablet_data()
466 wacom_wac->mode_value = 2; in wacom_query_tablet_data()
468 wacom_wac->mode_report = 131; in wacom_query_tablet_data()
469 wacom_wac->mode_value = 2; in wacom_query_tablet_data()
471 wacom_wac->mode_report = 2; in wacom_query_tablet_data()
472 wacom_wac->mode_value = 2; in wacom_query_tablet_data()
476 wacom_wac->mode_report = 2; in wacom_query_tablet_data()
477 wacom_wac->mode_value = 2; in wacom_query_tablet_data()
482 wacom_set_device_mode(hdev, wacom_wac); in wacom_query_tablet_data()
546 struct wacom_features *features = &wacom->wacom_wac.features; in wacom_are_sibling()
548 struct wacom_features *sibling_features = &sibling_wacom->wacom_wac.features; in wacom_are_sibling()
647 struct wacom_wac *wacom_wac = &wacom->wacom_wac; in wacom_remove_shared_data() local
649 if (wacom_wac->shared) { in wacom_remove_shared_data()
650 data = container_of(wacom_wac->shared, struct wacom_hdev_data, in wacom_remove_shared_data()
653 if (wacom_wac->shared->touch == wacom->hdev) in wacom_remove_shared_data()
654 wacom_wac->shared->touch = NULL; in wacom_remove_shared_data()
655 else if (wacom_wac->shared->pen == wacom->hdev) in wacom_remove_shared_data()
656 wacom_wac->shared->pen = NULL; in wacom_remove_shared_data()
659 wacom_wac->shared = NULL; in wacom_remove_shared_data()
666 struct wacom_wac *wacom_wac = &wacom->wacom_wac; in wacom_add_shared_data() local
685 wacom_wac->shared = &data->shared; in wacom_add_shared_data()
694 if (wacom_wac->features.device_type & WACOM_DEVICETYPE_TOUCH) in wacom_add_shared_data()
695 wacom_wac->shared->touch = hdev; in wacom_add_shared_data()
696 else if (wacom_wac->features.device_type & WACOM_DEVICETYPE_PEN) in wacom_add_shared_data()
697 wacom_wac->shared->pen = hdev; in wacom_add_shared_data()
717 if (wacom->wacom_wac.features.type == REMOTE) in wacom_led_control()
720 if (wacom->wacom_wac.pid) { /* wireless connected */ in wacom_led_control()
728 if (wacom->wacom_wac.features.type >= INTUOS5S && in wacom_led_control()
729 wacom->wacom_wac.features.type <= INTUOSPL) { in wacom_led_control()
741 if (wacom->wacom_wac.pid) { in wacom_led_control()
752 if (wacom->wacom_wac.features.type == WACOM_21UX2 || in wacom_led_control()
753 wacom->wacom_wac.features.type == WACOM_24HD) in wacom_led_control()
1290 if (!wacom->wacom_wac.pad_input) in wacom_leds_alloc_and_register()
1293 dev = &wacom->wacom_wac.pad_input->dev; in wacom_leds_alloc_and_register()
1314 if (!(wacom->wacom_wac.features.device_type & WACOM_DEVICETYPE_PAD)) in wacom_initialize_leds()
1318 switch (wacom->wacom_wac.features.type) { in wacom_initialize_leds()
1419 val->strval = battery->wacom->wacom_wac.name; in wacom_battery_get_property()
1495 if (wacom->wacom_wac.features.quirks & WACOM_QUIRK_BATTERY) in wacom_initialize_battery()
1517 return snprintf(buf, PAGE_SIZE, "%i\n", wacom->wacom_wac.bt_high_speed); in wacom_show_speed()
1534 wacom_bt_query_tablet_data(hdev, new_speed, &wacom->wacom_wac.features); in wacom_store_speed()
1684 if (wacom->wacom_wac.features.type != REMOTE) in wacom_initialize_remotes()
1740 struct wacom_wac *wacom_wac = &(wacom->wacom_wac); in wacom_allocate_input() local
1746 input_dev->name = wacom_wac->features.name; in wacom_allocate_input()
1754 input_dev->id.product = wacom_wac->pid ? wacom_wac->pid : hdev->product; in wacom_allocate_input()
1763 struct wacom_wac *wacom_wac = &(wacom->wacom_wac); in wacom_allocate_inputs() local
1765 wacom_wac->pen_input = wacom_allocate_input(wacom); in wacom_allocate_inputs()
1766 wacom_wac->touch_input = wacom_allocate_input(wacom); in wacom_allocate_inputs()
1767 wacom_wac->pad_input = wacom_allocate_input(wacom); in wacom_allocate_inputs()
1768 if (!wacom_wac->pen_input || in wacom_allocate_inputs()
1769 !wacom_wac->touch_input || in wacom_allocate_inputs()
1770 !wacom_wac->pad_input) in wacom_allocate_inputs()
1773 wacom_wac->pen_input->name = wacom_wac->pen_name; in wacom_allocate_inputs()
1774 wacom_wac->touch_input->name = wacom_wac->touch_name; in wacom_allocate_inputs()
1775 wacom_wac->pad_input->name = wacom_wac->pad_name; in wacom_allocate_inputs()
1783 struct wacom_wac *wacom_wac = &(wacom->wacom_wac); in wacom_register_inputs() local
1786 pen_input_dev = wacom_wac->pen_input; in wacom_register_inputs()
1787 touch_input_dev = wacom_wac->touch_input; in wacom_register_inputs()
1788 pad_input_dev = wacom_wac->pad_input; in wacom_register_inputs()
1793 error = wacom_setup_pen_input_capabilities(pen_input_dev, wacom_wac); in wacom_register_inputs()
1797 wacom_wac->pen_input = NULL; in wacom_register_inputs()
1805 error = wacom_setup_touch_input_capabilities(touch_input_dev, wacom_wac); in wacom_register_inputs()
1809 wacom_wac->touch_input = NULL; in wacom_register_inputs()
1817 error = wacom_setup_pad_input_capabilities(pad_input_dev, wacom_wac); in wacom_register_inputs()
1821 wacom_wac->pad_input = NULL; in wacom_register_inputs()
1832 wacom_wac->pad_input = NULL; in wacom_register_inputs()
1833 wacom_wac->touch_input = NULL; in wacom_register_inputs()
1834 wacom_wac->pen_input = NULL; in wacom_register_inputs()
1875 if ((wacom->wacom_wac.features.quirks & WACOM_QUIRK_BATTERY) && in wacom_battery_work()
1879 else if (!(wacom->wacom_wac.features.quirks & WACOM_QUIRK_BATTERY) && in wacom_battery_work()
1904 struct wacom_wac *wacom_wac = &wacom->wacom_wac; in wacom_update_name() local
1905 struct wacom_features *features = &wacom_wac->features; in wacom_update_name()
1936 snprintf(wacom_wac->name, sizeof(wacom_wac->name), "%s%s", in wacom_update_name()
1940 snprintf(wacom_wac->pen_name, sizeof(wacom_wac->pen_name), in wacom_update_name()
1942 snprintf(wacom_wac->touch_name, sizeof(wacom_wac->touch_name), in wacom_update_name()
1944 snprintf(wacom_wac->pad_name, sizeof(wacom_wac->pad_name), in wacom_update_name()
1959 wacom->wacom_wac.pen_input = NULL; in wacom_release_resources()
1960 wacom->wacom_wac.touch_input = NULL; in wacom_release_resources()
1961 wacom->wacom_wac.pad_input = NULL; in wacom_release_resources()
1966 struct wacom_wac *wacom_wac = &wacom->wacom_wac; in wacom_parse_and_register() local
1967 struct wacom_features *features = &wacom_wac->features; in wacom_parse_and_register()
2048 if (wacom->wacom_wac.features.device_type & WACOM_DEVICETYPE_PAD) { in wacom_parse_and_register()
2083 if ((wacom_wac->features.type == INTUOSHT || in wacom_parse_and_register()
2084 wacom_wac->features.type == INTUOSHT2) && in wacom_parse_and_register()
2085 (wacom_wac->features.device_type & WACOM_DEVICETYPE_TOUCH)) { in wacom_parse_and_register()
2086 wacom_wac->shared->type = wacom_wac->features.type; in wacom_parse_and_register()
2087 wacom_wac->shared->touch_input = wacom_wac->touch_input; in wacom_parse_and_register()
2105 struct wacom_wac *wacom_wac = &wacom->wacom_wac; in wacom_wireless_work() local
2108 struct wacom_wac *wacom_wac1, *wacom_wac2; in wacom_wireless_work()
2121 wacom_wac1 = &(wacom1->wacom_wac); in wacom_wireless_work()
2127 wacom_wac2 = &(wacom2->wacom_wac); in wacom_wireless_work()
2130 if (wacom_wac->pid == 0) { in wacom_wireless_work()
2136 wacom_wac->pid); in wacom_wireless_work()
2140 id->product == wacom_wac->pid) in wacom_wireless_work()
2154 wacom_wac1->pid = wacom_wac->pid; in wacom_wireless_work()
2166 wacom_wac2->pid = wacom_wac->pid; in wacom_wireless_work()
2173 strlcpy(wacom_wac->name, wacom_wac1->name, in wacom_wireless_work()
2174 sizeof(wacom_wac->name)); in wacom_wireless_work()
2251 remote->remotes[index].input->name = wacom->wacom_wac.pad_name; in wacom_remote_create_one()
2259 &wacom->wacom_wac); in wacom_remote_create_one()
2330 wacom_schedule_work(&wacom->wacom_wac, WACOM_WORKER_REMOTE); in wacom_remote_work()
2360 struct wacom_wac *wacom_wac; in wacom_probe() local
2379 wacom_wac = &wacom->wacom_wac; in wacom_probe()
2380 wacom_wac->features = *((struct wacom_features *)id->driver_data); in wacom_probe()
2381 features = &wacom_wac->features; in wacom_probe()
2388 wacom_wac->hid_data.inputmode = -1; in wacom_probe()
2389 wacom_wac->mode_report = -1; in wacom_probe()
2427 struct wacom_wac *wacom_wac = &wacom->wacom_wac; in wacom_remove() local
2428 struct wacom_features *features = &wacom_wac->features; in wacom_remove()
2450 struct wacom_features *features = &wacom->wacom_wac.features; in wacom_resume()