Lines Matching refs:rd
933 static void sixaxis_parse_report(struct sony_sc *sc, __u8 *rd, int size) in sixaxis_parse_report() argument
945 if (rd[30] >= 0xee) { in sixaxis_parse_report()
947 battery_charging = !(rd[30] & 0x01); in sixaxis_parse_report()
950 __u8 index = rd[30] <= 5 ? rd[30] : 5; in sixaxis_parse_report()
963 static void dualshock4_parse_report(struct sony_sc *sc, __u8 *rd, int size) in dualshock4_parse_report() argument
982 cable_state = (rd[offset] >> 4) & 0x01; in dualshock4_parse_report()
983 battery_capacity = rd[offset] & 0x0F; in dualshock4_parse_report()
1022 x = rd[offset+1] | ((rd[offset+2] & 0xF) << 8); in dualshock4_parse_report()
1023 y = ((rd[offset+2] & 0xF0) >> 4) | (rd[offset+3] << 4); in dualshock4_parse_report()
1027 !(rd[offset] >> 7)); in dualshock4_parse_report()
1036 __u8 *rd, int size) in sony_raw_event() argument
1044 if ((sc->quirks & SIXAXIS_CONTROLLER) && rd[0] == 0x01 && size == 49) { in sony_raw_event()
1045 swap(rd[41], rd[42]); in sony_raw_event()
1046 swap(rd[43], rd[44]); in sony_raw_event()
1047 swap(rd[45], rd[46]); in sony_raw_event()
1048 swap(rd[47], rd[48]); in sony_raw_event()
1050 sixaxis_parse_report(sc, rd, size); in sony_raw_event()
1051 } else if (((sc->quirks & DUALSHOCK4_CONTROLLER_USB) && rd[0] == 0x01 && in sony_raw_event()
1053 && rd[0] == 0x11 && size == 78)) { in sony_raw_event()
1054 dualshock4_parse_report(sc, rd, size); in sony_raw_event()