VirtualBox

Ignore:
Timestamp:
Oct 28, 2015 8:17:18 PM (9 years ago)
Author:
vboxsync
Message:

EFI/Firmware: 'svn merge /vendor/edk2/UDK2010.SR1 /vendor/edk2/current .', reverting and removing files+dirs listed in ReadMe.vbox, resolving conflicts with help from ../UDK2014.SP1/. This is a raw untested merge.

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

Legend:

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

  • trunk/src/VBox/Devices/EFI/Firmware/SourceLevelDebugPkg/Library/DebugAgent/DebugAgentCommon/DebugTimer.c

    r48674 r58459  
    22  Code for debug timer to support debug agent library implementation.
    33
    4   Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
     4  Copyright (c) 2010 - 2014, Intel Corporation. All rights reserved.<BR>
    55  This program and the accompanying materials
    66  are licensed and made available under the terms and conditions of the BSD License
     
    1818  Initialize CPU local APIC timer.
    1919
     20  @return   32-bit Local APIC timer init count.
    2021**/
    21 VOID
     22UINT32
    2223InitializeDebugTimer (
    2324  VOID
     
    4243  InitializeApicTimer (ApicTimerDivisor, InitialCount, TRUE, DEBUG_TIMER_VECTOR);
    4344
    44   if (MultiProcessorDebugSupport) {
    45     mDebugMpContext.DebugTimerInitCount = InitialCount;
    46   }
     45  return InitialCount;
    4746}
    4847
     
    6665  )
    6766{
    68   BOOLEAN     OldInterruptState;
    6967  BOOLEAN     OldDebugTimerInterruptState;
    7068
    71   OldInterruptState = SaveAndDisableInterrupts ();
    7269  OldDebugTimerInterruptState = GetApicTimerInterruptState ();
    73  
    74   if (EnableStatus) {
    75     EnableApicTimerInterrupt ();
    76   } else {
    77     DisableApicTimerInterrupt ();
     70
     71  if (OldDebugTimerInterruptState != EnableStatus) {
     72    if (EnableStatus) {
     73      EnableApicTimerInterrupt ();
     74    } else {
     75      DisableApicTimerInterrupt ();
     76    }
     77    //
     78    // Validate the Debug Timer interrupt state
     79    // This will make additional delay after Local Apic Timer interrupt state is changed.
     80    // Thus, CPU could handle the potential pending interrupt of Local Apic timer.
     81    //
     82    while (GetApicTimerInterruptState () != EnableStatus) {
     83      CpuPause ();
     84    }
    7885  }
    7986
    80   SetInterruptState (OldInterruptState);
    8187  return OldDebugTimerInterruptState;
    8288}
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