Lines Matching refs:readbuf
171 u8 *readbuf = NULL; in t4_read_write_register() local
205 readbuf = kzalloc(T4_FEATURE_REPORT_LEN, GFP_KERNEL); in t4_read_write_register()
206 if (!readbuf) { in t4_read_write_register()
211 ret = hid_hw_raw_request(hdev, T4_FEATURE_REPORT_ID, readbuf, in t4_read_write_register()
221 if (*(u32 *)&readbuf[6] != address) { in t4_read_write_register()
223 *(u32 *)&readbuf[6], address); in t4_read_write_register()
227 if (*(u16 *)&readbuf[10] != 1) { in t4_read_write_register()
229 *(u16 *)&readbuf[10]); in t4_read_write_register()
233 check_sum = t4_calc_check_sum(readbuf, 6, 7); in t4_read_write_register()
234 if (*(u16 *)&readbuf[13] != check_sum) { in t4_read_write_register()
236 *(u16 *)&readbuf[13], check_sum); in t4_read_write_register()
240 *read_val = readbuf[12]; in t4_read_write_register()
246 kfree(readbuf); in t4_read_write_register()
258 u8 *readbuf; in u1_read_write_register() local
291 readbuf = kzalloc(U1_FEATURE_REPORT_LEN, GFP_KERNEL); in u1_read_write_register()
292 if (!readbuf) { in u1_read_write_register()
297 ret = hid_hw_raw_request(hdev, U1_FEATURE_REPORT_ID, readbuf, in u1_read_write_register()
303 kfree(readbuf); in u1_read_write_register()
307 *read_val = readbuf[6]; in u1_read_write_register()
309 kfree(readbuf); in u1_read_write_register()