Function at 0x406bf0
Capabilities:
Get disk information

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x568c2c
mov eax, dword fs:[0]
push eax
sub esp, 0x21c
mov eax, dword [0x5cefc4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
lea ecx, [ebp - 0x21c]
mov esi, dword [ebp + 0xc]
push esi
mov dword [ebp - 0x228], eax
mov dword [ebp - 0x220], eax
call fcn.00406700
mov dword [ebp - 4], 0
test esi, esi
je 0x406e08
mov ecx, esi
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x406c50
sub ecx, edx
sar ecx, 1
cmp ecx, 2
jb 0x406e08
push 0x208
lea eax, [ebp - 0x218]
push 0
push eax
call fcn.00543520
add esp, 0xc
lea ecx, [ebp - 0x224]
push esi
call fcn.00406700
push 2
push 0
lea eax, [ebp - 0x220]
mov byte [ebp - 4], 1
push eax
lea ecx, [ebp - 0x224]
call fcn.00406eb0
push eax
lea ecx, [ebp - 0x224]
mov byte [ebp - 4], 2
call fcn.00405440
mov byte [ebp - 4], 1
or ebx, 0xffffffff
mov edx, dword [ebp - 0x220]
mov eax, ebx
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x406cd8
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push 0x104
lea eax, [ebp - 0x218]
push eax
push dword [ebp - 0x224]
call dword [sym.imp.KERNEL32.dll_QueryDosDeviceW]
test eax, eax
je 0x406d5f
mov eax, dword [ebp - 0x21c]
lea ecx, [ebp - 0x21c]
mov eax, dword [eax - 0xc]
add eax, 0xfffffffe
push eax
push 2
lea eax, [ebp - 0x220]
push eax
call fcn.00406eb0
lea eax, [ebp - 0x220]
mov byte [ebp - 4], 3
push eax
lea ecx, [ebp - 0x21c]
call fcn.00405440
mov byte [ebp - 4], 1
mov eax, ebx
mov edx, dword [ebp - 0x220]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x406d4c
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
lea eax, [ebp - 0x218]
push eax
push ecx
lea ecx, [ebp - 0x21c]
call fcn.00406fc0
mov esi, dword [ebp - 0x21c]
mov ecx, dword [esi - 0x10]
mov eax, dword [ecx]
call dword [eax + 0x10]
cmp dword [esi - 4], 0
mov ecx, eax
lea eax, [esi - 4]
jl 0x406d85
cmp ecx, dword [esi - 0x10]
jne 0x406d85
lea edi, [esi - 0x10]
lock inc dword [eax]
jmp 0x406db1
mov eax, dword [ecx]
push 2
push dword [esi - 0xc]
call dword [eax]
mov edi, eax
test edi, edi
je 0x406ea6
mov eax, dword [esi - 0xc]
mov dword [edi + 4], eax
lea eax, [edi + 0x10]
mov ecx, dword [esi - 0xc]
inc ecx
push ecx
push esi
push ecx
push eax
call fcn.00402110
add esp, 0x10
lea eax, [edi + 0x10]
mov byte [ebp - 4], 0
mov edi, dword [ebp - 0x228]
mov edx, dword [ebp - 0x224]
add edx, 0xfffffff0
mov dword [edi], eax
mov eax, ebx
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x406ddd
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov edx, dword [ebp - 0x21c]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], ebx
dec ebx
test ebx, ebx
jg 0x406e86
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
jmp 0x406e86
mov esi, dword [ebp - 0x21c]
mov ecx, dword [esi - 0x10]
mov eax, dword [ecx]
call dword [eax + 0x10]
cmp dword [esi - 4], 0
mov ecx, eax
lea eax, [esi - 4]
jl 0x406e2e
cmp ecx, dword [esi - 0x10]
jne 0x406e2e
lea edi, [esi - 0x10]
lock inc dword [eax]
jmp 0x406e56
mov eax, dword [ecx]
push 2
push dword [esi - 0xc]
call dword [eax]
mov edi, eax
test edi, edi
je 0x406ea6
mov eax, dword [esi - 0xc]
mov dword [edi + 4], eax
lea eax, [edi + 0x10]
mov ecx, dword [esi - 0xc]
inc ecx
push ecx
push esi
push ecx
push eax
call fcn.00402110
add esp, 0x10
lea eax, [edi + 0x10]
mov dword [ebp - 4], 0xffffffff
mov edi, dword [ebp - 0x228]
mov esi, dword [ebp - 0x21c]
add esi, 0xfffffff0
mov dword [edi], eax
or eax, 0xffffffff
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x406e86
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0053e9fa
mov esp, ebp
pop ebp
ret 8
call fcn.00402020
int3