PHYSICAL_ADDRESS

来源:互联网 发布:全能数据人生下载 编辑:程序博客网 时间:2024/06/07 11:33

这是我查找DDK的 ntdef.h 文件找到PHYSICAL_ADDRESS的定义:

.......................

.......................

typedef union _LARGE_INTEGER {
    struct {
        ULONG LowPart;
        LONG HighPart;
    };
    struct {
        ULONG LowPart;
        LONG HighPart;
    } u;
#endif //MIDL_PASS
    LONGLONG QuadPart;
} LARGE_INTEGER;

............................

............................

typedef LARGE_INTEGER PHYSICAL_ADDRESS, *PPHYSICAL_ADDRESS;



物理内存结构体PHYSICAL_ADDRESS(定义在ceddkh中,用64位来代表物理地址,对大多数32位的cpu,只需吧HighPart设置为0即可)。


LARGE_INTEGER Union

Represents a 64-bit signed integer value.

Note  Your C compiler may support 64-bit integers natively. For example, Microsoft Visual C++ supports the__int64 sized integer type. For more information, see the documentation included with your C compiler.

Syntax

Copy
typedef union _LARGE_INTEGER {  struct {    DWORD LowPart;    LONG  HighPart;  } ;  struct {    DWORD LowPart;    LONG  HighPart;  } u;  LONGLONG QuadPart;} LARGE_INTEGER, *PLARGE_INTEGER;

Members

LowPart

The low-order 32 bits.

HighPart

The high-order 32 bits.

u
LowPart

The low-order 32 bits.

HighPart

The high-order 32 bits.

QuadPart

A signed 64-bit integer.

Remarks

The LARGE_INTEGER structure is actually a union. If your compiler has built-in support for 64-bit integers, use theQuadPart member to store the 64-bit integer. Otherwise, use theLowPart and HighPart members to store the 64-bit integer.

0 0