36 lines
1.1 KiB
Plaintext
36 lines
1.1 KiB
Plaintext
|
///////////////////////////////////////////////////////////////////////////////
|
||
|
//
|
||
|
// Microsoft Research Singularity - Singularity ABI
|
||
|
//
|
||
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||
|
//
|
||
|
// File: PciPortHandle.csi
|
||
|
//
|
||
|
// Note:
|
||
|
//
|
||
|
|
||
|
using System;
|
||
|
using System.Runtime.CompilerServices;
|
||
|
|
||
|
namespace Microsoft.Singularity.V1.Services
|
||
|
{
|
||
|
public struct PciPortHandle
|
||
|
{
|
||
|
public readonly UIntPtr id;
|
||
|
|
||
|
[NoHeapAllocation]
|
||
|
public static bool CreateImpl(PciPortHandle* h);
|
||
|
|
||
|
[NoHeapAllocation]
|
||
|
public static bool Dispose(PciPortHandle h);
|
||
|
|
||
|
public static bool Read8Impl(PciPortHandle h, int offset, byte* value);
|
||
|
public static bool Read16Impl(PciPortHandle h, int offset, ushort* value);
|
||
|
public static bool Read32Impl(PciPortHandle h, int offset, uint* value);
|
||
|
|
||
|
public static bool Write8(PciPortHandle h, int offset, byte value);
|
||
|
public static bool Write16(PciPortHandle h, int offset, ushort value);
|
||
|
public static bool Write32(PciPortHandle h, int offset, uint value);
|
||
|
}
|
||
|
}
|