Lines Matching refs:p
336 static s32 uclogic_params_get_le24(const void *p) in uclogic_params_get_le24() argument
338 const __u8 *b = p; in uclogic_params_get_le24()
838 struct uclogic_params p = {0, }; in uclogic_params_huion_init() local
864 p.pen.usage_invalid = true; in uclogic_params_huion_init()
868 uclogic_params_init_invalid(&p); in uclogic_params_huion_init()
893 rc = uclogic_params_pen_init_v2(&p.pen, &found, in uclogic_params_huion_init()
904 &p.frame_list[0], in uclogic_params_huion_init()
916 p.pen.subreport_list[0].value = 0xe0; in uclogic_params_huion_init()
917 p.pen.subreport_list[0].id = in uclogic_params_huion_init()
927 &p.frame_list[1], in uclogic_params_huion_init()
937 p.frame_list[1].suffix = "Touch Ring"; in uclogic_params_huion_init()
938 p.frame_list[1].dev_id_byte = in uclogic_params_huion_init()
940 p.frame_list[1].touch_byte = 5; in uclogic_params_huion_init()
941 p.frame_list[1].touch_max = 12; in uclogic_params_huion_init()
942 p.frame_list[1].touch_flip_at = 7; in uclogic_params_huion_init()
946 &p.frame_list[1], in uclogic_params_huion_init()
956 p.frame_list[1].suffix = "Touch Strip"; in uclogic_params_huion_init()
957 p.frame_list[1].dev_id_byte = in uclogic_params_huion_init()
959 p.frame_list[1].touch_byte = 5; in uclogic_params_huion_init()
960 p.frame_list[1].touch_max = 8; in uclogic_params_huion_init()
964 p.pen.subreport_list[1].value = 0xf0; in uclogic_params_huion_init()
965 p.pen.subreport_list[1].id = in uclogic_params_huion_init()
970 &p.frame_list[2], in uclogic_params_huion_init()
980 p.frame_list[2].suffix = "Dial"; in uclogic_params_huion_init()
981 p.frame_list[2].dev_id_byte = in uclogic_params_huion_init()
983 p.frame_list[2].bitmap_dial_byte = 5; in uclogic_params_huion_init()
986 p.pen.subreport_list[2].value = 0xf1; in uclogic_params_huion_init()
987 p.pen.subreport_list[2].id = in uclogic_params_huion_init()
996 rc = uclogic_params_pen_init_v1(&p.pen, &found, hdev); in uclogic_params_huion_init()
1004 rc = uclogic_params_frame_init_v1(&p.frame_list[0], in uclogic_params_huion_init()
1014 p.pen.subreport_list[0].value = 0xe0; in uclogic_params_huion_init()
1015 p.pen.subreport_list[0].id = in uclogic_params_huion_init()
1022 uclogic_params_init_invalid(&p); in uclogic_params_huion_init()
1026 memcpy(params, &p, sizeof(*params)); in uclogic_params_huion_init()
1027 memset(&p, 0, sizeof(p)); in uclogic_params_huion_init()
1032 uclogic_params_cleanup(&p); in uclogic_params_huion_init()
1155 static int uclogic_params_ugee_v2_init_frame_buttons(struct uclogic_params *p, in uclogic_params_ugee_v2_init_frame_buttons() argument
1162 if (!p || desc_params_size != UCLOGIC_RDESC_PH_ID_NUM) in uclogic_params_ugee_v2_init_frame_buttons()
1172 rc = uclogic_params_frame_init_with_desc(&p->frame_list[0], in uclogic_params_ugee_v2_init_frame_buttons()
1190 static int uclogic_params_ugee_v2_init_frame_dial(struct uclogic_params *p, in uclogic_params_ugee_v2_init_frame_dial() argument
1197 if (!p || desc_params_size != UCLOGIC_RDESC_PH_ID_NUM) in uclogic_params_ugee_v2_init_frame_dial()
1207 rc = uclogic_params_frame_init_with_desc(&p->frame_list[0], in uclogic_params_ugee_v2_init_frame_dial()
1215 p->frame_list[0].bitmap_dial_byte = 7; in uclogic_params_ugee_v2_init_frame_dial()
1227 static int uclogic_params_ugee_v2_init_frame_mouse(struct uclogic_params *p) in uclogic_params_ugee_v2_init_frame_mouse() argument
1231 if (!p) in uclogic_params_ugee_v2_init_frame_mouse()
1234 rc = uclogic_params_frame_init_with_desc(&p->frame_list[1], in uclogic_params_ugee_v2_init_frame_mouse()
1281 struct uclogic_params *p) in uclogic_params_ugee_v2_init_battery() argument
1285 if (!hdev || !p) in uclogic_params_ugee_v2_init_battery()
1295 rc = uclogic_params_frame_init_with_desc(&p->frame_list[1], in uclogic_params_ugee_v2_init_battery()
1302 p->frame_list[1].suffix = "Battery"; in uclogic_params_ugee_v2_init_battery()
1303 p->pen.subreport_list[1].value = 0xf2; in uclogic_params_ugee_v2_init_battery()
1304 p->pen.subreport_list[1].id = UCLOGIC_RDESC_UGEE_V2_BATTERY_ID; in uclogic_params_ugee_v2_init_battery()
1338 struct uclogic_params *p) in uclogic_params_ugee_v2_init_event_hooks() argument
1346 if (!p) in uclogic_params_ugee_v2_init_event_hooks()
1353 p->event_hooks = kzalloc(sizeof(*p->event_hooks), GFP_KERNEL); in uclogic_params_ugee_v2_init_event_hooks()
1354 if (!p->event_hooks) in uclogic_params_ugee_v2_init_event_hooks()
1357 INIT_LIST_HEAD(&p->event_hooks->list); in uclogic_params_ugee_v2_init_event_hooks()
1370 list_add_tail(&event_hook->list, &p->event_hooks->list); in uclogic_params_ugee_v2_init_event_hooks()
1407 struct uclogic_params p = {0, }; in uclogic_params_ugee_v2_init() local
1419 rc = uclogic_params_ugee_v2_init_frame_mouse(&p); in uclogic_params_ugee_v2_init()
1427 uclogic_params_init_invalid(&p); in uclogic_params_ugee_v2_init()
1440 uclogic_params_init_invalid(&p); in uclogic_params_ugee_v2_init()
1452 uclogic_params_init_invalid(&p); in uclogic_params_ugee_v2_init()
1476 p.pen.desc_ptr = rdesc_pen; in uclogic_params_ugee_v2_init()
1477 p.pen.desc_size = uclogic_rdesc_ugee_v2_pen_template_size; in uclogic_params_ugee_v2_init()
1478 p.pen.id = 0x02; in uclogic_params_ugee_v2_init()
1479 p.pen.subreport_list[0].value = 0xf0; in uclogic_params_ugee_v2_init()
1480 p.pen.subreport_list[0].id = UCLOGIC_RDESC_V1_FRAME_ID; in uclogic_params_ugee_v2_init()
1489 rc = uclogic_params_ugee_v2_init_frame_dial(&p, desc_params, in uclogic_params_ugee_v2_init()
1494 rc = uclogic_params_ugee_v2_init_frame_buttons(&p, desc_params, in uclogic_params_ugee_v2_init()
1504 rc = uclogic_params_ugee_v2_init_battery(hdev, &p); in uclogic_params_ugee_v2_init()
1512 rc = uclogic_params_ugee_v2_init_event_hooks(hdev, &p); in uclogic_params_ugee_v2_init()
1520 memcpy(params, &p, sizeof(*params)); in uclogic_params_ugee_v2_init()
1521 memset(&p, 0, sizeof(p)); in uclogic_params_ugee_v2_init()
1525 uclogic_params_cleanup(&p); in uclogic_params_ugee_v2_init()
1553 struct uclogic_params p = {0, }; in uclogic_params_init() local
1572 &p, hdev, \ in uclogic_params_init()
1617 rc = uclogic_params_pen_init_v1(&p.pen, in uclogic_params_init()
1630 uclogic_params_init_invalid(&p); in uclogic_params_init()
1710 rc = uclogic_params_huion_init(&p, hdev); in uclogic_params_init()
1729 rc = uclogic_params_pen_init_v1(&p.pen, &found, hdev); in uclogic_params_init()
1736 uclogic_params_init_invalid(&p); in uclogic_params_init()
1739 uclogic_params_init_invalid(&p); in uclogic_params_init()
1747 rc = uclogic_params_pen_init_v1(&p.pen, &found, hdev); in uclogic_params_init()
1754 &p.frame_list[0], in uclogic_params_init()
1761 uclogic_params_init_invalid(&p); in uclogic_params_init()
1776 rc = uclogic_params_ugee_v2_init(&p, hdev); in uclogic_params_init()
1786 uclogic_params_init_invalid(&p); in uclogic_params_init()
1790 rc = uclogic_params_pen_init_v1(&p.pen, &found, hdev); in uclogic_params_init()
1796 &p.frame_list[0], in uclogic_params_init()
1806 p.frame_list[0].re_lsb = in uclogic_params_init()
1808 p.frame_list[0].dev_id_byte = in uclogic_params_init()
1812 uclogic_params_init_invalid(&p); in uclogic_params_init()
1820 uclogic_params_init_invalid(&p); in uclogic_params_init()
1824 rc = uclogic_params_pen_init_v1(&p.pen, &found, hdev); in uclogic_params_init()
1830 &p.frame_list[0], in uclogic_params_init()
1842 uclogic_params_init_invalid(&p); in uclogic_params_init()
1852 memcpy(params, &p, sizeof(*params)); in uclogic_params_init()
1853 memset(&p, 0, sizeof(p)); in uclogic_params_init()
1856 uclogic_params_cleanup(&p); in uclogic_params_init()