{"name": "ehci_queues_rip_unused", "code": "unsigned __int64 __fastcall ehci_queues_rip_unused ( __int64 @@a1@@ , int @@a2@@ ) { __int64 * v2 ; const char * v3 ; __int64 @@i@@ ; __int64 * @@v6@@ ; const char * @@v7@@ ; __int64 @@v8@@ ; __int64 @@v9@@ ; unsigned __int64 @@v10@@ ; @@v10@@ = __readfsqword ( Number ) ; if ( @@a2@@ ) v2 = ( __int64 * ) ( @@a1@@ + Number ) ; else v2 = ( __int64 * ) ( @@a1@@ + Number ) ; @@v6@@ = v2 ; if ( @@a2@@ ) v3 = String ; else v3 = Number L ; @@v7@@ = v3 ; @@v8@@ = ( unsigned int ) ( Number * * ( _DWORD * ) ( @@a1@@ + Number ) ) ; for ( @@i@@ = * @@v6@@ ; @@i@@ ; @@i@@ = @@v9@@ ) { @@v9@@ = * ( _QWORD * ) ( @@i@@ + Number ) ; if ( * ( _DWORD * ) ( @@i@@ + Number ) ) { * ( _DWORD * ) ( @@i@@ + Number ) = Number ; * ( _QWORD * ) ( @@i@@ + Number ) = * ( _QWORD * ) ( @@a1@@ + Number ) ; } else if ( * ( _QWORD * ) ( @@a1@@ + Number ) >= ( unsigned __int64 ) ( * ( _QWORD * ) ( @@i@@ + Number ) + @@v8@@ ) ) { ehci_free_queue ( @@i@@ , @@v7@@ ) ; } } return __readfsqword ( Number ) ^ @@v10@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "int", "s": 4}, "location": "r64"}, {"n": "v9", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s16"}, {"n": "v8", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s24"}, {"n": "v7", "t": {"T": 3, "t": "const char"}, "location": "s32"}, {"n": "v6", "t": {"T": 3, "t": "__int64"}, "location": "s40"}, {"n": "i", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s48"}, {"n": "v10", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s8"}]}
{"name": "ehci_free_queue", "code": "unsigned __int64 __fastcall ehci_free_queue ( __int64 @@a1@@ , const char * @@a2@@ ) { __int64 @@v2@@ ; int @@v4@@ ; __int64 @@v5@@ ; unsigned __int64 @@v6@@ ; @@v6@@ = __readfsqword ( Number ) ; if ( * ( _DWORD * ) ( @@a1@@ + Number ) ) @@v2@@ = * ( _QWORD * ) @@a1@@ + Number L ; else @@v2@@ = * ( _QWORD * ) @@a1@@ + Number L ; @@v5@@ = @@v2@@ ; trace_usb_ehci_queue_action ( @@a1@@ , String ) ; @@v4@@ = ehci_cancel_queue ( @@a1@@ ) ; if ( @@a2@@ && @@v4@@ > Number ) ehci_trace_guest_bug ( * ( _QWORD * ) @@a1@@ , @@a2@@ ) ; if ( * ( _QWORD * ) ( @@a1@@ + Number ) ) * ( _QWORD * ) ( * ( _QWORD * ) ( @@a1@@ + Number ) + Number L ) = * ( _QWORD * ) ( @@a1@@ + Number ) ; else * ( _QWORD * ) ( @@v5@@ + Number ) = * ( _QWORD * ) ( @@a1@@ + Number ) ; * * ( _QWORD * * ) ( @@a1@@ + Number ) = * ( _QWORD * ) ( @@a1@@ + Number ) ; g_free ( @@a1@@ ) ; return __readfsqword ( Number ) ^ @@v6@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "a2", "t": {"T": 3, "t": "const char"}, "location": "r64"}, {"n": "v2", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r8"}, {"n": "v5", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s16"}, {"n": "v4", "t": {"T": 1, "n": "int", "s": 4}, "location": "s20"}, {"n": "v6", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s8"}]} {"name": "ehci_state_waitlisthead", "code": "__int64 __fastcall ehci_state_waitlisthead ( _DWORD * @@a1@@ , int @@a2@@ ) { int @@i@@ ; unsigned int @@v4@@ ; int @@v5@@ ; int @@v6@@ ; int @@v7@@ ; unsigned __int64 @@v8@@ ; @@v8@@ = __readfsqword ( Number ) ; @@v4@@ = Number ; @@v5@@ = @@a1@@ [ Number ] ; if ( @@a2@@ ) ehci_set_usbsts ( ( __int64 ) @@a1@@ , Number ) ; ehci_queues_rip_unused ( ( __int64 ) @@a1@@ , @@a2@@ ) ; for ( @@i@@ = Number ; ; ++ @@i@@ ) { if ( @@i@@ > Number ) { LABEL_13 : ehci_set_state ( @@a1@@ , @@a2@@ , Number ) ; return @@v4@@ ; } if ( ( int ) get_dwords ( ( __int64 ) @@a1@@ , @@v5@@ & Number , ( unsigned int * ) & @@v6@@ , Number ) < Number ) return Number L ; ehci_trace_qh ( Number L , @@v5@@ & Number , ( unsigned int * ) & @@v6@@ ) ; if ( ( @@v7@@ & Number ) != Number ) break ; @@v5@@ = @@v6@@ ; if ( @@v6@@ == @@a1@@ [ Number ] ) goto LABEL_13 ; } if ( @@a2@@ ) @@v5@@ |= Number ; ehci_set_fetch_addr ( ( __int64 ) @@a1@@ , @@a2@@ , @@v5@@ ) ; ehci_set_state ( @@a1@@ , @@a2@@ , Number ) ; return Number ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "_DWORD"}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "int", "s": 4}, "location": "r64"}, {"n": "v7", "t": {"T": 1, "n": "int", "s": 4}, "location": "s60"}, {"n": "v6", "t": {"T": 1, "n": "int", "s": 4}, "location": "s64"}, {"n": "v5", "t": {"T": 1, "n": "int", "s": 4}, "location": "s68"}, {"n": "v4", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s72"}, {"n": "i", "t": {"T": 1, "n": "int", "s": 4}, "location": "s76"}, {"n": "v8", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s8"}]} {"name": "ehci_advance_periodic_state", "code": "unsigned __int64 __fastcall ehci_advance_periodic_state ( _DWORD * @@a1@@ ) { int @@v1@@ ; int @@v3@@ ; int @@v4@@ ; unsigned int @@v5@@ ; unsigned __int64 @@v6@@ ; @@v6@@ = __readfsqword ( Number ) ; @@v4@@ = Number ; @@v1@@ = ehci_get_state ( ( __int64 ) @@a1@@ , Number ) ; if ( @@v1@@ == Number ) { if ( ( @@a1@@ [ Number ] & Number ) != Number || ! ehci_periodic_enabled ( ( __int64 ) @@a1@@ ) ) return __readfsqword ( Number ) ^ @@v6@@ ; ehci_set_state ( @@a1@@ , @@v4@@ , Number ) ; } else if ( @@v1@@ != Number ) { fprintf ( stderr , String , ( unsigned int ) @@a1@@ [ Number ] ) ; g_assertion_message_expr ( Number L , String , Number L , String , Number L ) ; return __readfsqword ( Number ) ^ @@v6@@ ; } if ( ( @@a1@@ [ Number ] & Number ) != Number || ehci_periodic_enabled ( ( __int64 ) @@a1@@ ) ) { @@v5@@ = @@a1@@ [ Number ] & Number ; if ( @@v5@@ ) { @@v5@@ |= ( @@a1@@ [ Number ] >> Number ) & Number ; if ( ( int ) get_dwords ( ( __int64 ) @@a1@@ , @@v5@@ , ( unsigned int * ) & @@v3@@ , Number ) >= Number ) { ehci_set_fetch_addr ( ( __int64 ) @@a1@@ , @@v4@@ , @@v3@@ ) ; ehci_set_state ( @@a1@@ , @@v4@@ , Number ) ; ehci_advance_state ( @@a1@@ , @@v4@@ ) ; ehci_queues_rip_unused ( ( __int64 ) @@a1@@ , @@v4@@ ) ; } } } else { ehci_queues_rip_all ( ( __int64 ) @@a1@@ , @@v4@@ ) ; ehci_set_state ( @@a1@@ , @@v4@@ , Number ) ; } return __readfsqword ( Number ) ^ @@v6@@ ; }", "source": [{"n": "a1", "t": {"T": 3, "t": "_DWORD"}, "location": "r56"}, {"n": "v1", "t": {"T": 1, "n": "int", "s": 4}, "location": "r8"}, {"n": "v5", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s12"}, {"n": "v4", "t": {"T": 1, "n": "int", "s": 4}, "location": "s16"}, {"n": "v3", "t": {"T": 1, "n": "int", "s": 4}, "location": "s20"}, {"n": "v6", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s8"}]}