Function at 0x10051590
Capabilities:
Get storage device properties

Disassembly:
push 0xffffffffffffffff
push 0x100a34b1
mov eax, dword fs:[0]
push eax
sub esp, 0xd60
mov eax, dword [0x100c7210]
xor eax, esp
mov dword [esp + 0xd5c], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x100c7210]
xor eax, esp
push eax
lea eax, [esp + 0xd74]
mov dword fs:[0], eax
mov eax, dword [esp + 0xd84]
mov dword [esp + 0x1c], eax
xor al, al
xor edi, edi
xor ebx, ebx
mov dword [esp + 0x24], ecx
mov dword [esp + 0x20], edx
mov byte [esp + 0x17], al
mov dword [esp + 0x18], edi
or ebp, 0xffffffff
nop
cmp al, bl
jne 0x10051834
push 0x200
lea eax, [esp + 0x374]
push ebx
push eax
call fcn.10053730
push edi
push 0x100b61c4
push ebp
lea ecx, [esp + 0x388]
push 0xff
push ecx
call fcn.10057545
add esp, 0x20
push ebx
push ebx
push 3
push ebx
push 3
push ebx
lea edx, [esp + 0x388]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, ebp
je 0x10051820
xor eax, eax
mov dword [esp + 0x64], eax
mov dword [esp + 0x68], eax
push 0x800
mov dword [esp + 0x70], eax
lea eax, [esp + 0x574]
push ebx
push eax
mov dword [esp + 0x34], ebx
mov dword [esp + 0x70], ebx
mov dword [esp + 0x74], ebx
call fcn.10053730
add esp, 0xc
push ebx
lea ecx, [esp + 0x2c]
push ecx
push 0x800
lea edx, [esp + 0x57c]
push edx
push 0xc
lea eax, [esp + 0x78]
push eax
push 0x2d1400
push esi
call dword [sym.imp.KERNEL32.dll_DeviceIoControl]
test eax, eax
je 0x1005180f
push 0xff
lea ecx, [esp + 0x75]
push ebx
push ecx
mov byte [esp + 0x7c], bl
call fcn.10053730
push 0xff
lea edx, [esp + 0x281]
push ebx
push edx
mov byte [esp + 0x288], bl
call fcn.10053730
push 0xff
lea eax, [esp + 0x18d]
push ebx
push eax
mov byte [esp + 0x194], bl
call fcn.10053730
mov eax, dword [esp + 0x5a4]
push ebx
lea edi, [esp + 0x298]
lea ecx, [esp + 0x598]
call fcn.10050f20
mov eax, dword [esp + 0x5ac]
push ebx
lea edi, [esp + 0x19c]
lea ecx, [esp + 0x59c]
call fcn.10050f20
mov eax, dword [esp + 0x5b4]
push 1
lea edi, [esp + 0xa0]
lea ecx, [esp + 0x5a0]
call fcn.10050f20
movsx ecx, byte [esp + 0xa0]
push ecx
call fcn.1005bb48
add esp, 0x34
test eax, eax
jne 0x1005176d
movsx edx, byte [esp + 0x83]
push edx
call fcn.1005bb48
add esp, 4
test eax, eax
je 0x10051815
lea eax, [esp + 0x70]
push eax
lea ecx, [esp + 0x30]
call fcn.100091e0
mov ecx, dword [esp + 0x1c]
push eax
mov dword [esp + 0xd80], ebx
call fcn.10014660
lea ecx, [esp + 0x2c]
mov dword [esp + 0xd7c], ebp
call fcn.1000b140
lea ecx, [esp + 0x270]
push ecx
lea ecx, [esp + 0x30]
call fcn.100091e0
mov ecx, dword [esp + 0x24]
push eax
mov dword [esp + 0xd80], 1
call fcn.10014660
lea ecx, [esp + 0x2c]
mov dword [esp + 0xd7c], ebp
call fcn.1000b140
lea edx, [esp + 0x170]
push edx
lea ecx, [esp + 0x4c]
call fcn.100091e0
mov ecx, dword [esp + 0x20]
push eax
mov dword [esp + 0xd80], 2
call fcn.10014660
lea ecx, [esp + 0x48]
mov dword [esp + 0xd7c], ebp
call fcn.1000b140
mov byte [esp + 0x17], 1
jmp 0x10051815
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, dword [esp + 0x18]
mov al, byte [esp + 0x17]
add edi, 1
cmp edi, 0x10
mov dword [esp + 0x18], edi
jl 0x100515f0
mov ecx, dword [esp + 0xd74]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0xd5c]
xor ecx, esp
call fcn.10053547
add esp, 0xd6c
ret