Staging: hv: remove PVOID typedef
The PVOID typedef is now removed from the Hyper-V driver code. Cc: Hank Janssen <hjanssen@microsoft.com> Cc: Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
This commit is contained in:
Родитель
2be1301b7d
Коммит
8282c40014
|
@ -32,7 +32,7 @@
|
|||
//
|
||||
static int
|
||||
VmbusChannelCreateGpadlHeader(
|
||||
PVOID Kbuffer, // must be phys and virt contiguous
|
||||
void * Kbuffer, // must be phys and virt contiguous
|
||||
UINT32 Size, // page-size multiple
|
||||
VMBUS_CHANNEL_MSGINFO **msgInfo,
|
||||
UINT32 *MessageCount
|
||||
|
@ -204,10 +204,10 @@ VmbusChannelOpen(
|
|||
VMBUS_CHANNEL *NewChannel,
|
||||
UINT32 SendRingBufferSize,
|
||||
UINT32 RecvRingBufferSize,
|
||||
PVOID UserData,
|
||||
void * UserData,
|
||||
UINT32 UserDataLen,
|
||||
PFN_CHANNEL_CALLBACK pfnOnChannelCallback,
|
||||
PVOID Context
|
||||
void * Context
|
||||
)
|
||||
{
|
||||
int ret=0;
|
||||
|
@ -392,7 +392,7 @@ Description:
|
|||
--*/
|
||||
static int
|
||||
VmbusChannelCreateGpadlHeader(
|
||||
PVOID Kbuffer, // from kmalloc()
|
||||
void * Kbuffer, // from kmalloc()
|
||||
UINT32 Size, // page-size multiple
|
||||
VMBUS_CHANNEL_MSGINFO **MsgInfo,
|
||||
UINT32 *MessageCount)
|
||||
|
@ -515,7 +515,7 @@ Description:
|
|||
int
|
||||
VmbusChannelEstablishGpadl(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
PVOID Kbuffer, // from kmalloc()
|
||||
void * Kbuffer, // from kmalloc()
|
||||
UINT32 Size, // page-size multiple
|
||||
UINT32 *GpadlHandle
|
||||
)
|
||||
|
@ -752,7 +752,7 @@ Description:
|
|||
int
|
||||
VmbusChannelSendPacket(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
const PVOID Buffer,
|
||||
const void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId,
|
||||
VMBUS_PACKET_TYPE Type,
|
||||
|
@ -820,7 +820,7 @@ VmbusChannelSendPacketPageBuffer(
|
|||
VMBUS_CHANNEL *Channel,
|
||||
PAGE_BUFFER PageBuffers[],
|
||||
UINT32 PageCount,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId
|
||||
)
|
||||
|
@ -902,7 +902,7 @@ int
|
|||
VmbusChannelSendPacketMultiPageBuffer(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
MULTIPAGE_BUFFER *MultiPageBuffer,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId
|
||||
)
|
||||
|
@ -984,7 +984,7 @@ Description:
|
|||
int
|
||||
VmbusChannelRecvPacket(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* BufferActualLen,
|
||||
UINT64* RequestId
|
||||
|
@ -1061,7 +1061,7 @@ Description:
|
|||
int
|
||||
VmbusChannelRecvPacketRaw(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* BufferActualLen,
|
||||
UINT64* RequestId
|
||||
|
|
|
@ -67,10 +67,10 @@ VmbusChannelOpen(
|
|||
VMBUS_CHANNEL *Channel,
|
||||
UINT32 SendRingBufferSize,
|
||||
UINT32 RecvRingBufferSize,
|
||||
PVOID UserData,
|
||||
void * UserData,
|
||||
UINT32 UserDataLen,
|
||||
PFN_CHANNEL_CALLBACK pfnOnChannelCallback,
|
||||
PVOID Context
|
||||
void * Context
|
||||
);
|
||||
|
||||
static void
|
||||
|
@ -81,7 +81,7 @@ VmbusChannelClose(
|
|||
static int
|
||||
VmbusChannelSendPacket(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
const PVOID Buffer,
|
||||
const void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId,
|
||||
VMBUS_PACKET_TYPE Type,
|
||||
|
@ -93,7 +93,7 @@ VmbusChannelSendPacketPageBuffer(
|
|||
VMBUS_CHANNEL *Channel,
|
||||
PAGE_BUFFER PageBuffers[],
|
||||
UINT32 PageCount,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId
|
||||
);
|
||||
|
@ -102,7 +102,7 @@ static int
|
|||
VmbusChannelSendPacketMultiPageBuffer(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
MULTIPAGE_BUFFER *MultiPageBuffer,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId
|
||||
);
|
||||
|
@ -110,7 +110,7 @@ VmbusChannelSendPacketMultiPageBuffer(
|
|||
static int
|
||||
VmbusChannelEstablishGpadl(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
PVOID Kbuffer, // from kmalloc()
|
||||
void * Kbuffer, // from kmalloc()
|
||||
UINT32 Size, // page-size multiple
|
||||
UINT32 *GpadlHandle
|
||||
);
|
||||
|
@ -124,7 +124,7 @@ VmbusChannelTeardownGpadl(
|
|||
static int
|
||||
VmbusChannelRecvPacket(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* BufferActualLen,
|
||||
UINT64* RequestId
|
||||
|
@ -133,7 +133,7 @@ VmbusChannelRecvPacket(
|
|||
static int
|
||||
VmbusChannelRecvPacketRaw(
|
||||
VMBUS_CHANNEL *Channel,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* BufferActualLen,
|
||||
UINT64* RequestId
|
||||
|
|
|
@ -28,10 +28,10 @@ IVmbusChannelOpen(
|
|||
PDEVICE_OBJECT Device,
|
||||
UINT32 SendBufferSize,
|
||||
UINT32 RecvRingBufferSize,
|
||||
PVOID UserData,
|
||||
void * UserData,
|
||||
UINT32 UserDataLen,
|
||||
VMBUS_CHANNEL_CALLBACK ChannelCallback,
|
||||
PVOID Context
|
||||
void * Context
|
||||
)
|
||||
{
|
||||
return VmbusChannelOpen( (VMBUS_CHANNEL*)Device->context,
|
||||
|
@ -56,7 +56,7 @@ IVmbusChannelClose(
|
|||
static int
|
||||
IVmbusChannelSendPacket(
|
||||
PDEVICE_OBJECT Device,
|
||||
const PVOID Buffer,
|
||||
const void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId,
|
||||
UINT32 Type,
|
||||
|
@ -76,7 +76,7 @@ IVmbusChannelSendPacketPageBuffer(
|
|||
PDEVICE_OBJECT Device,
|
||||
PAGE_BUFFER PageBuffers[],
|
||||
UINT32 PageCount,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId
|
||||
)
|
||||
|
@ -93,7 +93,7 @@ static int
|
|||
IVmbusChannelSendPacketMultiPageBuffer(
|
||||
PDEVICE_OBJECT Device,
|
||||
MULTIPAGE_BUFFER *MultiPageBuffer,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId
|
||||
)
|
||||
|
@ -108,7 +108,7 @@ IVmbusChannelSendPacketMultiPageBuffer(
|
|||
static int
|
||||
IVmbusChannelRecvPacket (
|
||||
PDEVICE_OBJECT Device,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* BufferActualLen,
|
||||
UINT64* RequestId
|
||||
|
@ -124,7 +124,7 @@ IVmbusChannelRecvPacket (
|
|||
static int
|
||||
IVmbusChannelRecvPacketRaw(
|
||||
PDEVICE_OBJECT Device,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* BufferActualLen,
|
||||
UINT64* RequestId
|
||||
|
@ -140,7 +140,7 @@ IVmbusChannelRecvPacketRaw(
|
|||
static int
|
||||
IVmbusChannelEstablishGpadl(
|
||||
PDEVICE_OBJECT Device,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* GpadlHandle
|
||||
)
|
||||
|
|
|
@ -82,12 +82,12 @@ VmbusChannelOnVersionResponse(
|
|||
|
||||
static void
|
||||
VmbusChannelProcessOffer(
|
||||
PVOID context
|
||||
void * context
|
||||
);
|
||||
|
||||
static void
|
||||
VmbusChannelProcessRescindOffer(
|
||||
PVOID context
|
||||
void * context
|
||||
);
|
||||
|
||||
|
||||
|
@ -233,7 +233,7 @@ Description:
|
|||
--*/
|
||||
static void
|
||||
VmbusChannelProcessOffer(
|
||||
PVOID context
|
||||
void * context
|
||||
)
|
||||
{
|
||||
int ret=0;
|
||||
|
@ -317,7 +317,7 @@ Description:
|
|||
--*/
|
||||
static void
|
||||
VmbusChannelProcessRescindOffer(
|
||||
PVOID context
|
||||
void * context
|
||||
)
|
||||
{
|
||||
VMBUS_CHANNEL* channel=(VMBUS_CHANNEL*)context;
|
||||
|
|
|
@ -34,7 +34,7 @@
|
|||
|
||||
|
||||
|
||||
typedef void (*PFN_CHANNEL_CALLBACK)(PVOID context);
|
||||
typedef void (*PFN_CHANNEL_CALLBACK)(void * context);
|
||||
|
||||
typedef enum {
|
||||
CHANNEL_OFFER_STATE,
|
||||
|
@ -70,7 +70,7 @@ typedef struct _VMBUS_CHANNEL {
|
|||
//HANDLE dataWorkQueue;
|
||||
|
||||
PFN_CHANNEL_CALLBACK OnChannelCallback;
|
||||
PVOID ChannelCallbackContext;
|
||||
void * ChannelCallbackContext;
|
||||
|
||||
} VMBUS_CHANNEL;
|
||||
|
||||
|
|
|
@ -103,7 +103,7 @@ VmbusConnect(
|
|||
msg->VMBusVersionRequested = VMBUS_REVISION_NUMBER;
|
||||
msg->InterruptPage = GetPhysicalAddress(gVmbusConnection.InterruptPage);
|
||||
msg->MonitorPage1 = GetPhysicalAddress(gVmbusConnection.MonitorPages);
|
||||
msg->MonitorPage2 = GetPhysicalAddress((PVOID)((ULONG_PTR)gVmbusConnection.MonitorPages + PAGE_SIZE));
|
||||
msg->MonitorPage2 = GetPhysicalAddress((void *)((ULONG_PTR)gVmbusConnection.MonitorPages + PAGE_SIZE));
|
||||
|
||||
// Add to list before we send the request since we may receive the response
|
||||
// before returning from this routine
|
||||
|
@ -290,7 +290,7 @@ Description:
|
|||
--*/
|
||||
static void
|
||||
VmbusProcessChannelEvent(
|
||||
PVOID context
|
||||
void * context
|
||||
)
|
||||
{
|
||||
VMBUS_CHANNEL* channel;
|
||||
|
@ -385,7 +385,7 @@ Description:
|
|||
--*/
|
||||
int
|
||||
VmbusPostMessage(
|
||||
PVOID buffer,
|
||||
void * buffer,
|
||||
SIZE_T bufferLen
|
||||
)
|
||||
{
|
||||
|
|
|
@ -396,7 +396,7 @@ HV_STATUS
|
|||
HvPostMessage(
|
||||
HV_CONNECTION_ID connectionId,
|
||||
HV_MESSAGE_TYPE messageType,
|
||||
PVOID payload,
|
||||
void * payload,
|
||||
SIZE_T payloadSize
|
||||
)
|
||||
{
|
||||
|
|
|
@ -162,7 +162,7 @@ static HV_STATUS
|
|||
HvPostMessage(
|
||||
HV_CONNECTION_ID connectionId,
|
||||
HV_MESSAGE_TYPE messageType,
|
||||
PVOID payload,
|
||||
void * payload,
|
||||
SIZE_T payloadSize
|
||||
);
|
||||
|
||||
|
|
|
@ -59,7 +59,7 @@ NetVscOnCleanup(
|
|||
|
||||
static void
|
||||
NetVscOnChannelCallback(
|
||||
PVOID context
|
||||
void * context
|
||||
);
|
||||
|
||||
static int
|
||||
|
@ -107,7 +107,7 @@ NetVscOnReceive(
|
|||
|
||||
static void
|
||||
NetVscOnReceiveCompletion(
|
||||
PVOID Context
|
||||
void * Context
|
||||
);
|
||||
|
||||
static void
|
||||
|
@ -1337,7 +1337,7 @@ retry_send_cmplt:
|
|||
//
|
||||
static void
|
||||
NetVscOnReceiveCompletion(
|
||||
PVOID Context)
|
||||
void * Context)
|
||||
{
|
||||
NETVSC_PACKET *packet = (NETVSC_PACKET*)Context;
|
||||
DEVICE_OBJECT *device = (DEVICE_OBJECT*)packet->Device;
|
||||
|
@ -1393,7 +1393,7 @@ NetVscOnReceiveCompletion(
|
|||
|
||||
void
|
||||
NetVscOnChannelCallback(
|
||||
PVOID Context
|
||||
void * Context
|
||||
)
|
||||
{
|
||||
const int netPacketSize=2048;
|
||||
|
|
|
@ -65,13 +65,13 @@ typedef struct _NETVSC_DEVICE {
|
|||
HANDLE ReceivePacketListLock;
|
||||
|
||||
// Send buffer allocated by us but manages by NetVSP
|
||||
PVOID SendBuffer;
|
||||
void * SendBuffer;
|
||||
UINT32 SendBufferSize;
|
||||
UINT32 SendBufferGpadlHandle;
|
||||
UINT32 SendSectionSize;
|
||||
|
||||
// Receive buffer allocated by us but manages by NetVSP
|
||||
PVOID ReceiveBuffer;
|
||||
void * ReceiveBuffer;
|
||||
UINT32 ReceiveBufferSize;
|
||||
UINT32 ReceiveBufferGpadlHandle;
|
||||
UINT32 ReceiveSectionCount;
|
||||
|
|
|
@ -156,10 +156,10 @@ Description:
|
|||
Get the start of the ring buffer
|
||||
|
||||
--*/
|
||||
static inline PVOID
|
||||
static inline void *
|
||||
GetRingBuffer(RING_BUFFER_INFO* RingInfo)
|
||||
{
|
||||
return (PVOID)RingInfo->RingBuffer->Buffer;
|
||||
return (void *)RingInfo->RingBuffer->Buffer;
|
||||
}
|
||||
|
||||
|
||||
|
@ -228,13 +228,13 @@ static UINT32
|
|||
CopyToRingBuffer(
|
||||
RING_BUFFER_INFO *RingInfo,
|
||||
UINT32 StartWriteOffset,
|
||||
PVOID Src,
|
||||
void * Src,
|
||||
UINT32 SrcLen);
|
||||
|
||||
static UINT32
|
||||
CopyFromRingBuffer(
|
||||
RING_BUFFER_INFO *RingInfo,
|
||||
PVOID Dest,
|
||||
void * Dest,
|
||||
UINT32 DestLen,
|
||||
UINT32 StartReadOffset);
|
||||
|
||||
|
@ -486,7 +486,7 @@ Description:
|
|||
int
|
||||
RingBufferRead(
|
||||
RING_BUFFER_INFO* InRingInfo,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32 Offset
|
||||
)
|
||||
|
@ -557,10 +557,10 @@ UINT32
|
|||
CopyToRingBuffer(
|
||||
RING_BUFFER_INFO *RingInfo,
|
||||
UINT32 StartWriteOffset,
|
||||
PVOID Src,
|
||||
void * Src,
|
||||
UINT32 SrcLen)
|
||||
{
|
||||
PVOID ringBuffer=GetRingBuffer(RingInfo);
|
||||
void * ringBuffer=GetRingBuffer(RingInfo);
|
||||
UINT32 ringBufferSize=GetRingBufferSize(RingInfo);
|
||||
UINT32 fragLen;
|
||||
|
||||
|
@ -597,11 +597,11 @@ Description:
|
|||
UINT32
|
||||
CopyFromRingBuffer(
|
||||
RING_BUFFER_INFO *RingInfo,
|
||||
PVOID Dest,
|
||||
void * Dest,
|
||||
UINT32 DestLen,
|
||||
UINT32 StartReadOffset)
|
||||
{
|
||||
PVOID ringBuffer=GetRingBuffer(RingInfo);
|
||||
void * ringBuffer=GetRingBuffer(RingInfo);
|
||||
UINT32 ringBufferSize=GetRingBufferSize(RingInfo);
|
||||
|
||||
UINT32 fragLen;
|
||||
|
|
|
@ -28,7 +28,7 @@
|
|||
#include "include/osd.h"
|
||||
|
||||
typedef struct _SG_BUFFER_LIST {
|
||||
PVOID Data;
|
||||
void * Data;
|
||||
UINT32 Length;
|
||||
} SG_BUFFER_LIST;
|
||||
|
||||
|
@ -72,7 +72,7 @@ typedef struct _RING_BUFFER_DEBUG_INFO {
|
|||
static int
|
||||
RingBufferInit(
|
||||
RING_BUFFER_INFO *RingInfo,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen
|
||||
);
|
||||
|
||||
|
@ -91,14 +91,14 @@ RingBufferWrite(
|
|||
static int
|
||||
RingBufferPeek(
|
||||
RING_BUFFER_INFO *RingInfo,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen
|
||||
);
|
||||
|
||||
static int
|
||||
RingBufferRead(
|
||||
RING_BUFFER_INFO *RingInfo,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32 Offset
|
||||
);
|
||||
|
|
|
@ -118,7 +118,7 @@ StorVscOnCleanup(
|
|||
|
||||
static void
|
||||
StorVscOnChannelCallback(
|
||||
PVOID Context
|
||||
void * Context
|
||||
);
|
||||
|
||||
static void
|
||||
|
@ -530,7 +530,7 @@ StorVscConnectToVsp(
|
|||
ret = Device->Driver->VmbusChannelInterface.Open(Device,
|
||||
storDriver->RingBufferSize,
|
||||
storDriver->RingBufferSize,
|
||||
(PVOID)&props,
|
||||
(void *)&props,
|
||||
sizeof(VMSTORAGE_CHANNEL_PROPERTIES),
|
||||
StorVscOnChannelCallback,
|
||||
Device
|
||||
|
@ -901,7 +901,7 @@ StorVscOnReceive(
|
|||
|
||||
void
|
||||
StorVscOnChannelCallback(
|
||||
PVOID Context
|
||||
void * Context
|
||||
)
|
||||
{
|
||||
int ret=0;
|
||||
|
|
|
@ -148,7 +148,7 @@ VmbusDisconnect(
|
|||
|
||||
static int
|
||||
VmbusPostMessage(
|
||||
PVOID buffer,
|
||||
void * buffer,
|
||||
SIZE_T bufSize
|
||||
);
|
||||
|
||||
|
|
|
@ -49,7 +49,7 @@ typedef int (*PFN_ON_CLOSE)(DEVICE_OBJECT *Device);
|
|||
|
||||
typedef void (*PFN_QUERY_LINKSTATUS)(DEVICE_OBJECT *Device);
|
||||
typedef int (*PFN_ON_SEND)(DEVICE_OBJECT *dev, PNETVSC_PACKET packet);
|
||||
typedef void (*PFN_ON_SENDRECVCOMPLETION)(PVOID Context);
|
||||
typedef void (*PFN_ON_SENDRECVCOMPLETION)(void * Context);
|
||||
|
||||
typedef int (*PFN_ON_RECVCALLBACK)(DEVICE_OBJECT *dev, PNETVSC_PACKET packet);
|
||||
typedef void (*PFN_ON_LINKSTATUS_CHANGED)(DEVICE_OBJECT *dev, UINT32 Status);
|
||||
|
@ -80,18 +80,18 @@ typedef struct _NETVSC_PACKET {
|
|||
union {
|
||||
struct{
|
||||
UINT64 ReceiveCompletionTid;
|
||||
PVOID ReceiveCompletionContext;
|
||||
void * ReceiveCompletionContext;
|
||||
PFN_ON_SENDRECVCOMPLETION OnReceiveCompletion;
|
||||
} Recv;
|
||||
struct{
|
||||
UINT64 SendCompletionTid;
|
||||
PVOID SendCompletionContext;
|
||||
void * SendCompletionContext;
|
||||
PFN_ON_SENDRECVCOMPLETION OnSendCompletion;
|
||||
} Send;
|
||||
} Completion;
|
||||
|
||||
// This points to the memory after PageBuffers
|
||||
PVOID Extension;
|
||||
void * Extension;
|
||||
|
||||
UINT32 TotalDataBufferLength;
|
||||
// Points to the send/receive buffer where the ethernet frame is
|
||||
|
|
|
@ -83,12 +83,12 @@ typedef struct _STORVSC_REQUEST {
|
|||
UCHAR* SenseBuffer;
|
||||
UINT32 SenseBufferSize;
|
||||
|
||||
PVOID Context;
|
||||
void * Context;
|
||||
|
||||
PFN_ON_IO_REQUEST_COMPLTN OnIOCompletion;
|
||||
|
||||
// This points to the memory after DataBuffer
|
||||
PVOID Extension;
|
||||
void * Extension;
|
||||
|
||||
MULTIPAGE_BUFFER DataBuffer;
|
||||
} STORVSC_REQUEST;
|
||||
|
|
|
@ -88,16 +88,16 @@ typedef int (*PFN_ON_CHILDDEVICE_ADD)(PDEVICE_OBJECT RootDevice, PDEVICE_OBJECT
|
|||
typedef void (*PFN_ON_CHILDDEVICE_REMOVE)(PDEVICE_OBJECT Device);
|
||||
|
||||
// Vmbus channel interface
|
||||
typedef void (*VMBUS_CHANNEL_CALLBACK)(PVOID context);
|
||||
typedef void (*VMBUS_CHANNEL_CALLBACK)(void * context);
|
||||
|
||||
typedef int (*VMBUS_CHANNEL_OPEN)(
|
||||
PDEVICE_OBJECT Device,
|
||||
UINT32 SendBufferSize,
|
||||
UINT32 RecvRingBufferSize,
|
||||
PVOID UserData,
|
||||
void * UserData,
|
||||
UINT32 UserDataLen,
|
||||
VMBUS_CHANNEL_CALLBACK ChannelCallback,
|
||||
PVOID Context
|
||||
void * Context
|
||||
);
|
||||
|
||||
typedef void (*VMBUS_CHANNEL_CLOSE)(
|
||||
|
@ -106,7 +106,7 @@ typedef void (*VMBUS_CHANNEL_CLOSE)(
|
|||
|
||||
typedef int (*VMBUS_CHANNEL_SEND_PACKET)(
|
||||
PDEVICE_OBJECT Device,
|
||||
const PVOID Buffer,
|
||||
const void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId,
|
||||
UINT32 Type,
|
||||
|
@ -117,7 +117,7 @@ typedef int (*VMBUS_CHANNEL_SEND_PACKET_PAGEBUFFER)(
|
|||
PDEVICE_OBJECT Device,
|
||||
PAGE_BUFFER PageBuffers[],
|
||||
UINT32 PageCount,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId
|
||||
);
|
||||
|
@ -125,14 +125,14 @@ typedef int (*VMBUS_CHANNEL_SEND_PACKET_PAGEBUFFER)(
|
|||
typedef int (*VMBUS_CHANNEL_SEND_PACKET_MULTIPAGEBUFFER)(
|
||||
PDEVICE_OBJECT Device,
|
||||
MULTIPAGE_BUFFER *MultiPageBuffer,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT64 RequestId
|
||||
);
|
||||
|
||||
typedef int (*VMBUS_CHANNEL_RECV_PACKET)(
|
||||
PDEVICE_OBJECT Device,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* BufferActualLen,
|
||||
UINT64* RequestId
|
||||
|
@ -140,7 +140,7 @@ typedef int (*VMBUS_CHANNEL_RECV_PACKET)(
|
|||
|
||||
typedef int (*VMBUS_CHANNEL_RECV_PACKET_PAW)(
|
||||
PDEVICE_OBJECT Device,
|
||||
PVOID Buffer,
|
||||
void * Buffer,
|
||||
UINT32 BufferLen,
|
||||
UINT32* BufferActualLen,
|
||||
UINT64* RequestId
|
||||
|
@ -148,7 +148,7 @@ typedef int (*VMBUS_CHANNEL_RECV_PACKET_PAW)(
|
|||
|
||||
typedef int (*VMBUS_CHANNEL_ESTABLISH_GPADL)(
|
||||
PDEVICE_OBJECT Device,
|
||||
PVOID Buffer, // from kmalloc()
|
||||
void * Buffer, // from kmalloc()
|
||||
UINT32 BufferLen, // page-size multiple
|
||||
UINT32* GpadlHandle
|
||||
);
|
||||
|
|
|
@ -287,7 +287,7 @@ typedef union {
|
|||
} VMPACKET_LARGEST_POSSIBLE_HEADER, *PVMPACKET_LARGEST_POSSIBLE_HEADER;
|
||||
|
||||
#define VMPACKET_DATA_START_ADDRESS(__packet) \
|
||||
(PVOID)(((PUCHAR)__packet) + ((PVMPACKET_DESCRIPTOR)__packet)->DataOffset8 * 8)
|
||||
(void *)(((PUCHAR)__packet) + ((PVMPACKET_DESCRIPTOR)__packet)->DataOffset8 * 8)
|
||||
|
||||
#define VMPACKET_DATA_LENGTH(__packet) \
|
||||
((((PVMPACKET_DESCRIPTOR)__packet)->Length8 - ((PVMPACKET_DESCRIPTOR)__packet)->DataOffset8) * 8)
|
||||
|
|
|
@ -133,7 +133,6 @@ typedef long long LONGLONG;
|
|||
typedef unsigned long SIZE_T;
|
||||
typedef void VOID;
|
||||
//typedef unsigned char GUID[16];
|
||||
typedef void* PVOID;
|
||||
typedef unsigned char BOOL;
|
||||
typedef unsigned char BOOLEAN;
|
||||
typedef void* HANDLE;
|
||||
|
@ -246,9 +245,9 @@ extern void SpinlockRelease(HANDLE hSpin);
|
|||
void* Physical2LogicalAddr(ULONG_PTR PhysAddr);
|
||||
|
||||
#define GetPhysicalAddress Logical2PhysicalAddr
|
||||
ULONG_PTR Logical2PhysicalAddr(PVOID LogicalAddr);
|
||||
ULONG_PTR Logical2PhysicalAddr(void * LogicalAddr);
|
||||
|
||||
ULONG_PTR Virtual2Physical(PVOID VirtAddr);
|
||||
ULONG_PTR Virtual2Physical(void * VirtAddr);
|
||||
|
||||
void* PageMapVirtualAddress(unsigned long Pfn);
|
||||
void PageUnmapVirtualAddress(void* VirtAddr);
|
||||
|
|
|
@ -827,10 +827,10 @@ typedef __struct_bcount(MessageLength) struct _RNDIS_MESSAGE
|
|||
|
||||
// get pointer to contained message from NDIS_MESSAGE pointer
|
||||
#define RNDIS_MESSAGE_PTR_TO_MESSAGE_PTR(RndisMessage) \
|
||||
((PVOID) &RndisMessage->Message)
|
||||
((void *) &RndisMessage->Message)
|
||||
|
||||
// get pointer to contained message from NDIS_MESSAGE pointer
|
||||
#define RNDIS_MESSAGE_RAW_PTR_TO_MESSAGE_PTR(RndisMessage) \
|
||||
((PVOID) RndisMessage)
|
||||
((void *) RndisMessage)
|
||||
|
||||
#endif // _RNDIS_H_
|
||||
|
|
|
@ -414,14 +414,14 @@ void* Physical2LogicalAddr(ULONG_PTR PhysAddr)
|
|||
return logicalAddr;
|
||||
}
|
||||
|
||||
ULONG_PTR Logical2PhysicalAddr(PVOID LogicalAddr)
|
||||
ULONG_PTR Logical2PhysicalAddr(void * LogicalAddr)
|
||||
{
|
||||
BUG_ON(!virt_addr_valid(LogicalAddr));
|
||||
return virt_to_phys(LogicalAddr);
|
||||
}
|
||||
|
||||
|
||||
ULONG_PTR Virtual2Physical(PVOID VirtAddr)
|
||||
ULONG_PTR Virtual2Physical(void * VirtAddr)
|
||||
{
|
||||
ULONG_PTR pfn = vmalloc_to_pfn(VirtAddr);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче