Use the "real" udelay call instead of a wrapper function.
Cc: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
#include <linux/kernel.h>
#include <linux/mm.h>
+#include <linux/delay.h>
#include "include/logging.h"
#include "NetVsc.h"
#include "RndisFilter.h"
// Busy wait until the ref drop to 2, then set it to 1
while (InterlockedCompareExchange(&netDevice->RefCount, 1, 2) != 2)
{
- Sleep(100);
+ udelay(100);
}
return netDevice;
// Busy wait until the ref drop to 1, then set it to 0
while (InterlockedCompareExchange(&netDevice->RefCount, 0, 1) != 1)
{
- Sleep(100);
+ udelay(100);
}
Device->Extension = NULL;
{
DPRINT_INFO(NETVSC, "waiting for %d requests to complete...", netDevice->NumOutstandingSends);
- Sleep(100);
+ udelay(100);
}
DPRINT_INFO(NETVSC, "Disconnecting from netvsp...");
if (retries < 4)
{
- Sleep(100);
+ udelay(100);
goto retry_send_cmplt;
}
else
#include <linux/kernel.h>
#include <linux/string.h>
#include <linux/mm.h>
+#include <linux/delay.h>
#include "include/logging.h"
#include "include/StorVscApi.h"
// Busy wait until the ref drop to 2, then set it to 1
while (InterlockedCompareExchange(&storDevice->RefCount, 1, 2) != 2)
{
- Sleep(100);
+ udelay(100);
}
return storDevice;
// Busy wait until the ref drop to 1, then set it to 0
while (InterlockedCompareExchange(&storDevice->RefCount, 0, 1) != 1)
{
- Sleep(100);
+ udelay(100);
}
Device->Extension = NULL;
{
DPRINT_INFO(STORVSC, "waiting for %d requests to complete...", storDevice->NumOutstandingRequests);
- Sleep(100);
+ udelay(100);
}
DPRINT_INFO(STORVSC, "removing storage device (%p)...", Device->Extension);
extern int InterlockedDecrement(int *val);
extern int InterlockedCompareExchange(int *val, int new, int curr);
-extern void Sleep(unsigned long usecs);
-
extern void* VirtualAllocExec(unsigned int size);
extern void VirtualFree(void* VirtAddr);
}
-void Sleep(unsigned long usecs)
-{
- udelay(usecs);
-}
-
void* VirtualAllocExec(unsigned int size)
{
#ifdef __x86_64__