Rev 2010 | Rev 2219 | Go to most recent revision | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed
Rev 2010 | Rev 2015 | ||
---|---|---|---|
Line 19... | Line 19... | ||
19 | ;; ;; |
19 | ;; ;; |
20 | ;; See file COPYING for details ;; |
20 | ;; See file COPYING for details ;; |
21 | ;; ;; |
21 | ;; ;; |
22 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
22 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
Line 23... | Line 23... | ||
23 | 23 | ||
Line 24... | Line 24... | ||
24 | $Revision: 2010 $ |
24 | $Revision: 2015 $ |
25 | 25 | ||
26 | ;*************************************************************************** |
26 | ;*************************************************************************** |
27 | ; Function |
27 | ; Function |
Line 650... | Line 650... | ||
650 | .return_ab: |
650 | .return_ab: |
651 | mov dword[esp + 20], ebx |
651 | mov dword[esp + 20], ebx |
652 | .return_a: |
652 | .return_a: |
653 | mov dword[esp + 32], eax |
653 | mov dword[esp + 32], eax |
654 | ret |
654 | ret |
- | 655 | ||
- | 656 | align 4 |
|
- | 657 | ||
- | 658 | pci_irq_fixup: |
|
- | 659 | ||
- | 660 | push ebp |
|
- | 661 | ||
- | 662 | stdcall load_file, dev_data_path |
|
- | 663 | test eax, eax |
|
- | 664 | jz .fail |
|
- | 665 | ||
- | 666 | push eax |
|
- | 667 | ||
- | 668 | mov esi, eax |
|
- | 669 | lea edi, [eax+ebx] |
|
- | 670 | ||
- | 671 | .iterate: |
|
- | 672 | ||
- | 673 | cmp esi, edi |
|
- | 674 | jae .done |
|
- | 675 | ||
- | 676 | mov eax, [esi] |
|
- | 677 | cmp eax, -1 |
|
- | 678 | je .done |
|
- | 679 | ||
- | 680 | movzx ebx, al |
|
- | 681 | movzx ebp, ah |
|
- | 682 | ||
- | 683 | stdcall pci_read32, ebp, ebx, 0 |
|
- | 684 | ||
- | 685 | cmp eax, [esi+4] |
|
- | 686 | jne .skip |
|
- | 687 | ||
- | 688 | mov eax, [esi+8] |
|
- | 689 | stdcall pci_write8, ebp, ebx, 0x3C, eax |
|
- | 690 | .skip: |
|
- | 691 | add esi, 16 |
|
- | 692 | jmp .iterate |
|
- | 693 | ||
- | 694 | .done: |
|
- | 695 | call kernel_free ;and pop file base from stack |
|
- | 696 | .fail: |
|
- | 697 | pop ebp |
|
- | 698 | ret |