forked from KolibriOS/kolibrios
hda driver: don't read uninitialized memory
git-svn-id: svn://kolibrios.org@4555 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
parent
3416e337d4
commit
35e895c7dc
@ -833,6 +833,7 @@ proc read_pin_defaults
|
||||
test eax, eax
|
||||
jz .err_out
|
||||
mov [codec.init_pins], eax
|
||||
mov [codec.num_pins], 0
|
||||
mov edi, eax
|
||||
;Asper ]
|
||||
|
||||
@ -855,19 +856,14 @@ end if
|
||||
mov [edi + HDA_PINCFG.nid], bx
|
||||
stdcall snd_hda_codec_read, ebx, 0, AC_VERB_GET_CONFIG_DEFAULT, 0
|
||||
mov [edi + HDA_PINCFG.cfg], eax
|
||||
add edi, HDA_PINCFG.sizeof
|
||||
inc [codec.num_pins]
|
||||
|
||||
.continue:
|
||||
add edi, HDA_PINCFG.sizeof
|
||||
inc ebx
|
||||
dec ecx
|
||||
jnz .next_node
|
||||
|
||||
;Asper [
|
||||
and ebx, 0xFFFF
|
||||
sub bx, [codec.start_nid]
|
||||
mov [codec.num_pins], ebx
|
||||
;Asper ]
|
||||
|
||||
pop edi edx ecx ebx
|
||||
xor eax, eax
|
||||
ret
|
||||
|
Loading…
Reference in New Issue
Block a user