Lines Matching refs:rmem
381 ssize_t wiimote_cmd_read(struct wiimote_data *wdata, __u32 offset, __u8 *rmem, in wiimote_cmd_read() argument
389 wdata->state.cmd_read_buf = rmem; in wiimote_cmd_read()
432 static __u8 wiimote_cmd_read_ext(struct wiimote_data *wdata, __u8 *rmem) in wiimote_cmd_read_ext() argument
437 ret = wiimote_cmd_read(wdata, 0xa400fa, rmem, 6); in wiimote_cmd_read_ext()
441 hid_dbg(wdata->hdev, "extension ID: %6phC\n", rmem); in wiimote_cmd_read_ext()
443 if (rmem[0] == 0xff && rmem[1] == 0xff && rmem[2] == 0xff && in wiimote_cmd_read_ext()
444 rmem[3] == 0xff && rmem[4] == 0xff && rmem[5] == 0xff) in wiimote_cmd_read_ext()
447 if (rmem[4] == 0x00 && rmem[5] == 0x00) in wiimote_cmd_read_ext()
449 if (rmem[4] == 0x01 && rmem[5] == 0x01) in wiimote_cmd_read_ext()
451 if (rmem[4] == 0x04 && rmem[5] == 0x02) in wiimote_cmd_read_ext()
453 if (rmem[4] == 0x01 && rmem[5] == 0x20) in wiimote_cmd_read_ext()
455 if (rmem[0] == 0x01 && rmem[1] == 0x00 && in wiimote_cmd_read_ext()
456 rmem[4] == 0x01 && rmem[5] == 0x03) in wiimote_cmd_read_ext()
458 if (rmem[0] == 0x00 && rmem[1] == 0x00 && in wiimote_cmd_read_ext()
459 rmem[4] == 0x01 && rmem[5] == 0x03) in wiimote_cmd_read_ext()
510 static bool wiimote_cmd_read_mp(struct wiimote_data *wdata, __u8 *rmem) in wiimote_cmd_read_mp() argument
515 ret = wiimote_cmd_read(wdata, 0xa600fa, rmem, 6); in wiimote_cmd_read_mp()
519 hid_dbg(wdata->hdev, "motion plus ID: %6phC\n", rmem); in wiimote_cmd_read_mp()
521 if (rmem[5] == 0x05) in wiimote_cmd_read_mp()
524 hid_info(wdata->hdev, "unknown motion plus ID: %6phC\n", rmem); in wiimote_cmd_read_mp()
533 __u8 rmem[6]; in wiimote_cmd_read_mp_mapped() local
536 ret = wiimote_cmd_read(wdata, 0xa400fa, rmem, 6); in wiimote_cmd_read_mp_mapped()
540 hid_dbg(wdata->hdev, "mapped motion plus ID: %6phC\n", rmem); in wiimote_cmd_read_mp_mapped()
542 if (rmem[0] == 0xff && rmem[1] == 0xff && rmem[2] == 0xff && in wiimote_cmd_read_mp_mapped()
543 rmem[3] == 0xff && rmem[4] == 0xff && rmem[5] == 0xff) in wiimote_cmd_read_mp_mapped()
546 if (rmem[4] == 0x04 && rmem[5] == 0x05) in wiimote_cmd_read_mp_mapped()
548 else if (rmem[4] == 0x05 && rmem[5] == 0x05) in wiimote_cmd_read_mp_mapped()
550 else if (rmem[4] == 0x07 && rmem[5] == 0x05) in wiimote_cmd_read_mp_mapped()