Function at 0x12fa00
Capabilities:
Get thread local storage value
Set thread local storage value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
mov ebx, ecx
mov dword [ebp - 4], edx
push edi
mov dword [ebp - 8], ebx
call fcn.000ee7f0
test byte [ebp - 4], 0x70
jne 0x12fa77
call fcn.000ee7f0
mov edi, dword [0x1aa224]
push edi
call dword [sym.imp.KERNEL32.dll_TlsGetValue]
mov esi, eax
test esi, esi
jne 0x12fa5b
push 0xc08
call fcn.0015c8ae
add esp, 4
mov esi, eax
push 0xc08
push 0
push esi
call fcn.00153d90
add esp, 0xc
push esi
push edi
call dword [sym.imp.KERNEL32.dll_TlsSetValue]
push str.Invalid_FS_Type_in_ffs_open
mov dword [esi], 0x8000006
call fcn.000ee5f0
add esp, 4
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov ecx, 0x160
call fcn.000f2310
mov esi, eax
test esi, esi
je 0x130436
mov edi, dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
lea eax, [esi + 0x9c]
push eax
call edi
lea eax, [esi + 0xb8]
push eax
call edi
mov eax, dword [ebp - 4]
xor edx, edx
mov dword [esi + 0xb4], 0
mov dword [esi + 0x68], eax
mov dword [esi + 0x70], 0
mov dword [esi + 0x6c], str.Fragment
mov dword [esi], 0x10101010
mov dword [esi + 4], ebx
mov dword [esi + 8], 0
mov dword [esi + 0xc], 0
mov ecx, dword [ebx + 0x10]
lea eax, [ecx + 0x5ff]
div ecx
mov edi, eax
imul edi, ecx
mov ecx, edi
call fcn.000f2310
mov dword [esi + 0x118], eax
mov ecx, esi
test eax, eax
jne 0x12fb0d
mov dword [esi], eax
call fcn.000eee80
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x600
push 0
push 0x10000
mov edx, eax
call fcn.00135350
add esp, 0xc
cmp eax, 0x600
je 0x12fb77
test eax, eax
js 0x12fb3d
call fcn.000ee7f0
mov ecx, 0x8000004
call fcn.000ee550
push 0
push 0x10000
push str.ffs_open
push str._s:_Superblock_at__llu
call fcn.000ee5f0
mov dword [esi], 0
push dword [esi + 0x118]
call fcn.00158d47
add esp, 0x14
mov ecx, esi
call fcn.000eee80
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esi + 0x118]
movzx ecx, byte [eax + 0x55d]
movzx edx, byte [eax + 0x55f]
movzx ebx, byte [eax + 0x55e]
mov dword [ebp - 4], ecx
movzx ecx, byte [eax + 0x55c]
mov eax, edx
shl eax, 8
add eax, ebx
shl eax, 8
add eax, dword [ebp - 4]
shl eax, 8
add eax, ecx
cmp eax, 0x19540119
jne 0x12fbcb
mov dword [esi + 0x98], 1
mov dword [esi + 0x68], 0x40
jmp 0x12fdc8
shl ecx, 8
add ecx, dword [ebp - 4]
shl ecx, 8
add ecx, ebx
shl ecx, 8
add ecx, edx
cmp ecx, 0x19540119
je 0x12fce4
cmp dword [0x1aa220], 0
je 0x12fc08
push str.ufs_open:_Trying_256KB_UFS2_location_n
push 2
call fcn.00158e14
add esp, 4
push eax
call fcn.000a3930
add esp, 8
mov edx, dword [esi + 0x118]
mov ecx, esi
push 0x600
push 0
push 0x40000
call fcn.00135350
add esp, 0xc
cmp eax, 0x600
je 0x12fc78
test eax, eax
js 0x12fc3e
call fcn.000ee7f0
mov ecx, 0x8000004
call fcn.000ee550
push 0
push 0x40000
push str.ffs_open
push str._s:_Superblock_at__llu
call fcn.000ee650
mov dword [esi], 0
push dword [esi + 0x118]
call fcn.00158d47
add esp, 0x14
mov ecx, esi
call fcn.000eee80
xor eax, eax
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [esi + 0x118]
movzx ecx, byte [eax + 0x55d]
movzx edx, byte [eax + 0x55f]
movzx ebx, byte [eax + 0x55e]
mov dword [ebp - 4], ecx
movzx ecx, byte [eax + 0x55c]
mov eax, edx
shl eax, 8
add eax, ebx
shl eax, 8
add eax, dword [ebp - 4]
shl eax, 8
add eax, ecx
cmp eax, 0x19540119
jne 0x12fccc
mov dword [esi + 0x98], 1
mov dword [esi + 0x68], 0x40
jmp 0x12fdc8
shl ecx, 8
add ecx, dword [ebp - 4]
shl ecx, 8
add ecx, ebx
shl ecx, 8
add ecx, edx
cmp ecx, 0x19540119
jne 0x12fcfa
mov dword [esi + 0x98], 2
mov dword [esi + 0x68], 0x40
jmp 0x12fdc8
cmp dword [0x1aa220], 0
je 0x12fd1b
push str.ufs_open:_Trying_UFS1_location_n
push 2
call fcn.00158e14
add esp, 4
push eax
call fcn.000a3930
add esp, 8
mov edx, dword [esi + 0x118]
mov ecx, esi
push edi
push 0
push 0x2000
call fcn.00135350
add esp, 0xc
cmp eax, edi
je 0x12fd56
test eax, eax
js 0x12fd4a
call fcn.000ee7f0
mov ecx, 0x8000004
call fcn.000ee550
push 0
push 0x2000
jmp 0x12fc45
mov eax, dword [esi + 0x118]
movzx edx, byte [eax + 0x55f]
movzx edi, byte [eax + 0x55e]
movzx ebx, byte [eax + 0x55d]
movzx ecx, byte [eax + 0x55c]
mov eax, edx
shl eax, 8
add eax, edi
shl eax, 8
add eax, ebx
shl eax, 8
add eax, ecx
cmp eax, 0x11954
jne 0x12fd9c
mov dword [esi + 0x98], 1
jmp 0x12fdc1
shl ecx, 8
add ecx, ebx
shl ecx, 8
add ecx, edi
shl ecx, 8
add ecx, edx
cmp ecx, 0x11954
jne 0x1303de
mov dword [esi + 0x98], 2
mov dword [esi + 0x68], 0x10
cmp dword [esi + 0x68], 0x40
jne 0x130015
cmp dword [esi + 0x98], 1
mov ecx, dword [esi + 0x118]
jne 0x12fe6d
movzx eax, byte [ecx + 0x43f]
cdq
mov edi, eax
mov ebx, edx
movzx eax, byte [ecx + 0x43e]
shld ebx, edi, 8
cdq
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43d]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43c]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43b]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43a]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x439]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x438]
jmp 0x12fef0
movzx eax, byte [ecx + 0x438]
cdq
mov edi, eax
mov ebx, edx
movzx eax, byte [ecx + 0x439]
shld ebx, edi, 8
cdq
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43a]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43b]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43c]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43d]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43e]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x43f]
adc ebx, edx
cdq
shld ebx, edi, 8
shl edi, 8
add edi, eax
mov dword [esi + 0x30], edi
mov edi, dword [esi + 0x98]
adc ebx, edx
mov dword [esi + 0x34], ebx
mov ecx, dword [esi + 0x118]
cmp edi, 1
jne 0x12ff31
movzx edx, byte [ecx + 0x37]
movzx eax, byte [ecx + 0x36]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0x35]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0x34]
jmp 0x12ff4b
movzx edx, byte [ecx + 0x34]
movzx eax, byte [ecx + 0x35]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0x36]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0x37]
shl edx, 8
add edx, eax
cmp edi, 1
mov dword [esi + 0x50], edx
mov edx, dword [esi + 0x118]
jne 0x12ff7a
movzx ecx, byte [edx + 0x33]
movzx eax, byte [edx + 0x32]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x31]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x30]
jmp 0x12ff94
movzx ecx, byte [edx + 0x30]
movzx eax, byte [edx + 0x31]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x32]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x33]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x158], ecx
cmp dword [esi + 0x98], 1
jne 0x12ffc4
movzx ecx, byte [edx + 0x3b]
movzx eax, byte [edx + 0x3a]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x39]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x38]
jmp 0x12ffde
movzx ecx, byte [edx + 0x38]
movzx eax, byte [edx + 0x39]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x3a]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x3b]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x154], ecx
cmp dword [esi + 0x98], 1
jne 0x1300cd
movzx ecx, byte [edx + 0x2f]
movzx eax, byte [edx + 0x2e]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x2d]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x2c]
jmp 0x1300e7
mov ebx, dword [esi + 0x98]
cmp ebx, 1
jne 0x130047
mov ecx, dword [esi + 0x118]
movzx edi, byte [ecx + 0x27]
movzx eax, byte [ecx + 0x26]
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x25]
shl edi, 8
add edi, eax
movzx eax, byte [ecx + 0x24]
shl edi, 8
add edi, eax
jmp 0x13006c
mov edx, dword [esi + 0x118]
movzx edi, byte [edx + 0x24]
movzx eax, byte [edx + 0x25]
movzx ecx, byte [edx + 0x26]
shl edi, 8
add edi, eax
shl edi, 8
add edi, ecx
movzx ecx, byte [edx + 0x27]
shl edi, 8
add edi, ecx
mov eax, edi
cdq
mov dword [esi + 0x30], eax
mov dword [esi + 0x34], edx
mov ecx, dword [esi + 0x118]
cmp ebx, 1
jne 0x1300a6
movzx edx, byte [ecx + 0x37]
movzx eax, byte [ecx + 0x36]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0x35]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0x34]
shl edx, 8
add edx, eax
cmp ebx, ebx
jmp 0x12ff53
movzx edx, byte [ecx + 0x34]
movzx eax, byte [ecx + 0x35]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0x36]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0x37]
shl edx, 8
add edx, eax
cmp ebx, 1
jmp 0x12ff53
movzx ecx, byte [edx + 0x2c]
movzx eax, byte [edx + 0x2d]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x2e]
shl ecx, 8
add ecx, eax
movzx eax, byte [edx + 0x2f]
shl ecx, 8
add ecx, eax
mov dword [esi + 0x150], ecx
mov ecx, dword [esi + 0x30]
mov eax, dword [esi + 0x34]
add ecx, 0xffffffff
mov ebx, dword [esi + 0x50]
mov dword [esi + 0x48], ecx
adc eax, 0xffffffff
mov dword [esi + 0x40], ecx
mov ecx, dword [ebp - 8]
push 0
mov dword [esi + 0x4c], eax
mov dword [esi + 0x44], eax
mov dword [esi + 0x38], 0
mov dword [esi + 0x3c], 0
mov eax, dword [ecx + 0x10]
push ebx
mov dword [esi + 0x54], eax
push dword [ecx + 0xc]
push dword [ecx + 8]
call fcn.00171c30
cmp edx, dword [esi + 0x34]
ja 0x13014a
jb 0x13013e
cmp eax, dword [esi + 0x30]
jae 0x13014a
add eax, 0xffffffff
mov dword [esi + 0x48], eax
adc edx, 0xffffffff
mov dword [esi + 0x4c], edx
test ebx, 0x1ff
jne 0x1303b2
mov eax, dword [esi + 0x158]
test eax, 0x1ff
jne 0x1303b2
xor edx, edx
div ebx
cmp eax, dword [esi + 0x154]
je 0x1301a6
call fcn.000ee7f0
mov ecx, 0x800000a
call fcn.000ee550
push str.Not_a_UFS_FS__frag___block_size_mismatch_
call fcn.000ee5f0
add esp, 4
cmp dword [0x1aa220], 0
je 0x13041b
push str.ufs_open:_fragment___block_size_mismatch_n
jmp 0x130408
cmp dword [esi + 0x98], 1
mov ecx, dword [esi + 0x118]
jne 0x1301dd
movzx edx, byte [ecx + 0xbb]
movzx eax, byte [ecx + 0xba]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0xb9]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0xb8]
jmp 0x130203
movzx edx, byte [ecx + 0xb8]
movzx eax, byte [ecx + 0xb9]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0xba]
shl edx, 8
add edx, eax
movzx eax, byte [ecx + 0xbb]
shl edx, 8
add edx, eax
mov eax, dword [esi + 0x150]
imul eax, edx
mov dword [esi + 0x14], 0
mov dword [esi + 0x18], 2
mov dword [esi + 0x1c], 0
mov dword [esi + 0x20], 0
inc eax
mov dword [esi + 0x24], 0
mov ecx, eax
mov dword [esi + 0x10], eax
mov eax, dword [esi + 0x14]
add ecx, 0xffffffff
mov dword [esi + 0x28], ecx
adc eax, 0xffffffff
mov dword [esi + 0x94], 0
mov dword [esi + 0x2c], eax
mov ecx, dword [esi + 0x94]
mov eax, dword [esi + 0x118]
mov al, byte [ecx + eax + 0x90]
mov byte [ecx + esi + 0x74], al
inc dword [esi + 0x94]
cmp dword [esi + 0x94], 8
jb 0x130253
cmp dword [0x1aa220], 0
mov dword [esi + 0xdc], 0x129a60
mov dword [esi + 0xd4], 0x12a830
mov dword [esi + 0xd8], 0x12a1a0
mov dword [esi + 0xe4], 0xf6600
mov dword [esi + 0xe8], 0x134590
mov dword [esi + 0x104], 0x134980
mov dword [esi + 0xe0], 0x129900
mov dword [esi + 0xf0], 0x1407e0
mov dword [esi + 0x100], 0x12ac40
mov dword [esi + 0x108], 0x12abe0
mov dword [esi + 0xec], 0x12e440
mov dword [esi + 0x10c], 0x12f9a0
mov dword [esi + 0xf8], 0x12f940
mov dword [esi + 0xfc], 0x12f940
mov dword [esi + 0xf4], 0x12f8e0
mov dword [esi + 0x60], 0
mov dword [esi + 0x64], 0
mov dword [esi + 0x140], 0
mov dword [esi + 0x144], 0xffffffff
mov dword [esi + 0x148], 0
mov dword [esi + 0x14c], 0
mov dword [esi + 0x134], 0
mov dword [esi + 0x138], 0
mov dword [esi + 0x13c], 0
je 0x13039c
push dword [esi + 0x34]
push dword [esi + 0x30]
push dword [esi + 0x150]
push dword [esi + 0x1c]
push dword [esi + 0x18]
push dword [esi + 0x14]
push dword [esi + 0x10]
push str.inodes__llu_root_ino__llu_cyl_groups__d_blocks__llu_n
push 2
call fcn.00158e14
add esp, 4
push eax
call fcn.000f0dc0
add esp, 0x24
lea eax, [esi + 0x11c]
push eax
call dword [sym.imp.KERNEL32.dll_InitializeCriticalSection]
mov eax, esi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
call fcn.000ee7f0
mov ecx, 0x800000a
call fcn.000ee550
push str.Not_a_UFS_FS__invalid_fragment_or_block_size_
call fcn.000ee5f0
add esp, 4
cmp dword [0x1aa220], 0
je 0x13041b
push str.ufs_open:_invalid_fragment_or_block_size_n
jmp 0x130408
call fcn.000ee7f0
mov ecx, 0x800000a
call fcn.000ee550
push str.No_UFS_Magic_Found
call fcn.000ee5f0
add esp, 4
cmp dword [0x1aa220], 0
je 0x13041b
push str.ufs_open:_No_UFS_magic_found_n
push 2
call fcn.00158e14
add esp, 4
push eax
call fcn.000a3930
add esp, 8
mov dword [esi], 0
push dword [esi + 0x118]
call fcn.00158d47
add esp, 4
mov ecx, esi
call fcn.000eee80
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret