63 lines
1.7 KiB
Plaintext
63 lines
1.7 KiB
Plaintext
///////////////////////////////////////////////////////////////////////////////
|
|
//
|
|
// Microsoft Research Singularity
|
|
//
|
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
|
//
|
|
// File: HalTimer.csi
|
|
//
|
|
// Note:
|
|
//
|
|
|
|
using System;
|
|
using System.Runtime.CompilerServices;
|
|
|
|
namespace Microsoft.Singularity.Hal
|
|
{
|
|
public class HalTimer
|
|
{
|
|
/// <summary>
|
|
/// Clear interrupt associated with timer.
|
|
/// </summary>
|
|
[NoHeapAllocation]
|
|
public void ClearInterrupt();
|
|
|
|
/// <value>
|
|
/// Maximum value accepted by SetNextInterrupt (in units of 100ns).
|
|
/// </value>
|
|
public long MaxInterruptInterval {
|
|
[NoHeapAllocation]
|
|
get;
|
|
}
|
|
|
|
/// <value>
|
|
/// Minimum value accepted by SetNextInterrupt (in units of 100ns).
|
|
/// </value>
|
|
public long MinInterruptInterval {
|
|
[NoHeapAllocation]
|
|
get;
|
|
}
|
|
|
|
/// <value>
|
|
/// Granularity of interrupt timeout (in units of 100ns).
|
|
/// </value>
|
|
public long InterruptIntervalGranularity {
|
|
[NoHeapAllocation]
|
|
get;
|
|
}
|
|
|
|
/// <summary>
|
|
/// Set relative time of next interrupt.
|
|
///
|
|
/// <param name="delta">Relative time of next interrupt in units
|
|
/// of 100ns. The time should be with the range between
|
|
/// from <c>SetNextInterruptMinDelta</c> to
|
|
/// <c>SetNextInterruptMaxDelta</c></param>.
|
|
/// <returns> true on success.</returns>
|
|
/// </summary>
|
|
[NoHeapAllocation]
|
|
public bool SetNextInterrupt(long delta);
|
|
}
|
|
|
|
} // namespace Microsoft.Singularity.Hal
|