diff options
author | Greg Kroah-Hartman <gregkh@suse.de> | 2009-07-14 15:12:46 -0700 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2009-09-15 12:01:46 -0700 |
commit | c4b0bc94828a86cfb6a975b0e0d92dc1cd389565 (patch) | |
tree | d67ad0683d5f196baa70e9040021dbac0bf8e2fe /drivers/staging/hv/RndisFilter.c | |
parent | b509bf5badcd30b1c163349a87a56933b59663e1 (diff) |
Staging: hv: remove ULONG_PTR typedef
The ULONG_PTR 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>
Diffstat (limited to 'drivers/staging/hv/RndisFilter.c')
-rw-r--r-- | drivers/staging/hv/RndisFilter.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/staging/hv/RndisFilter.c b/drivers/staging/hv/RndisFilter.c index 12365820e6c..9bfd1695836 100644 --- a/drivers/staging/hv/RndisFilter.c +++ b/drivers/staging/hv/RndisFilter.c @@ -362,11 +362,11 @@ RndisFilterSendRequest( packet->PageBuffers[0].Pfn = GetPhysicalAddress(&Request->RequestMessage) >> PAGE_SHIFT; packet->PageBuffers[0].Length = Request->RequestMessage.MessageLength; - packet->PageBuffers[0].Offset = (ULONG_PTR)&Request->RequestMessage & (PAGE_SIZE -1); + packet->PageBuffers[0].Offset = (unsigned long)&Request->RequestMessage & (PAGE_SIZE -1); packet->Completion.Send.SendCompletionContext = Request;//packet; packet->Completion.Send.OnSendCompletion = RndisFilterOnSendRequestCompletion; - packet->Completion.Send.SendCompletionTid = (ULONG_PTR)Device; + packet->Completion.Send.SendCompletionTid = (unsigned long)Device; ret = gRndisFilter.InnerDriver.OnSend(Device->NetDevice->Device, packet); DPRINT_EXIT(NETVSC); @@ -523,7 +523,7 @@ RndisFilterOnReceive( rndisHeader = (RNDIS_MESSAGE*)PageMapVirtualAddress(Packet->PageBuffers[0].Pfn); - rndisHeader = (void*)((ULONG_PTR)rndisHeader + Packet->PageBuffers[0].Offset); + rndisHeader = (void*)((unsigned long)rndisHeader + Packet->PageBuffers[0].Offset); // Make sure we got a valid rndis message // FIXME: There seems to be a bug in set completion msg where its MessageLength is 16 bytes but @@ -531,7 +531,7 @@ RndisFilterOnReceive( #if 0 if ( Packet->TotalDataBufferLength != rndisHeader->MessageLength ) { - PageUnmapVirtualAddress((void*)(ULONG_PTR)rndisHeader - Packet->PageBuffers[0].Offset); + PageUnmapVirtualAddress((void*)(unsigned long)rndisHeader - Packet->PageBuffers[0].Offset); DPRINT_ERR(NETVSC, "invalid rndis message? (expected %u bytes got %u)...dropping this message!", rndisHeader->MessageLength, Packet->TotalDataBufferLength); @@ -548,7 +548,7 @@ RndisFilterOnReceive( memcpy(&rndisMessage, rndisHeader, (rndisHeader->MessageLength > sizeof(RNDIS_MESSAGE))?sizeof(RNDIS_MESSAGE):rndisHeader->MessageLength); - PageUnmapVirtualAddress((void*)(ULONG_PTR)rndisHeader - Packet->PageBuffers[0].Offset); + PageUnmapVirtualAddress((void*)(unsigned long)rndisHeader - Packet->PageBuffers[0].Offset); DumpRndisMessage(&rndisMessage); @@ -633,7 +633,7 @@ RndisFilterQueryDevice( } memcpy(Result, - (void*)((ULONG_PTR)queryComplete + queryComplete->InformationBufferOffset), + (void*)((unsigned long)queryComplete + queryComplete->InformationBufferOffset), queryComplete->InformationBufferLength); *ResultSize = queryComplete->InformationBufferLength; @@ -703,7 +703,7 @@ RndisFilterSetPacketFilter( set->InformationBufferLength = sizeof(u32); set->InformationBufferOffset = sizeof(RNDIS_SET_REQUEST); - memcpy((void*)(ULONG_PTR)set + sizeof(RNDIS_SET_REQUEST), &NewFilter, sizeof(u32)); + memcpy((void*)(unsigned long)set + sizeof(RNDIS_SET_REQUEST), &NewFilter, sizeof(u32)); ret = RndisFilterSendRequest(Device, request); if (ret != 0) @@ -1113,7 +1113,7 @@ RndisFilterOnSend( Packet->IsDataPacket = TRUE; Packet->PageBuffers[0].Pfn = GetPhysicalAddress(rndisMessage) >> PAGE_SHIFT; - Packet->PageBuffers[0].Offset = (ULONG_PTR)rndisMessage & (PAGE_SIZE-1); + Packet->PageBuffers[0].Offset = (unsigned long)rndisMessage & (PAGE_SIZE-1); Packet->PageBuffers[0].Length = rndisMessageSize; // Save the packet send completion and context |