VirtualBox

Ignore:
Timestamp:
Apr 14, 2023 3:17:44 PM (22 months ago)
Author:
vboxsync
Message:

Devices/EFI/FirmwareNew: Update to edk2-stable202302 and make it build, bugref:4643

Location:
trunk/src/VBox/Devices/EFI/FirmwareNew
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/EFI/FirmwareNew

  • trunk/src/VBox/Devices/EFI/FirmwareNew/OvmfPkg/Sec/X64/SecEntry.nasm

    • Property svn:mime-type set to text/x-asm
    r80721 r99404  
    1616
    1717extern ASM_PFX(SecCoreStartupWithStack)
     18
     19%macro  tdcall  0
     20  db  0x66, 0x0f, 0x01, 0xcc
     21%endmacro
    1822
    1923;
     
    3539global ASM_PFX(_ModuleEntryPoint)
    3640ASM_PFX(_ModuleEntryPoint):
     41
     42    ;
     43    ; Guest type is stored in OVMF_WORK_AREA
     44    ;
     45    %define OVMF_WORK_AREA        FixedPcdGet32 (PcdOvmfWorkAreaBase)
     46    %define VM_GUEST_TYPE_TDX     2
     47    mov     eax, OVMF_WORK_AREA
     48    cmp     byte[eax], VM_GUEST_TYPE_TDX
     49    jne     InitStack
     50
     51    %define TDCALL_TDINFO         1
     52    mov     rax, TDCALL_TDINFO
     53    tdcall
     54
     55    ;
     56    ; R8  [31:0]  NUM_VCPUS
     57    ;     [63:32] MAX_VCPUS
     58    ; R9  [31:0]  VCPU_INDEX
     59    ; Td Guest set the VCPU0 as the BSP, others are the APs
     60    ; APs jump to spinloop and get released by DXE's MpInitLib
     61    ;
     62    mov     rax, r9
     63    and     rax, 0xffff
     64    test    rax, rax
     65    jz      InitStack
     66    mov     rsp, FixedPcdGet32 (PcdOvmfSecGhcbBackupBase)
     67    jmp     ParkAp
     68
     69InitStack:
    3770
    3871    ;
     
    68101    call    ASM_PFX(SecCoreStartupWithStack)
    69102
     103%include "../../IntelTdx/Sec/X64/IntelTdxAPs.nasm"
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette