Function at 0x608610
Capabilities:
Get disk information
Get disk information via ioctl

Disassembly:
push ebp
mov ebp, esp
add esp, 0xfffff14c
xor ecx, ecx
mov dword [ebp - 0xeb4], ecx
mov dword [ebp - 0xeb0], ecx
mov dword [ebp - 0xdac], ecx
mov dword [ebp - 0xda8], ecx
mov dword [ebp - 0xda4], ecx
mov dword [ebp - 0xda0], ecx
mov dword [ebp - 0xc], ecx
mov dword [ebp - 0x20], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.0040573c
xor eax, eax
push ebp
push 0x6089f1
push dword fs:[eax]
mov dword fs:[eax], esp
lea eax, [ebp - 0x990]
xor ecx, ecx
mov edx, 0x968
call fcn.00403464
lea eax, [ebp - 0x99c]
xor ecx, ecx
mov edx, 0xc
call fcn.00403464
mov eax, dword [ebp - 8]
call fcn.0040528c
lea eax, [ebp - 0xda0]
push eax
mov ecx, 2
mov edx, 1
mov eax, dword [ebp - 4]
call fcn.004057ac
mov eax, dword [ebp - 0xda0]
mov edx, 0x608a04
call fcn.00405698
je 0x6086ca
lea eax, [ebp - 0xc]
mov ecx, dword [ebp - 4]
mov edx, 0x608a10
call fcn.00405598
jmp 0x60871c
lea eax, [ebp - 0xc]
mov edx, dword [ebp - 4]
call fcn.00405324
lea eax, [ebp - 0xda4]
push eax
mov eax, dword [ebp - 0xc]
call fcn.0040554c
mov edx, eax
mov ecx, 1
mov eax, dword [ebp - 0xc]
call fcn.004057ac
mov eax, dword [ebp - 0xda4]
mov edx, 0x608a20
call fcn.00405698
jne 0x60871c
mov eax, dword [ebp - 0xc]
call fcn.0040554c
mov edx, eax
lea eax, [ebp - 0xc]
mov ecx, 1
call fcn.004057ec
push 0
push 0
push 3
push 0
push 3
push 0x80000000
mov eax, dword [ebp - 0xc]
push eax
call sub.kernel32.dll_CreateFileA_1
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0xffffffff
je 0x6089ab
push 0
lea eax, [ebp - 0x14]
push eax
push 0x968
lea eax, [ebp - 0x990]
push eax
push 0
push 0
push 0x560000
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_DeviceIoControl
cmp eax, 1
sbb eax, eax
inc eax
mov byte [ebp - 0x21], al
cmp byte [ebp - 0x21], 0
je 0x608855
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_CloseHandle_1
cmp byte [ebp - 0x21], 0
je 0x6089ab
lea eax, [ebp - 0x20]
call fcn.0040528c
mov eax, dword [ebp - 0x990]
dec eax
test eax, eax
jl 0x608808
inc eax
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x18], 0
cmp dword [ebp - 0x18], 0x63
jge 0x608800
xor eax, eax
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
call fcn.005dbe84
mov edx, dword [ebp - 0x18]
lea edx, [edx + edx*2]
cmp eax, dword [ebp + edx*8 - 0x988]
jne 0x6087f4
push dword [ebp - 0x20]
push 0x608a2c
lea edx, [ebp - 0xda8]
mov eax, dword [ebp - 0x1c]
call fcn.0040a78c
push dword [ebp - 0xda8]
lea eax, [ebp - 0x20]
mov edx, 3
call fcn.0040560c
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 0xf0
jne 0x6087b4
inc dword [ebp - 0x18]
dec dword [ebp - 0x28]
jne 0x6087a9
lea eax, [ebp - 0xdac]
push eax
mov ecx, 1
mov edx, 1
mov eax, dword [ebp - 0x20]
call fcn.004057ac
mov eax, dword [ebp - 0xdac]
mov edx, 0x608a2c
call fcn.00405698
jne 0x608845
lea eax, [ebp - 0x20]
mov ecx, 1
mov edx, 1
call fcn.004057ec
mov eax, dword [ebp - 8]
mov edx, dword [ebp - 0x20]
call fcn.004052e0
jmp 0x6089ab
push 0
lea eax, [ebp - 0x14]
push eax
push 0xc
lea eax, [ebp - 0x99c]
push eax
push 0
push 0
push 0x2d1080
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_DeviceIoControl
cmp eax, 1
sbb eax, eax
inc eax
mov byte [ebp - 0x21], al
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_CloseHandle_1
cmp byte [ebp - 0x21], 0
je 0x6088d1
mov eax, dword [ebp - 0x998]
xor edx, edx
push edx
push eax
mov eax, dword [ebp - 8]
call fcn.0040a878
xor eax, eax
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
call fcn.005dbe84
cmp eax, dword [ebp - 0x998]
jne 0x6088c0
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 0x1c]
call fcn.0040a78c
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 0xf0
jne 0x6088a5
jmp 0x6089ab
push 0x400
lea eax, [ebp - 0xd9c]
push eax
mov eax, dword [ebp - 4]
call fcn.0040574c
push eax
call sub.kernel32.dll_QueryDosDeviceA
test eax, eax
jbe 0x6089ab
lea eax, [ebp - 0x20]
lea edx, [ebp - 0xd9c]
mov ecx, 0x400
call fcn.004054fc
mov eax, dword [ebp - 0x20]
call fcn.00608368
mov dword [ebp - 0x18], eax
cmp dword [ebp - 0x18], 0xffffffff
jle 0x608922
mov edx, dword [ebp - 8]
mov eax, dword [ebp - 0x18]
call fcn.0040a78c
push dword [ebp - 4]
push 0x608a38
push dword [ebp - 0x20]
lea eax, [ebp - 0xeb0]
mov edx, 3
call fcn.0040560c
mov edx, dword [ebp - 0xeb0]
lea eax, [ebp - 0xeac]
mov ecx, 0xff
call fcn.00405528
lea edx, [ebp - 0xeac]
mov eax, 0x88a294
mov cl, 0x64
call fcn.004032d0
lea edx, [ebp - 0x20]
mov eax, dword [ebp - 4]
call fcn.0061b000
lea edx, [ebp - 0xeb4]
mov eax, dword [ebp - 0x20]
call fcn.0040a048
mov edx, dword [ebp - 0xeb4]
mov eax, 0x608a44
call fcn.00405890
test eax, eax
jle 0x6089ab
mov eax, dword [ebp - 8]
call fcn.0040528c
mov eax, 0x88a294
mov edx, 0x608a60
mov cl, 0x64
call fcn.00403294
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x6089f8
lea eax, [ebp - 0xeb4]
mov edx, 2
call fcn.004052b0
lea eax, [ebp - 0xdac]
mov edx, 4
call fcn.004052b0
lea eax, [ebp - 0x20]
call fcn.0040528c
lea eax, [ebp - 0xc]
call fcn.0040528c
lea eax, [ebp - 4]
call fcn.0040528c
ret