{"name": "vmxnet_tx_pkt_update_ip_checksums", "code": "unsigned __int64 __fastcall vmxnet_tx_pkt_update_ip_checksums ( __int64 @@a1@@ ) { __int16 @@v1@@ ; char @@v3@@ ; __int16 @@v4@@ ; unsigned int @@v5@@ ; __int64 @@v6@@ ; unsigned __int64 @@v7@@ ; @@v7@@ = __readfsqword ( Number ) ; if ( ! @@a1@@ ) _assert_fail ( String , String , Number , String ) ; @@v3@@ = * ( _BYTE * ) ( @@a1@@ + Number ) & Number ; if ( @@v3@@ == Number || @@v3@@ == Number ) { @@v6@@ = * ( _QWORD * ) ( * ( _QWORD * ) ( @@a1@@ + Number ) + Number L ) ; if ( ( unsigned __int64 ) * ( unsigned int * ) ( @@a1@@ + Number ) + * ( _QWORD * ) ( * ( _QWORD * ) ( @@a1@@ + Number ) + Number L ) <= Number ) { * ( _WORD * ) ( @@v6@@ + Number ) = cpu_to_be16 ( * ( _DWORD * ) ( @@a1@@ + Number ) + * ( _QWORD * ) ( * ( _QWORD * ) ( @@a1@@ + Number ) + Number L ) ) ; * ( _WORD * ) ( @@v6@@ + Number ) = Number ; @@v4@@ = net_raw_checksum ( @@v6@@ , * ( _QWORD * ) ( * ( _QWORD * ) ( @@a1@@ + Number ) + Number L ) ) ; * ( _WORD * ) ( @@v6@@ + Number ) = cpu_to_be16 ( @@v4@@ ) ; @@v5@@ = eth_calc_pseudo_hdr_csum ( @@v6@@ , ( unsigned __int16 ) * ( _DWORD * ) ( @@a1@@ + Number ) ) ; @@v1@@ = net_checksum_finish ( @@v5@@ ) ; @@v4@@ = cpu_to_be16 ( ~ @@v1@@ ) ; iov_from_buf ( * ( _QWORD * ) ( @@a1@@ + Number ) + Number L , * ( unsigned int * ) ( @@a1@@ + Number ) , * ( unsigned __int16 * ) ( @@a1@@ + Number ) , & @@v4@@ , Number L ) ; } } return __readfsqword ( Number ) ^ @@v7@@ ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "v1", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "r8"}, {"n": "v6", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "s16"}, {"n": "v5", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "s20"}, {"n": "v4", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "s22"}, {"n": "v3", "t": {"T": 1, "n": "char", "s": 1}, "location": "s23"}, {"n": "v7", "t": {"T": 1, "n": "unsigned __int64", "s": 8}, "location": "s8"}]}
{"name": "cpu_to_be16", "code": "__int16 __fastcall cpu_to_be16 ( __int16 @@a1@@ ) { return bswap16 ( @@a1@@ ) ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int16", "s": 2}, "location": "r56"}]} {"name": "net_raw_checksum", "code": "__int64 __fastcall net_raw_checksum ( __int64 @@a1@@ , unsigned int @@a2@@ ) { unsigned int @@v2@@ ; @@v2@@ = net_checksum_add ( @@a2@@ , @@a1@@ ) ; return net_checksum_finish ( @@v2@@ ) ; }", "source": [{"n": "a1", "t": {"T": 1, "n": "__int64", "s": 8}, "location": "r56"}, {"n": "a2", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "r64"}, {"n": "v2", "t": {"T": 1, "n": "unsigned int", "s": 4}, "location": "r8"}]}