Function at 0x14009a8d0
Capabilities:
Query or enumerate registry value

Disassembly:
push rbp
push rdi
push r12
push r14
push r15
lea rbp, [rsp - 0x1fc0]
mov eax, 0x20c0
call fcn.1400c26e0
sub rsp, rax
mov qword [rsp + 0x50], 0xfffffffffffffffe
mov qword [rsp + 0x20f0], rbx
mov qword [rsp + 0x2108], rsi
mov rax, qword [0x14014f010]
xor rax, rsp
mov qword [rbp + 0x1fb0], rax
mov r15, r8
mov r14, rdx
test rdx, rdx
jne 0x14009a943
mov r8d, 0x265
lea rdx, str.CRtkBssGen4PresetLoader::GetPresetId
lea rcx, str._s__d_RETURN_FALSE_ON_FALSE
call fcn.14005be10
xor eax, eax
jmp 0x14009add9
mov rcx, r15
call fcn.140004a60
mov rcx, r14
call fcn.14000fa10
mov ecx, eax
xor edi, edi
cmp eax, 1
jne 0x14009ac45
call fcn.140004f00
mov rcx, rax
test rax, rax
je 0x14009ae0f
mov rax, qword [rax]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rsp + 0x70], rax
lea r8, [rsp + 0x70]
mov rdx, r14
call fcn.14009ae20
lea rbx, [rdi - 1]
test eax, eax
jne 0x14009a9b0
mov r8d, 0x270
lea rdx, str.CRtkBssGen4PresetLoader::GetPresetId
lea rcx, str._s__d_RETURN_FALSE_ON_FALSE
call fcn.14005be10
jmp 0x14009aa07
mov qword [rsp + 0x60], rdi
mov r8, r14
lea rdx, [rsp + 0x60]
call fcn.14009a830
nop
mov rax, qword [rsp + 0x60]
cmp dword [rax - 0x10], 0
jne 0x14009aa2a
mov r8d, 0x273
lea rdx, str.CRtkBssGen4PresetLoader::GetPresetId
lea rcx, str._s__d_RETURN_FALSE_ON_FALSE
call fcn.14005be10
nop
mov rdx, qword [rsp + 0x60]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14009aa07
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rsp + 0x70]
add rdx, 0xffffffffffffffe8
lock xadd dword [rdx + 0x10], ebx
sub ebx, 1
jg 0x14009aa23
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
xor eax, eax
jmp 0x14009add9
mov qword [rbp - 0x80], rdi
lea rax, [rsp + 0x48]
mov qword [rsp + 0x30], rax
lea rdx, str.DriverVersion
lea rcx, [rsp + 0x48]
call fcn.140004560
mov rbx, rax
mov rsi, qword [rsp + 0x70]
add rsi, 0xffffffffffffffe8
mov rcx, rsi
call fcn.140006ba0
add rax, 0x18
mov qword [rsp + 0x38], rax
mov r9, rbx
lea r8, [rsp + 0x38]
mov rdx, 0xffffffff80000002
lea rcx, [rbp - 0x80]
call fcn.14007c740
nop
call fcn.140004f00
mov rcx, rax
test rax, rax
je 0x14009ae04
mov rax, qword [rax]
call qword [rax + reloc.OLEAUT32.dll_SafeArrayGetElement]
add rax, 0x18
mov qword [rbp - 0x70], rax
lea rdx, str.APOTunings
lea rcx, [rbp - 0x70]
call fcn.140062ab0
mov qword [rsp + 0x78], rdi
lea rax, [rsp + 0x30]
mov qword [rbp - 0x78], rax
lea rdx, str.TuningVersion
lea rcx, [rsp + 0x30]
call fcn.140004560
mov rbx, rax
mov r12, qword [rbp - 0x70]
lea rcx, [r12 - 0x18]
call fcn.140006ba0
add rax, 0x18
mov qword [rsp + 0x40], rax
mov r9, rbx
lea r8, [rsp + 0x40]
mov rdx, 0xffffffff80000002
lea rcx, [rsp + 0x78]
call fcn.14007c740
nop
mov rcx, rsi
call fcn.140006ba0
add rax, 0x18
mov qword [rbp - 0x78], rax
mov r8d, 0x27
lea rcx, [rbp - 0x78]
call fcn.14008a290
mov rax, qword [rsp + 0x78]
mov qword [rsp + 0x28], rax
mov rax, qword [rbp - 0x80]
mov qword [rsp + 0x20], rax
mov rbx, qword [rbp - 0x78]
mov r9, rbx
mov r8, qword [rsp + 0x60]
lea rdx, str._s__s_DrvVer_s_PreVer_s
mov rcx, r15
call fcn.140006c20
lea r8, [0x140114840]
lea rdx, [0x1400df7d4]
mov rcx, r15
call fcn.14000bad0
mov rax, qword [r15]
mov qword [rsp + 0x20], rax
mov r9, qword [r14 + 0x10]
mov r8d, 0x286
lea rdx, str.CRtkBssGen4PresetLoader::GetPresetId
lea rcx, str._s__d_EpId_s_PresetId_s
call fcn.14005be10
nop
lea rdx, [rbx - 0x18]
mov rbx, 0xffffffffffffffff
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14009abab
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rsp + 0x78]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14009abca
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov eax, ebx
lock xadd dword [r12 - 8], eax
sub eax, 1
jg 0x14009abe9
mov rcx, qword [r12 - 0x18]
mov rax, qword [rcx]
lea rdx, [r12 - 0x18]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rbp - 0x80]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14009ac07
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
mov rdx, qword [rsp + 0x60]
add rdx, 0xffffffffffffffe8
mov eax, ebx
lock xadd dword [rdx + 0x10], eax
sub eax, 1
jg 0x14009ac26
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
nop
lock xadd dword [rsi + 0x10], ebx
sub ebx, 1
jg 0x14009adcc
mov rcx, qword [rsi]
mov rax, qword [rcx]
mov rdx, rsi
call qword [rax + reloc.OLEAUT32.dll_VariantClear]
jmp 0x14009adcc
add eax, 0xfffffffe
cmp eax, 1
jbe 0x14009ac73
mov dword [rsp + 0x20], ecx
mov r9, qword [r14 + 0x10]
mov r8d, 0x2a9
lea rdx, str.CRtkBssGen4PresetLoader::GetPresetId
lea rcx, str._s__d_EpId_s_GetRtkGen4TuningType_d
call fcn.14005be10
jmp 0x14009adcc
xor eax, eax
mov qword [rbp - 0x60], rax
mov qword [rbp - 0x68], rdi
mov dword [rbp - 0x60], edi
mov qword [rbp - 0x58], rdi
mov r9d, 0x2001b
lea r8, str.SOFTWARERealtekAudioRtkAudUServiceBssGen4Preset
mov rdx, 0xffffffff80000002
lea rcx, [rbp - 0x68]
call fcn.140026e10
test eax, eax
jne 0x14009ad96
xor edx, edx
mov r8d, 0x2000
lea rcx, [rbp - 0x50]
call fcn.1400bffa0
mov dword [rsp + 0x58], 0x1ffe
lea rax, [rsp + 0x58]
mov qword [rsp + 0x28], rax
lea rax, [rbp - 0x50]
mov qword [rsp + 0x20], rax
lea r9, [rsp + 0x68]
xor r8d, r8d
lea rdx, str.GenaricPresetId
mov rsi, qword [rbp - 0x68]
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegQueryValueExW]
test eax, eax
jne 0x14009ad1c
mov eax, dword [rsp + 0x68]
dec eax
cmp eax, 1
ja 0x14009ad17
mov eax, dword [rsp + 0x58]
test eax, eax
je 0x14009ad36
test al, 1
jne 0x14009ad17
shr rax, 1
cmp word [rbp + rax*2 - 0x52], 0
je 0x14009ad3a
mov eax, SafeArrayDestroy
mov dword [rsp + 0x20], eax
lea r9, str.GenaricPresetId
mov r8d, 0x297
lea rcx, str._s__d_QueryStringValue_s_ret_d
jmp 0x14009ad77
mov word [rbp - 0x50], di
lea rax, [rbp - 0x50]
mov rbx, 0xffffffffffffffff
inc rbx
cmp word [rax + rbx*2], 0
jne 0x14009ad45
mov r8d, ebx
lea rdx, [rbp - 0x50]
mov rcx, r15
call fcn.140004940
mov rax, qword [r15]
mov qword [rsp + 0x20], rax
mov r9, qword [r14 + 0x10]
mov r8d, 0x29d
lea rcx, str._s__d_EpId_s_GenaricPresetId_s
lea rdx, str.CRtkBssGen4PresetLoader::GetPresetId
call fcn.14005be10
test rsi, rsi
je 0x14009adbe
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCloseKey]
mov rsi, rdi
jmp 0x14009adbe
mov dword [rsp + 0x20], eax
lea r9, str.SOFTWARERealtekAudioRtkAudUServiceBssGen4Preset
mov r8d, 0x2a4
lea rdx, str.CRtkBssGen4PresetLoader::GetPresetId
lea rcx, str._s__d_RegBSSGen4RootStore__s__ret_d
call fcn.14005be10
mov rsi, qword [rbp - 0x68]
test rsi, rsi
je 0x14009adcc
mov rcx, rsi
call qword [sym.imp.api_ms_win_core_registry_l1_1_0.dll_RegCloseKey]
mov rcx, qword [r15]
cmp dword [rcx - 0x10], 0
setne dil
mov eax, edi
mov rcx, qword [rbp + 0x1fb0]
xor rcx, rsp
call fcn.1400b96d0
lea r11, [rsp + 0x20c0]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r12
pop rdi
pop rbp
ret
mov ecx, 0x80004005
call fcn.140005030
nop
mov ecx, 0x80004005
call fcn.140005030
int3