Subversion Repositories Kolibri OS

Rev

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

Rev 9899 Rev 9958
Line 3... Line 3...
3
;; Copyright (C) KolibriOS team 2004-2022. All rights reserved. ;;
3
;; Copyright (C) KolibriOS team 2004-2022. All rights reserved. ;;
4
;; Distributed under terms of the GNU General Public License    ;;
4
;; Distributed under terms of the GNU General Public License    ;;
5
;;                                                              ;;
5
;;                                                              ;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
6
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
Line 7... Line 7...
7
 
7
 
Line 8... Line 8...
8
$Revision: 9899 $
8
$Revision: 9958 $
9
 
9
 
10
align 4
10
align 4
11
proc mem_test
11
proc mem_test
Line 408... Line 408...
408
.end_cpuid:
408
.end_cpuid:
409
        mov     eax, [cpu_type]
409
        mov     eax, [cpu_type]
410
        ret
410
        ret
411
endp
411
endp
Line 412... Line -...
412
 
-
 
413
ACPI_HI_RSDP_WINDOW_START  = 0x000E0000
-
 
414
ACPI_HI_RSDP_WINDOW_END    = 0x00100000
412
 
Line 415... Line 413...
415
ACPI_RSDP_CHECKSUM_LENGTH  = 20
413
ACPI_RSDP_CHECKSUM_LENGTH  = 20
416
 
414
 
417
proc acpi_locate_tables uses ebx esi edi
415
proc acpi_locate_tables uses ebx esi edi
Line 473... Line 471...
473
 
471
 
474
acpi_locate:
472
acpi_locate:
475
        push    ebx
473
        push    ebx
Line 476... Line -...
476
        push    edi
-
 
477
 
-
 
478
if defined UEFI
474
        push    edi
479
        ; UEFI loader knows where RSDP is
475
 
480
        mov     ebx, [BOOT_LO.acpi_rsdp]
476
        mov     ebx, [BOOT_LO.acpi_rsdp]
-
 
477
        test    ebx, ebx
481
        test    ebx, ebx
478
        jz      .done
482
        jz      .done
-
 
483
        call    .check
-
 
484
else
-
 
485
        movzx   ebx, word [0x40E]
-
 
486
        shl     ebx, 4
-
 
487
        lea     ecx, [ebx+1024]
-
 
488
        call    .check
-
 
489
 
-
 
490
        test    ebx, ebx
-
 
491
        jz      @F
-
 
492
        jmp     .done
-
 
493
 
-
 
494
@@:
-
 
495
        mov     ebx, ACPI_HI_RSDP_WINDOW_START
-
 
496
        mov     edi, ACPI_HI_RSDP_WINDOW_END
-
 
497
        call    .check
479
        mov     edi, ebx
498
end if
480
        call    .check
499
.done:
481
.done:
500
        mov     [acpi_rsdp_base - OS_BASE], ebx
482
        mov     [acpi_rsdp_base - OS_BASE], ebx
501
        test    ebx, ebx
483
        test    ebx, ebx