Subversion Repositories Kolibri OS

Rev

Rev 3083 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 3083 Rev 5048
Line 50... Line 50...
50
  .step_size	      db ?    ; step_size=StepSize+1
50
	.step_size	    db ?    ; step_size=StepSize+1
51
  .maxDb	      dd ?    ; Max volume in Db.   maxDb=(num_steps*step_size/4*100)
51
	.maxDb		    dd ?    ; Max volume in Db.   maxDb=(num_steps*step_size/4*100)
52
}
52
}
Line 53... Line 53...
53
 
53
 
54
; retrieve the default device type from the default config value
-
 
55
 
54
; retrieve the default device type from the default config value
56
proc  defcfg_type stdcall, node:dword
55
proc defcfg_type stdcall, node:dword
57
    push     edx
56
	push	 edx
58
    mov      edx, [node]
57
	mov	 edx, [node]
59
    mov      eax, [edx + HDA_GNODE.def_cfg]
58
	mov	 eax, [edx + HDA_GNODE.def_cfg]
Line 91... Line 90...
91
    shr      eax, AC_DEFCFG_COLOR_SHIFT
90
	shr	 eax, AC_DEFCFG_COLOR_SHIFT
92
    pop      edx
91
	pop	 edx
93
    ret
92
	ret
94
endp
93
endp
Line 95... Line -...
95
 
-
 
96
 
94
 
97
; destructor
95
; destructor
98
proc  snd_hda_generic_free
96
proc snd_hda_generic_free
99
    push     eax ebx edx edi
97
	push	eax ebx edx edi
100
    ; free all widgets
98
	; free all widgets
Line 110... Line 108...
110
    mov      eax, [edx + HDA_GNODE.conn_list]
108
	mov	eax, [edx + HDA_GNODE.conn_list]
111
    lea      edi, [edx + HDA_GNODE.slist]
109
	lea	edi, [edx + HDA_GNODE.slist]
112
    cmp      eax, edi
110
	cmp	eax, edi
113
    je	     @f
111
	je	@f
114
    pusha
112
	pusha
115
    call     Kfree  ;free conn_list
113
	invoke	Kfree  ;free conn_list
116
    popa
114
	popa
117
  @@:
115
@@:
118
    mov      eax, edx
116
	mov	eax, edx
119
    mov      edx, [edx + HDA_GNODE.next]
117
	mov	edx, [edx + HDA_GNODE.next]
120
    pusha
118
	pusha
121
    call     Kfree  ;free node
119
	invoke	Kfree  ;free node
122
    popa
120
	popa
123
    jmp      .next
121
	jmp	.next
124
  .free_head:
122
.free_head:
125
    mov      eax, [spec.nid_list]
123
	mov	eax, [spec.nid_list]
126
    pusha
124
	pusha
127
    call     Kfree  ;free the very 1st node in the list
125
	invoke	Kfree  ;free the very 1st node in the list
128
    popa
126
	popa
129
    mov      [spec.nid_list], 0
127
	mov	[spec.nid_list], 0
130
  .out:
128
.out:
131
    pop      edi edx ebx eax
129
	pop	edi edx ebx eax
132
    ret
130
	ret
Line 136... Line 134...
136
; add a new widget node and read its attributes
134
; add a new widget node and read its attributes
137
proc  add_new_node stdcall, nid:dword
135
proc add_new_node stdcall, nid:dword
138
    push     ebx ecx edx edi esi
136
	push	ebx ecx edx edi esi
Line 139... Line 137...
139
 
137
 
140
    mov      eax, HDA_GNODE.sizeof
138
	mov	eax, HDA_GNODE.sizeof
141
    call     Kmalloc
139
	invoke	Kmalloc
142
    test     eax, eax
140
	test	eax, eax
Line 143... Line 141...
143
    jz	     .err_out	; Not enough memory
141
	jz	.err_out   ; Not enough memory
144
 
142
 
Line 158... Line 156...
158
    stdcall  get_wcaps_type, eax
156
	stdcall get_wcaps_type, eax
159
    mov      byte [edx + HDA_GNODE.type], al
157
	mov	byte [edx + HDA_GNODE.type], al
Line 160... Line 158...
160
 
158
 
161
    mov      eax, HDA_MAX_CONNECTIONS*2  ;HDA_MAX_CONNECTIONS * sizeof(word)
159
	mov	eax, HDA_MAX_CONNECTIONS*2  ;HDA_MAX_CONNECTIONS * sizeof(word)
162
    push     ebx ecx edx
160
	push	ebx ecx edx
163
    call     Kmalloc	;malloc temporary conn_list
161
	invoke	Kmalloc    ;malloc temporary conn_list
164
    pop      edx ecx ebx
162
	pop	edx ecx ebx
Line 165... Line 163...
165
    mov      edi, eax
163
	mov	edi, eax
166
 
164
 
Line 172... Line 170...
172
    cmp      ecx, 0
170
	cmp	ecx, 0
173
    jge      @f
171
	jge	@f
Line 174... Line 172...
174
 
172
 
175
    mov      eax, edx
173
	mov	eax, edx
176
    pusha
174
	pusha
177
    call     Kfree	;free node
175
	invoke	Kfree	   ;free node
178
    popa
176
	popa
179
    mov      eax, ecx
177
	mov	eax, ecx
180
    jmp      .out
178
	jmp	.out
Line 190... Line 188...
190
    jmp      .set_conn_list
188
	jmp	.set_conn_list
191
  @@:
189
@@:
192
    mov      eax, ecx
190
	mov	eax, ecx
193
    shl      ecx, 1
191
	shl	ecx, 1
194
    push     ebx ecx edx edi
192
	push	ebx ecx edx edi
195
    call     Kmalloc	;malloc conn_list
193
	invoke	Kmalloc    ;malloc conn_list
196
    pop      edi edx ecx ebx
194
	pop	edi edx ecx ebx
197
    shr      ecx, 1
195
	shr	ecx, 1
198
    test     eax, eax
196
	test	eax, eax
199
    jnz      @f
197
	jnz	@f
Line 200... Line 198...
200
 
198
 
201
    mov      eax, edi
199
	mov	eax, edi
202
    pusha
200
	pusha
203
    call     Kfree	;free temporary conn_list
201
	invoke	Kfree	   ;free temporary conn_list
204
    popa
202
	popa
205
    jmp      .err_out
203
	jmp	.err_out
206
  @@:
204
@@:
207
    mov      [edx + HDA_GNODE.conn_list], eax
205
	mov	[edx + HDA_GNODE.conn_list], eax
Line 262... Line 260...
262
;    ;try to beep here
260
;        ;try to beep here
263
;    stdcall  snd_hda_codec_read, [nid], 0, AC_VERB_GET_BEEP_CONTROL, 0 ;eax
261
;        stdcall snd_hda_codec_read, [nid], 0, AC_VERB_GET_BEEP_CONTROL, 0 ;eax
264
; if DEBUG
262
;if DEBUG
265
;    push     eax esi
263
;        push    eax esi
266
;    mov      esi, msgBeeperNid
264
;        mov     esi, msgBeeperNid
267
;    call     SysMsgBoardStr
265
;        invoke  SysMsgBoardStr
268
;    push     eax
266
;        push    eax
269
;    mov      eax, [nid]
267
;        mov     eax, [nid]
270
;    stdcall  fdword2str, 2
268
;        stdcall fdword2str, 2
271
;    call     SysMsgBoardStr
269
;        invoke  SysMsgBoardStr
272
;
270
;
273
;    mov      esi, msgBeeperValue
271
;        mov     esi, msgBeeperValue
274
;    call     SysMsgBoardStr
272
;        invoke  SysMsgBoardStr
275
;    pop      eax
273
;        pop     eax
276
;    stdcall  fdword2str, 2
274
;        stdcall fdword2str, 2
277
;    call     SysMsgBoardStr
275
;        invoke  SysMsgBoardStr
278
;
276
;
279
;    mov      esi, msgBeepNow
277
;        mov     esi, msgBeepNow
280
;    call     SysMsgBoardStr
278
;        invoke  SysMsgBoardStr
281
;    pop      esi eax
279
;        pop     esi eax
282
; end if
280
;end if
283
;    mov      ecx, 256*1
281
;        mov     ecx, 256*1
284
;  .next_tone:
282
;.next_tone:
285
;    dec      ecx
283
;        dec     ecx
Line 292... Line 290...
292
;  .end_beep:
290
;.end_beep:
293
;    stdcall  snd_hda_codec_read, [nid], 0, AC_VERB_GET_BEEP_CONTROL, 0 ;eax
291
;        stdcall snd_hda_codec_read, [nid], 0, AC_VERB_GET_BEEP_CONTROL, 0 ;eax
294
; if DEBUG
292
;if DEBUG
295
;    ;push     eax esi
293
;        ;push    eax esi
296
;    mov      esi, msgBeeperValue
294
;        mov     esi, msgBeeperValue
297
;    call     SysMsgBoardStr
295
;        invoke  SysMsgBoardStr
298
;    stdcall  fdword2str, 2
296
;        stdcall  fdword2str, 2
299
;    call     SysMsgBoardStr
297
;        invoke   SysMsgBoardStr
300
;    ;pop      esi eax
298
;        ;pop      esi eax
301
;  end if
299
;end if
302
;  .not_beeper:
300
;.not_beeper:
303
;    popa
301
;        popa
304
;;Asper+: Beeper ]
302
;;Asper+: Beeper ]
Line 365... Line 363...
365
    ;Asper+ ]
363
	;Asper+ ]
Line 366... Line 364...
366
 
364
 
367
  .out:
365
.out:
368
    mov      eax, edi
366
	mov	eax, edi
369
    pusha
367
	pusha
370
    call     Kfree     ;free temporary conn_list
368
	invoke	Kfree	  ;free temporary conn_list
371
    popa
369
	popa
372
    xor      eax, eax
370
	xor	eax, eax
373
    pop      esi edi edx ecx ebx
371
	pop	esi edi edx ecx ebx
Line 374... Line 372...
374
    ret
372
	ret
375
 
373
 
376
  .err_out:
374
.err_out:
377
    mov      eax, edx
375
	mov	eax, edx
378
    pusha
376
	pusha
379
    call     Kfree     ;free node
377
	invoke	Kfree	  ;free node
380
    popa
378
	popa
381
    xor      eax, eax
379
	xor	eax, eax
382
    dec      eax
380
	dec	eax
Line 409... Line 407...
409
    jge      .nid_ok
407
	jge	.nid_ok
410
  @@:
408
@@:
411
  if  FDEBUG
409
if  FDEBUG
412
    push     esi
410
	push	esi
413
    mov      esi, emsgInvalidAFGSubtree
411
	mov	esi, emsgInvalidAFGSubtree
414
    call     SysMsgBoardStr
412
	invoke	SysMsgBoardStr
415
    pop      esi
413
	pop	esi
416
  end if
414
end if
417
    xor      eax, eax
415
	xor	eax, eax
418
    dec      eax
416
	dec	eax
419
    jmp      .out
417
	jmp	.out
Line 435... Line 433...
435
  .out:
433
.out:
436
    pop      edx ecx ebx
434
	pop	edx ecx ebx
437
    ret
435
	ret
438
endp
436
endp
Line -... Line 437...
-
 
437
 
-
 
438
;Asper+[
-
 
439
proc print_afg_tree_nodes
-
 
440
	push	eax esi edi
-
 
441
	mov	esi, msgNodeSeq
-
 
442
	invoke	SysMsgBoardStr
-
 
443
 
-
 
444
	mov	edi, [spec.nid_list]
-
 
445
	test	edi, edi
-
 
446
	jz	.out
-
 
447
.next_node:
-
 
448
	movzx	eax, word [edi + HDA_GNODE.nid]
-
 
449
	mov	esi, msgNID
-
 
450
	invoke	SysMsgBoardStr
-
 
451
	stdcall fdword2str, 3
-
 
452
	invoke	SysMsgBoardStr
-
 
453
 
-
 
454
	mov	eax, [edi + HDA_GNODE.next]
-
 
455
	test	eax, eax
-
 
456
	jz	.out
-
 
457
 
-
 
458
	mov	edi, eax
-
 
459
	jmp	.next_node
-
 
460
.out:
-
 
461
	pop	edi esi eax
-
 
462
	ret
-
 
463
endp
Line 439... Line 464...
439
 
464
;Asper+]
440
 
465
 
441
; look for the node record for the given NID
466
; look for the node record for the given NID
442
proc  hda_get_node stdcall, nid:dword
467
proc hda_get_node stdcall, nid:dword
Line 478... Line 503...
478
    movzx    ebx, [esi + HDA_GNODE.nid]
503
	movzx	ebx, [esi + HDA_GNODE.nid]
479
    stdcall  snd_hda_codec_write, ebx, 0, AC_VERB_SET_EAPD_BTLENABLE, AC_EAPDBTL_EAPD ;eax
504
	stdcall snd_hda_codec_write, ebx, 0, AC_VERB_SET_EAPD_BTLENABLE, AC_EAPDBTL_EAPD ;eax
480
  if  DEBUG
505
if  DEBUG
481
    push     eax esi
506
	push	eax esi
482
    mov      esi, msgEnableEAPD
507
	mov	esi, msgEnableEAPD
483
    call     SysMsgBoardStr
508
	invoke	SysMsgBoardStr
484
    mov      eax, ebx
509
	mov	eax, ebx
485
    stdcall  fdword2str, 3
510
	stdcall fdword2str, 3
486
    call     SysMsgBoardStr
511
	invoke	SysMsgBoardStr
487
    pop      esi eax
512
	pop	esi eax
488
  end if
513
      end if
489
  .out:
514
.out:
490
    pop      esi ebx eax
515
	pop	esi ebx eax
491
    ret
516
	ret
492
endp
517
endp
493
;Asper+]
518
;Asper+]
Line 494... Line 519...
494
 
519
 
495
; unmute (and set max vol) the output amplifier
520
; unmute (and set max vol) the output amplifier
496
proc  unmute_output stdcall, node:dword
-
 
497
 
521
proc unmute_output stdcall, node:dword
498
    push     ebx ecx edx esi
522
	push	ebx ecx edx esi
499
    mov      esi, [node]
523
	mov	esi, [node]
500
    test     [esi + HDA_GNODE.wid_caps], AC_WCAP_OUT_AMP
524
	test	[esi + HDA_GNODE.wid_caps], AC_WCAP_OUT_AMP
501
    jz	     .out
525
	jz	.out
502
    movzx    eax, word [esi + HDA_GNODE.nid]
526
	movzx	eax, word [esi + HDA_GNODE.nid]
503
  if  DEBUG
527
if  DEBUG
504
    push     esi
528
	push	esi
505
    mov      esi, msgUnmuteOut
529
	mov	esi, msgUnmuteOut
506
    call     SysMsgBoardStr
530
	invoke	SysMsgBoardStr
507
    stdcall  fdword2str, 3
531
	stdcall fdword2str, 3
508
    call     SysMsgBoardStr
532
	invoke	SysMsgBoardStr
509
    pop      esi
533
	pop	esi
Line 510... Line 534...
510
  end if
534
end if
Line 526... Line 550...
526
    test     al, al
550
	test	al, al
527
    jz	     .out
551
	jz	.out
528
  if  DEBUG
552
if  DEBUG
529
    push     eax esi
553
	push	eax esi
530
    mov      esi, msgAmpVal
554
	mov	esi, msgAmpVal
531
    call     SysMsgBoardStr
555
	invoke	SysMsgBoardStr
532
    stdcall  fdword2str, 1
556
	stdcall fdword2str, 1
533
    call     SysMsgBoardStr
557
	invoke	SysMsgBoardStr
Line 534... Line 558...
534
 
558
 
535
    mov      esi, strSemicolon
559
	mov	esi, strSemicolon
536
    call     SysMsgBoardStr
560
	invoke	SysMsgBoardStr
537
    mov      eax, ecx
561
	mov	eax, ecx
538
    stdcall  fdword2str, 3
562
	stdcall fdword2str, 3
539
    call     SysMsgBoardStr
563
	invoke	SysMsgBoardStr
540
    pop      esi eax
564
	pop	esi eax
541
  end if
565
end if
542
    mov      [volume.out_amp_node], esi
-
 
543
    inc      al
566
	mov	[volume.out_amp_node], esi
544
    mov      [volume.num_steps], al
-
 
545
    inc      cl
567
	mov	[volume.num_steps], al
546
    mov      [volume.step_size], cl
568
	mov	[volume.step_size], cl
547
    mul      cl
-
 
548
    shr      eax, 2
569
	mul	cl
549
    imul     eax, 100
570
	imul	eax, (100/4)
550
    mov      [volume.maxDb], eax
-
 
551
 
571
	mov	[volume.maxDb], eax
552
  .out:
572
.out:
553
    xor      eax, eax
573
	xor	eax, eax
554
    pop      esi edx ecx ebx
574
	pop	esi edx ecx ebx
555
    ret
575
	ret
Line 564... Line 584...
564
    mov      esi, [node]
584
	mov	esi, [node]
565
    movzx    eax, word [esi + HDA_GNODE.nid]
585
	movzx	eax, word [esi + HDA_GNODE.nid]
566
  if  DEBUG
586
if  DEBUG
567
    push     eax esi
587
	push	eax esi
568
    mov      esi, msgUnmuteIn
588
	mov	esi, msgUnmuteIn
569
    call     SysMsgBoardStr
589
	invoke	SysMsgBoardStr
570
    stdcall  fdword2str, 3
590
	stdcall fdword2str, 3
571
    call     SysMsgBoardStr
591
	invoke	SysMsgBoardStr
572
    mov      esi, msgIdx
592
	mov	esi, msgIdx
573
    call     SysMsgBoardStr
593
	invoke	SysMsgBoardStr
574
    mov      eax, [index]
594
	mov	eax, [index]
575
    stdcall  fdword2str, 3
595
	stdcall fdword2str, 3
576
    call     SysMsgBoardStr
596
	invoke	SysMsgBoardStr
577
    pop      esi eax
597
	pop	esi eax
578
  end if
598
end if
Line 579... Line 599...
579
 
599
 
580
    mov      edx, [esi + HDA_GNODE.amp_in_caps]
600
	mov	edx, [esi + HDA_GNODE.amp_in_caps]
Line 597... Line 617...
597
	mov	esi, [node]
617
	mov	esi, [node]
598
	movzx	eax, word [esi + HDA_GNODE.nid]
618
	movzx	eax, word [esi + HDA_GNODE.nid]
599
	mov	ebx, [index]
619
	mov	ebx, [index]
600
     if DEBUG
620
if DEBUG
601
	mov	esi, msgConnect
621
	mov	esi, msgConnect
602
	call	SysMsgBoardStr
622
	invoke	SysMsgBoardStr
603
	stdcall fdword2str, 3
623
	stdcall fdword2str, 3
604
	call	SysMsgBoardStr
624
	invoke	SysMsgBoardStr
Line 605... Line 625...
605
 
625
 
606
	mov	esi, msgIdx
626
	mov	esi, msgIdx
607
	call	SysMsgBoardStr
627
	invoke	SysMsgBoardStr
608
	push	eax
628
	push	eax
609
	mov	eax, ebx
629
	mov	eax, ebx
610
	stdcall fdword2str, 3
630
	stdcall fdword2str, 3
611
	call	SysMsgBoardStr
631
	invoke	SysMsgBoardStr
612
	pop	eax
632
	pop	eax
613
     end if
633
end if
614
	stdcall snd_hda_codec_write, eax, 0, AC_VERB_SET_CONNECT_SEL, ebx
634
	stdcall snd_hda_codec_write, eax, 0, AC_VERB_SET_CONNECT_SEL, ebx
615
	pop	esi ebx
635
	pop	esi ebx
Line 628... Line 648...
628
    mov      eax, [esi + HDA_GNODE.next]
648
	mov	eax, [esi + HDA_GNODE.next]
629
    test     eax, eax
649
	test	eax, eax
630
    jz	     .out
650
	jz	.out
631
    mov      esi, eax
651
	mov	esi, eax
632
    jmp      .next_node
652
	jmp	.next_node
633
 
-
 
634
  .out:
653
.out:
635
    pop      esi eax
654
	pop	esi eax
636
    ret
655
	ret
637
endp
656
endp
Line 659... Line 678...
659
	test	ebx, AC_WCAP_DIGITAL
678
	test	ebx, AC_WCAP_DIGITAL
660
	jz	@f
679
	jz	@f
661
     if DEBUG
680
if DEBUG
662
	push	esi
681
	push	esi
663
	mov	esi, msgSkipDigitalOutNode
682
	mov	esi, msgSkipDigitalOutNode
664
	call	SysMsgBoardStr
683
	invoke	SysMsgBoardStr
665
	stdcall fdword2str, 3
684
	stdcall fdword2str, 3
666
	call	SysMsgBoardStr
685
	invoke	SysMsgBoardStr
667
	pop	esi
686
	pop	esi
668
     end if
687
end if
669
	jmp	.ret_zero
688
	jmp	.ret_zero
670
  @@:
689
@@:
671
     if DEBUG
690
if DEBUG
672
	push	eax esi
691
	push	eax esi
673
	mov	esi, msgAudOutFound
692
	mov	esi, msgAudOutFound
674
	call	SysMsgBoardStr
693
	invoke	SysMsgBoardStr
675
	stdcall fdword2str, 3
694
	stdcall fdword2str, 3
676
	call	SysMsgBoardStr
695
	invoke	SysMsgBoardStr
677
	pop	esi eax
696
	pop	esi eax
678
     end if
697
end if
Line 679... Line 698...
679
 
698
 
680
	push	eax
699
	push	eax
Line 766... Line 785...
766
	jne	.continue
785
	jne	.continue
Line 767... Line 786...
767
 
786
 
768
	test	[esi + HDA_GNODE.wid_caps], AC_WCAP_DIGITAL
787
	test	[esi + HDA_GNODE.wid_caps], AC_WCAP_DIGITAL
769
	jnz	.continue ; skip SPDIF
788
	jnz	.continue ; skip SPDIF
770
  @@:
789
@@:
-
 
790
	push	eax
-
 
791
	movzx	eax, [esi + HDA_GNODE.nid]
-
 
792
	stdcall snd_hda_enable_pin_sense, eax, eax	;Asper+: enable unsolicited events for the output pin
-
 
793
	pop	eax
771
	; output as default?
794
 
772
if DEBUG
795
if DEBUG
773
   pusha
796
	pusha
774
;   push   esi
797
;        push    esi
775
;   mov    esi, msgPin_Nid
798
;        mov     esi, msgPin_Nid
776
;   call   SysMsgBoardStr
799
;        invoke  SysMsgBoardStr
777
;   pop    esi
800
;        pop     esi
778
   movzx  eax, [esi + HDA_GNODE.nid]
801
	movzx	eax, [esi + HDA_GNODE.nid]
779
   movzx  ebx, [esi + HDA_GNODE.pin_ctl]
802
	movzx	ebx, [esi + HDA_GNODE.pin_ctl]
780
   mov	  ecx, [esi + HDA_GNODE.pin_caps]
803
	mov	ecx, [esi + HDA_GNODE.pin_caps]
781
   mov	  edx, [esi + HDA_GNODE.def_cfg]
804
	mov	edx, [esi + HDA_GNODE.def_cfg]
782
   mov	  edi, [esi + HDA_GNODE.amp_out_caps]
805
	mov	edi, [esi + HDA_GNODE.amp_out_caps]
783
   mov	  esi, msgPin_Nid
806
	mov	esi, msgPin_Nid
784
   call   SysMsgBoardStr
807
	invoke	SysMsgBoardStr
785
   stdcall fdword2str, 3
808
	stdcall fdword2str, 3
Line 786... Line 809...
786
   call   SysMsgBoardStr
809
	invoke	SysMsgBoardStr
787
 
810
 
788
   mov	  esi, msgPin_Ctl
811
	mov	esi, msgPin_Ctl
789
   call   SysMsgBoardStr
812
	invoke	SysMsgBoardStr
790
   mov	  eax, ebx
813
	mov	eax, ebx
Line 791... Line 814...
791
   stdcall fdword2str, 2
814
	stdcall fdword2str, 2
792
   call   SysMsgBoardStr
815
	invoke	SysMsgBoardStr
793
 
816
 
794
   mov	  esi, msgPin_Caps
817
	mov	esi, msgPin_Caps
795
   call   SysMsgBoardStr
818
	invoke	SysMsgBoardStr
Line 796... Line 819...
796
   mov	  eax, ecx
819
	mov	eax, ecx
797
   stdcall fdword2str, 2
820
	stdcall fdword2str, 2
798
   call   SysMsgBoardStr
821
	invoke	SysMsgBoardStr
799
 
822
 
800
   mov	  esi, msgDef_Cfg
823
	mov	esi, msgDef_Cfg
Line 801... Line 824...
801
   call   SysMsgBoardStr
824
	invoke	SysMsgBoardStr
802
   mov	  eax, edx
825
	mov    eax, edx
803
   stdcall fdword2str, 2
826
	stdcall fdword2str, 2
804
   call   SysMsgBoardStr
827
	invoke	SysMsgBoardStr
805
 
828
 
806
   mov	  esi, msgAmp_Out_Caps
-
 
807
   call   SysMsgBoardStr
829
	mov    esi, msgAmp_Out_Caps
808
   mov	  eax, edi
830
	invoke	SysMsgBoardStr
-
 
831
	mov    eax, edi
809
   stdcall fdword2str, 2
832
	stdcall fdword2str, 2
810
   call   SysMsgBoardStr
833
	invoke	SysMsgBoardStr
-
 
834
	popa
-
 
835
end if
-
 
836
	; output as default?
-
 
837
;        test    [esi + HDA_GNODE.pin_ctl], AC_PINCTL_OUT_EN
811
 
838
;        jz      .continue
812
   popa
839
.use_dac0:
Line 813... Line 840...
813
end if
840
	cmp	[spec.dac_node], 0
814
;       test    [esi + HDA_GNODE.pin_ctl], AC_PINCTL_OUT_EN
841
	jne	.use_dac1
815
;       jz      .continue
842
 
816
	stdcall clear_check_flags
843
	stdcall clear_check_flags
817
	stdcall parse_output_path, esi, 0
844
	stdcall parse_output_path, esi, 0
-
 
845
 
818
 
846
	test	eax, eax
819
	test	eax, eax
847
	jnz	@f
820
	jnz	@f
848
	mov	edx, [spec.out_pin_node]
821
	mov	edx, [spec.out_pin_node]
849
	test	edx, edx
822
	test	edx, edx
850
	jz	@f
Line 897... Line 925...
897
	test	eax, eax
925
	test	eax, eax
898
	jnz	@f
926
	jnz	@f
899
     if DEBUG
927
if DEBUG
900
	push	esi
928
	push	esi
901
	mov	esi, emsgNoProperOutputPathFound
929
	mov	esi, emsgNoProperOutputPathFound
902
	call	SysMsgBoardStr
930
	invoke	SysMsgBoardStr
903
	pop	esi
931
	pop	esi
904
     end if
932
end if
905
  @@:
933
@@:
906
	pop	edx
934
	pop	edx
907
	xor	eax, eax
935
	xor	eax, eax
Line 919... Line 947...
919
 
947
 
920
	stdcall build_afg_tree
948
	stdcall build_afg_tree
921
	cmp	eax, 0
949
	cmp	eax, 0
Line -... Line 950...
-
 
950
	jl	.error
-
 
951
 
-
 
952
if  FDEBUG
-
 
953
	stdcall print_afg_tree_nodes ;Asper+
922
	jl	.error
954
end if
923
 
955
 
924
	stdcall parse_output
956
	stdcall parse_output
925
	xor	eax, eax
957
	xor	eax, eax
926
  .out:
958
.out: