/linux/drivers/hid/ |
H A D | hid-samsung.c | 85 hid_map_usage_clear(hi, usage, bit, max, EV_KEY, (c)) 88 struct hid_input *hi, struct hid_field *field, struct hid_usage *usage, in samsung_kbd_mouse_input_mapping() argument 94 if (ifnum != 1 || HID_UP_CONSUMER != (usage->hid & HID_USAGE_PAGE)) in samsung_kbd_mouse_input_mapping() 98 usage->hid & HID_USAGE); in samsung_kbd_mouse_input_mapping() 100 switch (usage->hid & HID_USAGE) { in samsung_kbd_mouse_input_mapping() 143 struct hid_input *hi, struct hid_field *field, struct hid_usage *usage, in samsung_kbd_input_mapping() argument 146 if (!(HID_UP_CONSUMER == (usage->hid & HID_USAGE_PAGE) || in samsung_kbd_input_mapping() 147 HID_UP_KEYBOARD == (usage->hid & HID_USAGE_PAGE))) in samsung_kbd_input_mapping() 151 usage->hid & HID_USAGE); in samsung_kbd_input_mapping() 153 if (HID_UP_KEYBOARD == (usage->hid & HID_USAGE_PAGE)) { in samsung_kbd_input_mapping() [all …]
|
H A D | hid-input.c | 52 __u32 usage; /* the HID usage associated */ member 80 .usage = HID_DG_ERASER, 83 .usage = HID_DG_INVERT, 86 .usage = HID_DG_TIPSWITCH, 89 .usage = HID_DG_TIPPRESSURE, 92 .usage = HID_DG_INRANGE, 96 #define map_abs(c) hid_map_usage(hidinput, usage, &bit, &max, EV_ABS, (c)) 97 #define map_rel(c) hid_map_usage(hidinput, usage, &bit, &max, EV_REL, (c)) 98 #define map_key(c) hid_map_usage(hidinput, usage, &bit, &max, EV_KEY, (c)) 99 #define map_led(c) hid_map_usage(hidinput, usage, &bit, &max, EV_LED, (c)) [all …]
|
H A D | hid-lenovo.c | 63 #define map_key_clear(c) hid_map_usage_clear(hi, usage, bit, max, EV_KEY, (c)) 171 struct hid_usage *usage, unsigned long **bit, int *max) in lenovo_input_mapping_tpkbd() argument 173 if (usage->hid == (HID_UP_BUTTON | 0x0010)) { in lenovo_input_mapping_tpkbd() 184 struct hid_usage *usage, unsigned long **bit, int *max) in lenovo_input_mapping_cptkbd() argument 187 if ((usage->hid & HID_USAGE_PAGE) == HID_UP_MSVENDOR || in lenovo_input_mapping_cptkbd() 188 (usage->hid & HID_USAGE_PAGE) == HID_UP_LNVENDOR) { in lenovo_input_mapping_cptkbd() 189 switch (usage->hid & HID_USAGE) { in lenovo_input_mapping_cptkbd() 225 if (usage->hid == HID_GD_WHEEL) in lenovo_input_mapping_cptkbd() 227 if ((usage->hid & HID_USAGE_PAGE) == HID_UP_BUTTON && in lenovo_input_mapping_cptkbd() 228 (usage->hid & HID_USAGE) == 0x003) in lenovo_input_mapping_cptkbd() [all …]
|
H A D | hid-a4tech.c | 35 struct hid_field *field, struct hid_usage *usage, in a4_input_mapping() argument 41 usage->hid == A4_WHEEL_ORIENTATION) { in a4_input_mapping() 57 struct hid_field *field, struct hid_usage *usage, in a4_input_mapped() argument 62 if (usage->type == EV_REL && usage->code == REL_WHEEL_HI_RES) { in a4_input_mapped() 67 if ((a4->quirks & A4_2WHEEL_MOUSE_HACK_7) && usage->hid == 0x00090007) in a4_input_mapped() 74 struct hid_usage *usage, __s32 value) in a4_event() argument 85 if (usage->type == EV_REL && usage->code == REL_WHEEL_HI_RES) { in a4_event() 90 if (usage->hid == A4_WHEEL_ORIENTATION) { in a4_event() 99 if ((a4->quirks & A4_2WHEEL_MOUSE_HACK_7) && usage->hid == 0x00090007) { in a4_event() 104 if (usage->code == REL_WHEEL_HI_RES && a4->hw_wheel) { in a4_event() [all …]
|
H A D | hid-gyration.c | 22 #define gy_map_key_clear(c) hid_map_usage_clear(hi, usage, bit, max, \ 25 struct hid_field *field, struct hid_usage *usage, in gyration_input_mapping() argument 28 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_LOGIVENDOR) in gyration_input_mapping() 32 switch (usage->hid & HID_USAGE) { in gyration_input_mapping() 55 struct hid_usage *usage, __s32 value) in gyration_event() argument 61 if ((usage->hid & HID_USAGE_PAGE) == HID_UP_GENDESK && in gyration_event() 62 (usage->hid & 0xff) == 0x82) { in gyration_event() 64 input_event(input, usage->type, usage->code, 1); in gyration_event() 66 input_event(input, usage->type, usage->code, 0); in gyration_event()
|
H A D | hid-ezkey.c | 22 #define ez_map_rel(c) hid_map_usage(hi, usage, bit, max, EV_REL, (c)) 23 #define ez_map_key(c) hid_map_usage(hi, usage, bit, max, EV_KEY, (c)) 26 struct hid_field *field, struct hid_usage *usage, in ez_input_mapping() argument 29 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_CONSUMER) in ez_input_mapping() 32 switch (usage->hid & HID_USAGE) { in ez_input_mapping() 48 struct hid_usage *usage, __s32 value) in ez_event() argument 51 !usage->type) in ez_event() 55 if (usage->type == EV_REL && usage->code == REL_HWHEEL) { in ez_event() 57 input_event(input, usage->type, REL_WHEEL, -value); in ez_event()
|
H A D | hid-icade.c | 165 struct hid_usage *usage, __s32 value) in icade_event() argument 170 !usage->type) in icade_event() 177 trans = icade_find_translation(usage->hid & HID_USAGE); in icade_event() 182 input_event(field->hidinput->input, usage->type, in icade_event() 189 struct hid_field *field, struct hid_usage *usage, in icade_input_mapping() argument 194 if ((usage->hid & HID_USAGE_PAGE) == HID_UP_KEYBOARD) { in icade_input_mapping() 195 trans = icade_find_translation(usage->hid & HID_USAGE); in icade_input_mapping() 200 hid_map_usage(hi, usage, bit, max, EV_KEY, trans->to); in icade_input_mapping() 212 struct hid_field *field, struct hid_usage *usage, in icade_input_mapped() argument 215 if (usage->type == EV_KEY) in icade_input_mapped() [all …]
|
H A D | hid-microsoft.c | 78 #define ms_map_key_clear(c) hid_map_usage_clear(hi, usage, bit, max, \ 80 static int ms_ergonomy_kb_quirk(struct hid_input *hi, struct hid_usage *usage, in ms_ergonomy_kb_quirk() argument 85 if ((usage->hid & HID_USAGE_PAGE) == HID_UP_CONSUMER) { in ms_ergonomy_kb_quirk() 86 switch (usage->hid & HID_USAGE) { in ms_ergonomy_kb_quirk() 101 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_MSVENDOR) in ms_ergonomy_kb_quirk() 104 switch (usage->hid & HID_USAGE) { in ms_ergonomy_kb_quirk() 115 hid_map_usage_clear(hi, usage, bit, max, EV_REL, REL_WHEEL); in ms_ergonomy_kb_quirk() 142 static int ms_presenter_8k_quirk(struct hid_input *hi, struct hid_usage *usage, in ms_presenter_8k_quirk() argument 145 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_MSVENDOR) in ms_presenter_8k_quirk() 149 switch (usage->hid & HID_USAGE) { in ms_presenter_8k_quirk() [all …]
|
H A D | hid-lg.c | 535 #define lg_map_key_clear(c) hid_map_usage_clear(hi, usage, bit, max, \ 539 struct hid_usage *usage, unsigned long **bit, int *max) in lg_ultrax_remote_mapping() argument 541 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_LOGIVENDOR) in lg_ultrax_remote_mapping() 545 switch (usage->hid & HID_USAGE) { in lg_ultrax_remote_mapping() 571 static int lg_wireless_mapping(struct hid_input *hi, struct hid_usage *usage, in lg_wireless_mapping() argument 574 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_CONSUMER) in lg_wireless_mapping() 577 switch (usage->hid & HID_USAGE) { in lg_wireless_mapping() 633 struct hid_field *field, struct hid_usage *usage, in lg_input_mapping() argument 649 unsigned int hid = usage->hid; in lg_input_mapping() 652 lg_ultrax_remote_mapping(hi, usage, bit, max)) in lg_input_mapping() [all …]
|
H A D | hid-multitouch.c | 494 struct hid_field *field, struct hid_usage *usage) in mt_feature_mapping() argument 498 switch (usage->hid) { in mt_feature_mapping() 512 if (usage->usage_index >= field->report_count) { in mt_feature_mapping() 518 if (field->value[usage->usage_index] == MT_BUTTONTYPE_CLICKPAD) in mt_feature_mapping() 524 if (usage->usage_index == 0) in mt_feature_mapping() 543 struct mt_usages *usage; in mt_allocate_usage() local 545 usage = devm_kzalloc(&hdev->dev, sizeof(*usage), GFP_KERNEL); in mt_allocate_usage() 546 if (!usage) in mt_allocate_usage() 550 usage->x = DEFAULT_ZERO; in mt_allocate_usage() 551 usage->y = DEFAULT_ZERO; in mt_allocate_usage() [all …]
|
H A D | hid-jabra.c | 22 struct hid_usage *usage, in jabra_input_mapping() argument 26 ((usage->hid & HID_USAGE_PAGE) >= HID_UP_VENDOR_DEFINED_MIN && in jabra_input_mapping() 27 (usage->hid & HID_USAGE_PAGE) <= HID_UP_VENDOR_DEFINED_MAX); in jabra_input_mapping() 30 usage->hid, in jabra_input_mapping() 32 usage->collection_index, in jabra_input_mapping() 33 usage->usage_index, in jabra_input_mapping()
|
H A D | hid-ite.c | 43 struct hid_usage *usage, unsigned long **bit, in ite_input_mapping() argument 50 (usage->hid & HID_USAGE_PAGE) == 0x00880000) { in ite_input_mapping() 51 if (usage->hid == 0x00880078) { in ite_input_mapping() 53 hid_map_usage_clear(hi, usage, bit, max, EV_KEY, KEY_F22); in ite_input_mapping() 56 if (usage->hid == 0x00880079) { in ite_input_mapping() 58 hid_map_usage_clear(hi, usage, bit, max, EV_KEY, KEY_F23); in ite_input_mapping() 68 struct hid_usage *usage, __s32 value) in ite_event() argument 82 if (usage->hid == HID_GD_RFKILL_BTN) { in ite_event()
|
H A D | hid-cypress.c | 84 struct hid_field *field, struct hid_usage *usage, in cp_input_mapped() argument 92 if (usage->type == EV_REL && usage->code == REL_WHEEL) in cp_input_mapped() 94 if (usage->hid == 0x00090005) in cp_input_mapped() 101 struct hid_usage *usage, __s32 value) in cp_event() argument 106 !usage->type || !(quirks & CP_2WHEEL_MOUSE_HACK)) in cp_event() 109 if (usage->hid == 0x00090005) { in cp_event() 118 if (usage->code == REL_WHEEL && (quirks & CP_2WHEEL_MOUSE_HACK_ON)) { in cp_event() 121 input_event(input, usage->type, REL_HWHEEL, value); in cp_event()
|
H A D | hid-plantronics.c | 38 (usage->hid & HID_USAGE_PAGE) == HID_UP_CONSUMER) 55 struct hid_usage *usage, in plantronics_input_mapping() argument 89 switch (usage->hid) { in plantronics_input_mapping() 112 usage->hid, field->application); in plantronics_input_mapping() 116 hid_map_usage_clear(hi, usage, bit, max, EV_KEY, mapped_key); in plantronics_input_mapping() 118 usage->hid, field->application, mapped_key); in plantronics_input_mapping() 123 struct hid_usage *usage, __s32 value) in plantronics_event() argument 172 col_page = hdev->collection[i].usage & HID_USAGE_PAGE; in plantronics_device_type() 174 plt_type = hdev->collection[i].usage; in plantronics_device_type() 178 plt_type = hdev->collection[i].usage; in plantronics_device_type()
|
H A D | hid-evision.c | 18 struct hid_field *field, struct hid_usage *usage, in evision_input_mapping() argument 21 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_CONSUMER) in evision_input_mapping() 25 if ((usage->hid & HID_USAGE) >> 8 == 0x05) in evision_input_mapping() 28 if ((usage->hid & HID_USAGE) >> 8 == 0x06) in evision_input_mapping() 31 switch (usage->hid & HID_USAGE) { in evision_input_mapping()
|
H A D | hid-petalynx.c | 35 #define pl_map_key_clear(c) hid_map_usage_clear(hi, usage, bit, max, \ 38 struct hid_field *field, struct hid_usage *usage, in pl_input_mapping() argument 41 if ((usage->hid & HID_USAGE_PAGE) == HID_UP_LOGIVENDOR) { in pl_input_mapping() 42 switch (usage->hid & HID_USAGE) { in pl_input_mapping() 54 if ((usage->hid & HID_USAGE_PAGE) == HID_UP_CONSUMER) { in pl_input_mapping() 55 switch (usage->hid & HID_USAGE) { in pl_input_mapping()
|
H A D | hid-corsair.c | 48 static int corsair_usage_to_gkey(unsigned int usage) in corsair_usage_to_gkey() argument 51 if (usage >= 0xd0 && usage <= 0xdf) in corsair_usage_to_gkey() 52 return usage - 0xd0 + 1; in corsair_usage_to_gkey() 54 if (usage >= 0xe8 && usage <= 0xe9) in corsair_usage_to_gkey() 55 return usage - 0xe8 + 17; in corsair_usage_to_gkey() 606 struct hid_usage *usage, __s32 value) in corsair_event() argument 613 switch (usage->hid & HID_USAGE) { in corsair_event() 630 struct hid_usage *usage, unsigned long **bit, in corsair_input_mapping() argument 635 if ((usage->hid & HID_USAGE_PAGE) != HID_UP_KEYBOARD) in corsair_input_mapping() 638 gkey = corsair_usage_to_gkey(usage->hid & HID_USAGE); in corsair_input_mapping() [all …]
|
/linux/tools/verification/rv/src/ |
H A D | rv.c | 42 static const char *const usage[] = { in rv_list() local 57 for (i = 0; usage[i]; i++) in rv_list() 58 fprintf(stderr, "%s\n", usage[i]); in rv_list() 79 static const char *const usage[] = { in rv_mon() local 97 for (i = 0; usage[i]; i++) in rv_mon() 98 fprintf(stderr, "%s\n", usage[i]); in rv_mon() 104 for (i = 0; usage[i]; i++) in rv_mon() 105 fprintf(stderr, "%s\n", usage[i]); in rv_mon() 121 static void usage(int exit_val, const char *fmt, ...) in usage() function 127 static const char *const usage[] = { in usage() local [all …]
|
/linux/mm/ |
H A D | page_counter.c | 22 unsigned long usage) in propagate_protected_usage() argument 30 protected = min(usage, READ_ONCE(c->min)); in propagate_protected_usage() 39 protected = min(usage, READ_ONCE(c->low)); in propagate_protected_usage() 58 new = atomic_long_sub_return(nr_pages, &counter->usage); in page_counter_cancel() 63 atomic_long_set(&counter->usage, new); in page_counter_cancel() 84 new = atomic_long_add_return(nr_pages, &c->usage); in page_counter_charge() 141 new = atomic_long_add_return(nr_pages, &c->usage); in page_counter_try_charge() 143 atomic_long_sub(nr_pages, &c->usage); in page_counter_try_charge() 199 long usage; in page_counter_set_max() local 212 usage = page_counter_read(counter); in page_counter_set_max() [all …]
|
H A D | sparse.c | 205 subsection_mask_set(ms->usage->subsection_map, pfn, pfns); in subsection_map_init() 299 struct mem_section_usage *usage, unsigned long flags) in sparse_init_one_section() argument 304 ms->usage = usage; in sparse_init_one_section() 332 struct mem_section_usage *usage; in sparse_early_usemaps_alloc_pgdat_section() local 349 usage = memblock_alloc_try_nid(size, SMP_CACHE_BYTES, goal, limit, nid); in sparse_early_usemaps_alloc_pgdat_section() 350 if (!usage && limit) { in sparse_early_usemaps_alloc_pgdat_section() 354 return usage; in sparse_early_usemaps_alloc_pgdat_section() 358 struct mem_section_usage *usage) in check_usemap_section_nr() argument 372 usemap_snr = pfn_to_section_nr(__pa(usage) >> PAGE_SHIF in check_usemap_section_nr() 408 check_usemap_section_nr(int nid,struct mem_section_usage * usage) check_usemap_section_nr() argument 509 struct mem_section_usage *usage; sparse_init_nid() local 836 struct mem_section_usage *usage = NULL; section_activate() local [all...] |
H A D | bootmem_info.c | 49 struct mem_section_usage *usage; in register_page_bootmem_info_section() 69 usage = ms->usage; in register_page_bootmem_info_section() 70 page = virt_to_page(usage); in register_page_bootmem_info_section() 84 struct mem_section_usage *usage; in register_page_bootmem_info_section() 93 usage = ms->usage; in register_page_bootmem_info_section() 94 page = virt_to_page(usage); in register_page_bootmem_info_section() 48 struct mem_section_usage *usage; register_page_bootmem_info_section() local 83 struct mem_section_usage *usage; register_page_bootmem_info_section() local
|
/linux/drivers/dma-buf/ |
H A D | st-dma-resv.c | 65 enum dma_resv_usage usage = (unsigned long)arg; in test_signaling() local 89 dma_resv_add_fence(&resv, f, usage); in test_signaling() 90 if (dma_resv_test_signaled(&resv, usage)) { in test_signaling() 96 if (!dma_resv_test_signaled(&resv, usage)) { in test_signaling() 111 enum dma_resv_usage usage = (unsigned long)arg; in test_for_each() local 136 dma_resv_add_fence(&resv, f, usage); in test_for_each() 139 dma_resv_for_each_fence(&cursor, &resv, usage, fence) { in test_for_each() 150 if (dma_resv_iter_usage(&cursor) != usage) { in test_for_each() 172 enum dma_resv_usage usage = (unsigned long)arg; in test_for_each_unlocked() local 198 dma_resv_add_fence(&resv, f, usage); in test_for_each_unlocked() [all …]
|
H A D | dma-resv.c | 72 enum dma_resv_usage *usage) in dma_resv_list_entry() argument 79 if (usage) in dma_resv_list_entry() 80 *usage = tmp & DMA_RESV_LIST_MASK; in dma_resv_list_entry() 87 enum dma_resv_usage usage) in dma_resv_list_set() argument 89 long tmp = ((long)fence) | usage; in dma_resv_list_set() 216 enum dma_resv_usage usage; in dma_resv_reserve_fences() local 219 dma_resv_list_entry(old, i, obj, &fence, &usage); in dma_resv_reserve_fences() 223 dma_resv_list_set(new, j++, fence, usage); in dma_resv_reserve_fences() 288 enum dma_resv_usage usage) in dma_resv_add_fence() argument 310 if ((old->context == fence->context && old_usage >= usage && in dma_resv_add_fence() [all …]
|
/linux/tools/power/acpi/tools/ec/ |
H A D | ec_access.c | 35 void usage(char progname[], int exit_status) in usage() function 62 usage(argv[0], EXIT_FAILURE); in parse_opts() 67 usage(argv[0], EXIT_FAILURE); in parse_opts() 72 usage(argv[0], EXIT_FAILURE); in parse_opts() 78 usage(argv[0], EXIT_FAILURE); in parse_opts() 84 usage(argv[0], EXIT_FAILURE); in parse_opts() 92 usage(argv[0], EXIT_SUCCESS); in parse_opts() 95 usage(argv[0], EXIT_FAILURE); in parse_opts() 104 usage(argv[0], EXIT_FAILURE); in parse_opts() 110 usage(argv[0], EXIT_FAILURE); in parse_opts() [all …]
|
/linux/tools/usb/usbip/src/ |
H A D | usbip.c | 38 void (*usage)(void); member 46 .usage = NULL 52 .usage = NULL 58 .usage = usbip_attach_usage 64 .usage = usbip_detach_usage 70 .usage = usbip_list_usage 76 .usage = usbip_bind_usage 82 .usage = usbip_unbind_usage 88 .usage = NULL 101 if (!strcmp(cmds[i].name, argv[0]) && cmds[i].usage) { in usbip_help() [all …]
|