Archived
14
0
Fork 0

Staging: hv: remove DPRINT_EXIT macro

No need for it, use the built-in kernel function tracing instead
if you really need something like this.

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:
Greg Kroah-Hartman 2010-07-22 15:14:04 -07:00
parent 2acadc269f
commit 83c720ea39
16 changed files with 14 additions and 348 deletions

View file

@ -43,10 +43,8 @@ static int BlkVscOnDeviceAdd(struct hv_device *Device, void *AdditionalInfo)
deviceInfo = (struct storvsc_device_info *)AdditionalInfo; deviceInfo = (struct storvsc_device_info *)AdditionalInfo;
ret = StorVscOnDeviceAdd(Device, AdditionalInfo); ret = StorVscOnDeviceAdd(Device, AdditionalInfo);
if (ret != 0) { if (ret != 0)
DPRINT_EXIT(BLKVSC);
return ret; return ret;
}
/* /*
* We need to use the device instance guid to set the path and target * We need to use the device instance guid to set the path and target
@ -61,8 +59,6 @@ static int BlkVscOnDeviceAdd(struct hv_device *Device, void *AdditionalInfo)
deviceInfo->TargetId = Device->deviceInstance.data[5] << 8 | deviceInfo->TargetId = Device->deviceInstance.data[5] << 8 |
Device->deviceInstance.data[4]; Device->deviceInstance.data[4];
DPRINT_EXIT(BLKVSC);
return ret; return ret;
} }
@ -102,7 +98,5 @@ int BlkVscInitialize(struct hv_driver *Driver)
storDriver->Base.OnCleanup = StorVscOnCleanup; storDriver->Base.OnCleanup = StorVscOnCleanup;
storDriver->OnIORequest = StorVscOnIORequest; storDriver->OnIORequest = StorVscOnIORequest;
DPRINT_EXIT(BLKVSC);
return ret; return ret;
} }

View file

@ -193,8 +193,6 @@ static int blkvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
/* The driver belongs to vmbus */ /* The driver belongs to vmbus */
ret = vmbus_child_driver_register(drv_ctx); ret = vmbus_child_driver_register(drv_ctx);
DPRINT_EXIT(BLKVSC_DRV);
return ret; return ret;
} }
@ -237,8 +235,6 @@ static void blkvsc_drv_exit(void)
vmbus_child_driver_unregister(drv_ctx); vmbus_child_driver_unregister(drv_ctx);
DPRINT_EXIT(BLKVSC_DRV);
return; return;
} }
@ -407,8 +403,6 @@ Cleanup:
blkdev = NULL; blkdev = NULL;
} }
DPRINT_EXIT(BLKVSC_DRV);
return ret; return ret;
} }
@ -747,10 +741,8 @@ static int blkvsc_remove(struct device *device)
DPRINT_DBG(BLKVSC_DRV, "blkvsc_remove()\n"); DPRINT_DBG(BLKVSC_DRV, "blkvsc_remove()\n");
if (!storvsc_drv_obj->Base.OnDeviceRemove) { if (!storvsc_drv_obj->Base.OnDeviceRemove)
DPRINT_EXIT(BLKVSC_DRV);
return -1; return -1;
}
/* /*
* Call to the vsc driver to let it know that the device is being * Call to the vsc driver to let it know that the device is being
@ -794,8 +786,6 @@ static int blkvsc_remove(struct device *device)
kfree(blkdev); kfree(blkdev);
DPRINT_EXIT(BLKVSC_DRV);
return ret; return ret;
} }
@ -1488,8 +1478,6 @@ static int __init blkvsc_init(void)
ret = blkvsc_drv_init(BlkVscInitialize); ret = blkvsc_drv_init(BlkVscInitialize);
DPRINT_EXIT(BLKVSC_DRV);
return ret; return ret;
} }

View file

@ -90,8 +90,6 @@ static void VmbusChannelSetEvent(struct vmbus_channel *Channel)
} else { } else {
VmbusSetEvent(Channel->OfferMsg.ChildRelId); VmbusSetEvent(Channel->OfferMsg.ChildRelId);
} }
DPRINT_EXIT(VMBUS);
} }
#if 0 #if 0
@ -113,8 +111,6 @@ static void VmbusChannelClearEvent(struct vmbus_channel *channel)
(unsigned long *)&monitorPage->TriggerGroup (unsigned long *)&monitorPage->TriggerGroup
[Channel->MonitorGroup].Pending); [Channel->MonitorGroup].Pending);
} }
DPRINT_EXIT(VMBUS);
} }
#endif #endif
@ -299,9 +295,6 @@ Cleanup:
kfree(openInfo->WaitEvent); kfree(openInfo->WaitEvent);
kfree(openInfo); kfree(openInfo);
DPRINT_EXIT(VMBUS);
return 0; return 0;
errorout: errorout:
@ -586,9 +579,6 @@ Cleanup:
kfree(msgInfo->WaitEvent); kfree(msgInfo->WaitEvent);
kfree(msgInfo); kfree(msgInfo);
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -642,9 +632,6 @@ int VmbusChannelTeardownGpadl(struct vmbus_channel *Channel, u32 GpadlHandle)
kfree(info->WaitEvent); kfree(info->WaitEvent);
kfree(info); kfree(info);
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -710,8 +697,6 @@ void VmbusChannelClose(struct vmbus_channel *Channel)
FreeVmbusChannel(Channel); FreeVmbusChannel(Channel);
} }
DPRINT_EXIT(VMBUS);
} }
/** /**
@ -765,8 +750,6 @@ int VmbusChannelSendPacket(struct vmbus_channel *Channel, const void *Buffer,
if (ret == 0 && !GetRingBufferInterruptMask(&Channel->Outbound)) if (ret == 0 && !GetRingBufferInterruptMask(&Channel->Outbound))
VmbusChannelSetEvent(Channel); VmbusChannelSetEvent(Channel);
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
EXPORT_SYMBOL(VmbusChannelSendPacket); EXPORT_SYMBOL(VmbusChannelSendPacket);
@ -831,8 +814,6 @@ int VmbusChannelSendPacketPageBuffer(struct vmbus_channel *Channel,
if (ret == 0 && !GetRingBufferInterruptMask(&Channel->Outbound)) if (ret == 0 && !GetRingBufferInterruptMask(&Channel->Outbound))
VmbusChannelSetEvent(Channel); VmbusChannelSetEvent(Channel);
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -899,8 +880,6 @@ int VmbusChannelSendPacketMultiPageBuffer(struct vmbus_channel *Channel,
if (ret == 0 && !GetRingBufferInterruptMask(&Channel->Outbound)) if (ret == 0 && !GetRingBufferInterruptMask(&Channel->Outbound))
VmbusChannelSetEvent(Channel); VmbusChannelSetEvent(Channel);
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -938,7 +917,6 @@ int VmbusChannelRecvPacket(struct vmbus_channel *Channel, void *Buffer,
spin_unlock_irqrestore(&Channel->inbound_lock, flags); spin_unlock_irqrestore(&Channel->inbound_lock, flags);
/* DPRINT_DBG(VMBUS, "nothing to read!!"); */ /* DPRINT_DBG(VMBUS, "nothing to read!!"); */
DPRINT_EXIT(VMBUS);
return 0; return 0;
} }
@ -960,8 +938,6 @@ int VmbusChannelRecvPacket(struct vmbus_channel *Channel, void *Buffer,
DPRINT_ERR(VMBUS, "buffer too small - got %d needs %d", DPRINT_ERR(VMBUS, "buffer too small - got %d needs %d",
BufferLen, userLen); BufferLen, userLen);
DPRINT_EXIT(VMBUS);
return -1; return -1;
} }
@ -973,8 +949,6 @@ int VmbusChannelRecvPacket(struct vmbus_channel *Channel, void *Buffer,
spin_unlock_irqrestore(&Channel->inbound_lock, flags); spin_unlock_irqrestore(&Channel->inbound_lock, flags);
DPRINT_EXIT(VMBUS);
return 0; return 0;
} }
EXPORT_SYMBOL(VmbusChannelRecvPacket); EXPORT_SYMBOL(VmbusChannelRecvPacket);
@ -1003,7 +977,6 @@ int VmbusChannelRecvPacketRaw(struct vmbus_channel *Channel, void *Buffer,
spin_unlock_irqrestore(&Channel->inbound_lock, flags); spin_unlock_irqrestore(&Channel->inbound_lock, flags);
/* DPRINT_DBG(VMBUS, "nothing to read!!"); */ /* DPRINT_DBG(VMBUS, "nothing to read!!"); */
DPRINT_EXIT(VMBUS);
return 0; return 0;
} }
@ -1024,7 +997,6 @@ int VmbusChannelRecvPacketRaw(struct vmbus_channel *Channel, void *Buffer,
DPRINT_ERR(VMBUS, "buffer too small - needed %d bytes but " DPRINT_ERR(VMBUS, "buffer too small - needed %d bytes but "
"got space for only %d bytes", packetLen, BufferLen); "got space for only %d bytes", packetLen, BufferLen);
DPRINT_EXIT(VMBUS);
return -2; return -2;
} }
@ -1034,9 +1006,6 @@ int VmbusChannelRecvPacketRaw(struct vmbus_channel *Channel, void *Buffer,
ret = RingBufferRead(&Channel->Inbound, Buffer, packetLen, 0); ret = RingBufferRead(&Channel->Inbound, Buffer, packetLen, 0);
spin_unlock_irqrestore(&Channel->inbound_lock, flags); spin_unlock_irqrestore(&Channel->inbound_lock, flags);
DPRINT_EXIT(VMBUS);
return 0; return 0;
} }

View file

@ -271,8 +271,6 @@ static inline void ReleaseVmbusChannel(void *context)
DPRINT_DBG(VMBUS, "channel released (%p)", channel); DPRINT_DBG(VMBUS, "channel released (%p)", channel);
kfree(channel); kfree(channel);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -329,7 +327,6 @@ static void VmbusChannelProcessOffer(void *context)
DPRINT_DBG(VMBUS, "Ignoring duplicate offer for relid (%d)", DPRINT_DBG(VMBUS, "Ignoring duplicate offer for relid (%d)",
newChannel->OfferMsg.ChildRelId); newChannel->OfferMsg.ChildRelId);
FreeVmbusChannel(newChannel); FreeVmbusChannel(newChannel);
DPRINT_EXIT(VMBUS);
return; return;
} }
@ -387,7 +384,6 @@ static void VmbusChannelProcessOffer(void *context)
cnt++; cnt++;
} }
} }
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -398,7 +394,6 @@ static void VmbusChannelProcessRescindOffer(void *context)
struct vmbus_channel *channel = context; struct vmbus_channel *channel = context;
VmbusChildDeviceRemove(channel->DeviceObject); VmbusChildDeviceRemove(channel->DeviceObject);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -429,7 +424,6 @@ static void VmbusChannelOnOffer(struct vmbus_channel_message_header *hdr)
if (!fSupported) { if (!fSupported) {
DPRINT_DBG(VMBUS, "Ignoring channel offer notification for " DPRINT_DBG(VMBUS, "Ignoring channel offer notification for "
"child relid %d", offer->ChildRelId); "child relid %d", offer->ChildRelId);
DPRINT_EXIT(VMBUS);
return; return;
} }
@ -478,8 +472,6 @@ static void VmbusChannelOnOffer(struct vmbus_channel_message_header *hdr)
/* TODO: Make sure the offer comes from our parent partition */ /* TODO: Make sure the offer comes from our parent partition */
osd_schedule_callback(newChannel->ControlWQ, VmbusChannelProcessOffer, osd_schedule_callback(newChannel->ControlWQ, VmbusChannelProcessOffer,
newChannel); newChannel);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -503,8 +495,6 @@ static void VmbusChannelOnOfferRescind(struct vmbus_channel_message_header *hdr)
osd_schedule_callback(channel->ControlWQ, osd_schedule_callback(channel->ControlWQ,
VmbusChannelProcessRescindOffer, VmbusChannelProcessRescindOffer,
channel); channel);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -515,7 +505,6 @@ static void VmbusChannelOnOfferRescind(struct vmbus_channel_message_header *hdr)
static void VmbusChannelOnOffersDelivered( static void VmbusChannelOnOffersDelivered(
struct vmbus_channel_message_header *hdr) struct vmbus_channel_message_header *hdr)
{ {
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -560,8 +549,6 @@ static void VmbusChannelOnOpenResult(struct vmbus_channel_message_header *hdr)
} }
} }
spin_unlock_irqrestore(&gVmbusConnection.channelmsg_lock, flags); spin_unlock_irqrestore(&gVmbusConnection.channelmsg_lock, flags);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -610,8 +597,6 @@ static void VmbusChannelOnGpadlCreated(struct vmbus_channel_message_header *hdr)
} }
} }
spin_unlock_irqrestore(&gVmbusConnection.channelmsg_lock, flags); spin_unlock_irqrestore(&gVmbusConnection.channelmsg_lock, flags);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -656,8 +641,6 @@ static void VmbusChannelOnGpadlTorndown(
} }
} }
spin_unlock_irqrestore(&gVmbusConnection.channelmsg_lock, flags); spin_unlock_irqrestore(&gVmbusConnection.channelmsg_lock, flags);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -695,8 +678,6 @@ static void VmbusChannelOnVersionResponse(
} }
} }
spin_unlock_irqrestore(&gVmbusConnection.channelmsg_lock, flags); spin_unlock_irqrestore(&gVmbusConnection.channelmsg_lock, flags);
DPRINT_EXIT(VMBUS);
} }
/* Channel message dispatch table */ /* Channel message dispatch table */
@ -755,7 +736,6 @@ void VmbusOnChannelMessage(void *Context)
/* Free the msg that was allocated in VmbusOnMsgDPC() */ /* Free the msg that was allocated in VmbusOnMsgDPC() */
kfree(msg); kfree(msg);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -812,7 +792,6 @@ Cleanup:
kfree(msgInfo); kfree(msgInfo);
} }
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }

View file

@ -153,8 +153,6 @@ int VmbusConnect(void)
kfree(msgInfo->WaitEvent); kfree(msgInfo->WaitEvent);
kfree(msgInfo); kfree(msgInfo);
DPRINT_EXIT(VMBUS);
return 0; return 0;
Cleanup: Cleanup:
@ -178,8 +176,6 @@ Cleanup:
kfree(msgInfo); kfree(msgInfo);
} }
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -217,7 +213,6 @@ int VmbusDisconnect(void)
Cleanup: Cleanup:
kfree(msg); kfree(msg);
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -304,8 +299,6 @@ void VmbusOnEvents(void)
} }
} }
} }
DPRINT_EXIT(VMBUS);
return; return;
} }
@ -326,16 +319,10 @@ int VmbusPostMessage(void *buffer, size_t bufferLen)
*/ */
int VmbusSetEvent(u32 childRelId) int VmbusSetEvent(u32 childRelId)
{ {
int ret = 0;
/* Each u32 represents 32 channels */ /* Each u32 represents 32 channels */
set_bit(childRelId & 31, set_bit(childRelId & 31,
(unsigned long *)gVmbusConnection.SendInterruptPage + (unsigned long *)gVmbusConnection.SendInterruptPage +
(childRelId >> 5)); (childRelId >> 5));
ret = HvSignalEvent(); return HvSignalEvent();
DPRINT_EXIT(VMBUS);
return ret;
} }

View file

@ -273,8 +273,6 @@ int HvInit(void)
gHvContext.SignalEventParam->FlagNumber = 0; gHvContext.SignalEventParam->FlagNumber = 0;
gHvContext.SignalEventParam->RsvdZ = 0; gHvContext.SignalEventParam->RsvdZ = 0;
DPRINT_EXIT(VMBUS);
return ret; return ret;
Cleanup: Cleanup:
@ -287,8 +285,6 @@ Cleanup:
vfree(virtAddr); vfree(virtAddr);
} }
ret = -1; ret = -1;
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -311,8 +307,6 @@ void HvCleanup(void)
vfree(gHvContext.HypercallPage); vfree(gHvContext.HypercallPage);
gHvContext.HypercallPage = NULL; gHvContext.HypercallPage = NULL;
} }
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -388,10 +382,8 @@ void HvSynicInit(void *irqarg)
u32 irqVector = *((u32 *)(irqarg)); u32 irqVector = *((u32 *)(irqarg));
int cpu = smp_processor_id(); int cpu = smp_processor_id();
if (!gHvContext.HypercallPage) { if (!gHvContext.HypercallPage)
DPRINT_EXIT(VMBUS);
return; return;
}
/* Check the version */ /* Check the version */
rdmsrl(HV_X64_MSR_SVERSION, version); rdmsrl(HV_X64_MSR_SVERSION, version);
@ -458,9 +450,6 @@ void HvSynicInit(void *irqarg)
wrmsrl(HV_X64_MSR_SCONTROL, sctrl.AsUINT64); wrmsrl(HV_X64_MSR_SCONTROL, sctrl.AsUINT64);
gHvContext.SynICInitialized = true; gHvContext.SynICInitialized = true;
DPRINT_EXIT(VMBUS);
return; return;
Cleanup: Cleanup:
@ -469,8 +458,6 @@ Cleanup:
if (gHvContext.synICMessagePage[cpu]) if (gHvContext.synICMessagePage[cpu])
osd_PageFree(gHvContext.synICMessagePage[cpu], 1); osd_PageFree(gHvContext.synICMessagePage[cpu], 1);
DPRINT_EXIT(VMBUS);
return; return;
} }
@ -484,10 +471,8 @@ void HvSynicCleanup(void *arg)
union hv_synic_siefp siefp; union hv_synic_siefp siefp;
int cpu = smp_processor_id(); int cpu = smp_processor_id();
if (!gHvContext.SynICInitialized) { if (!gHvContext.SynICInitialized)
DPRINT_EXIT(VMBUS);
return; return;
}
rdmsrl(HV_X64_MSR_SINT0 + VMBUS_MESSAGE_SINT, sharedSint.AsUINT64); rdmsrl(HV_X64_MSR_SINT0 + VMBUS_MESSAGE_SINT, sharedSint.AsUINT64);
@ -511,6 +496,4 @@ void HvSynicCleanup(void *arg)
osd_PageFree(gHvContext.synICMessagePage[cpu], 1); osd_PageFree(gHvContext.synICMessagePage[cpu], 1);
osd_PageFree(gHvContext.synICEventPage[cpu], 1); osd_PageFree(gHvContext.synICEventPage[cpu], 1);
DPRINT_EXIT(VMBUS);
} }

View file

@ -98,8 +98,6 @@ static void shutdown_onchannelcallback(void *context)
kfree(buf); kfree(buf);
DPRINT_EXIT(VMBUS);
if (execute_shutdown == true) if (execute_shutdown == true)
orderly_poweroff(false); orderly_poweroff(false);
} }
@ -186,8 +184,6 @@ static void timesync_onchannelcallback(void *context)
} }
kfree(buf); kfree(buf);
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -241,8 +237,6 @@ static void heartbeat_onchannelcallback(void *context)
} }
kfree(buf); kfree(buf);
DPRINT_EXIT(VMBUS);
} }
static int __init init_hyperv_utils(void) static int __init init_hyperv_utils(void)

View file

@ -92,14 +92,4 @@ extern unsigned int vmbus_loglevel;
__func__, ## args);\ __func__, ## args);\
} while (0) } while (0)
#ifdef DEBUG
#define DPRINT_EXIT(mod) do {\
if ((mod & (HIWORD(vmbus_loglevel))) && \
(DEBUG_LVL_ENTEREXIT <= LOWORD(vmbus_loglevel))) \
printk(KERN_DEBUG "["#mod"]: %s() exit\n", __func__);\
} while (0)
#else
#define DPRINT_EXIT(mod)
#endif
#endif /* _LOGGING_H_ */ #endif /* _LOGGING_H_ */

View file

@ -200,9 +200,6 @@ int NetVscInitialize(struct hv_driver *drv)
driver->OnSend = NetVscOnSend; driver->OnSend = NetVscOnSend;
RndisFilterInit(driver); RndisFilterInit(driver);
DPRINT_EXIT(NETVSC);
return 0; return 0;
} }
@ -216,7 +213,6 @@ static int NetVscInitializeReceiveBufferWithNetVsp(struct hv_device *Device)
if (!netDevice) { if (!netDevice) {
DPRINT_ERR(NETVSC, "unable to get net device..." DPRINT_ERR(NETVSC, "unable to get net device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
/* ASSERT(netDevice->ReceiveBufferSize > 0); */ /* ASSERT(netDevice->ReceiveBufferSize > 0); */
@ -331,7 +327,6 @@ Cleanup:
Exit: Exit:
PutNetDevice(Device); PutNetDevice(Device);
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -345,7 +340,6 @@ static int NetVscInitializeSendBufferWithNetVsp(struct hv_device *Device)
if (!netDevice) { if (!netDevice) {
DPRINT_ERR(NETVSC, "unable to get net device..." DPRINT_ERR(NETVSC, "unable to get net device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
if (netDevice->SendBufferSize <= 0) { if (netDevice->SendBufferSize <= 0) {
@ -428,7 +422,6 @@ Cleanup:
Exit: Exit:
PutNetDevice(Device); PutNetDevice(Device);
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -467,7 +460,6 @@ static int NetVscDestroyReceiveBuffer(struct netvsc_device *NetDevice)
if (ret != 0) { if (ret != 0) {
DPRINT_ERR(NETVSC, "unable to send revoke receive " DPRINT_ERR(NETVSC, "unable to send revoke receive "
"buffer to netvsp"); "buffer to netvsp");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
} }
@ -484,7 +476,6 @@ static int NetVscDestroyReceiveBuffer(struct netvsc_device *NetDevice)
if (ret != 0) { if (ret != 0) {
DPRINT_ERR(NETVSC, DPRINT_ERR(NETVSC,
"unable to teardown receive buffer's gpadl"); "unable to teardown receive buffer's gpadl");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
NetDevice->ReceiveBufferGpadlHandle = 0; NetDevice->ReceiveBufferGpadlHandle = 0;
@ -505,8 +496,6 @@ static int NetVscDestroyReceiveBuffer(struct netvsc_device *NetDevice)
NetDevice->ReceiveSections = NULL; NetDevice->ReceiveSections = NULL;
} }
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -544,7 +533,6 @@ static int NetVscDestroySendBuffer(struct netvsc_device *NetDevice)
if (ret != 0) { if (ret != 0) {
DPRINT_ERR(NETVSC, "unable to send revoke send buffer " DPRINT_ERR(NETVSC, "unable to send revoke send buffer "
"to netvsp"); "to netvsp");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
} }
@ -562,7 +550,6 @@ static int NetVscDestroySendBuffer(struct netvsc_device *NetDevice)
if (ret != 0) { if (ret != 0) {
DPRINT_ERR(NETVSC, "unable to teardown send buffer's " DPRINT_ERR(NETVSC, "unable to teardown send buffer's "
"gpadl"); "gpadl");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
NetDevice->SendBufferGpadlHandle = 0; NetDevice->SendBufferGpadlHandle = 0;
@ -577,8 +564,6 @@ static int NetVscDestroySendBuffer(struct netvsc_device *NetDevice)
NetDevice->SendBuffer = NULL; NetDevice->SendBuffer = NULL;
} }
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -594,7 +579,6 @@ static int NetVscConnectToVsp(struct hv_device *Device)
if (!netDevice) { if (!netDevice) {
DPRINT_ERR(NETVSC, "unable to get net device..." DPRINT_ERR(NETVSC, "unable to get net device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
@ -684,7 +668,6 @@ static int NetVscConnectToVsp(struct hv_device *Device)
Cleanup: Cleanup:
PutNetDevice(Device); PutNetDevice(Device);
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -692,8 +675,6 @@ static void NetVscDisconnectFromVsp(struct netvsc_device *NetDevice)
{ {
NetVscDestroyReceiveBuffer(NetDevice); NetVscDestroyReceiveBuffer(NetDevice);
NetVscDestroySendBuffer(NetDevice); NetVscDestroySendBuffer(NetDevice);
DPRINT_EXIT(NETVSC);
} }
/* /*
@ -771,7 +752,6 @@ static int NetVscOnDeviceAdd(struct hv_device *Device, void *AdditionalInfo)
DPRINT_INFO(NETVSC, "*** NetVSC channel handshake result - %d ***", DPRINT_INFO(NETVSC, "*** NetVSC channel handshake result - %d ***",
ret); ret);
DPRINT_EXIT(NETVSC);
return ret; return ret;
Close: Close:
@ -796,7 +776,6 @@ Cleanup:
FreeNetDevice(netDevice); FreeNetDevice(netDevice);
} }
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -850,8 +829,6 @@ static int NetVscOnDeviceRemove(struct hv_device *Device)
kfree(netDevice->ChannelInitEvent); kfree(netDevice->ChannelInitEvent);
FreeNetDevice(netDevice); FreeNetDevice(netDevice);
DPRINT_EXIT(NETVSC);
return 0; return 0;
} }
@ -860,7 +837,6 @@ static int NetVscOnDeviceRemove(struct hv_device *Device)
*/ */
static void NetVscOnCleanup(struct hv_driver *drv) static void NetVscOnCleanup(struct hv_driver *drv)
{ {
DPRINT_EXIT(NETVSC);
} }
static void NetVscOnSendCompletion(struct hv_device *Device, static void NetVscOnSendCompletion(struct hv_device *Device,
@ -874,7 +850,6 @@ static void NetVscOnSendCompletion(struct hv_device *Device,
if (!netDevice) { if (!netDevice) {
DPRINT_ERR(NETVSC, "unable to get net device..." DPRINT_ERR(NETVSC, "unable to get net device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(NETVSC);
return; return;
} }
@ -908,7 +883,6 @@ static void NetVscOnSendCompletion(struct hv_device *Device,
} }
PutNetDevice(Device); PutNetDevice(Device);
DPRINT_EXIT(NETVSC);
} }
static int NetVscOnSend(struct hv_device *Device, static int NetVscOnSend(struct hv_device *Device,
@ -923,7 +897,6 @@ static int NetVscOnSend(struct hv_device *Device,
if (!netDevice) { if (!netDevice) {
DPRINT_ERR(NETVSC, "net device (%p) shutting down..." DPRINT_ERR(NETVSC, "net device (%p) shutting down..."
"ignoring outbound packets", netDevice); "ignoring outbound packets", netDevice);
DPRINT_EXIT(NETVSC);
return -2; return -2;
} }
@ -963,8 +936,6 @@ static int NetVscOnSend(struct hv_device *Device,
atomic_inc(&netDevice->NumOutstandingSends); atomic_inc(&netDevice->NumOutstandingSends);
PutNetDevice(Device); PutNetDevice(Device);
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -988,7 +959,6 @@ static void NetVscOnReceive(struct hv_device *Device,
if (!netDevice) { if (!netDevice) {
DPRINT_ERR(NETVSC, "unable to get net device..." DPRINT_ERR(NETVSC, "unable to get net device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(NETVSC);
return; return;
} }
@ -1164,7 +1134,6 @@ static void NetVscOnReceive(struct hv_device *Device,
/* ASSERT(list_empty(&listHead)); */ /* ASSERT(list_empty(&listHead)); */
PutNetDevice(Device); PutNetDevice(Device);
DPRINT_EXIT(NETVSC);
} }
static void NetVscSendReceiveCompletion(struct hv_device *Device, static void NetVscSendReceiveCompletion(struct hv_device *Device,
@ -1234,7 +1203,6 @@ static void NetVscOnReceiveCompletion(void *Context)
if (!netDevice) { if (!netDevice) {
DPRINT_ERR(NETVSC, "unable to get net device..." DPRINT_ERR(NETVSC, "unable to get net device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(NETVSC);
return; return;
} }
@ -1265,7 +1233,6 @@ static void NetVscOnReceiveCompletion(void *Context)
NetVscSendReceiveCompletion(device, transactionId); NetVscSendReceiveCompletion(device, transactionId);
PutNetDevice(device); PutNetDevice(device);
DPRINT_EXIT(NETVSC);
} }
static void NetVscOnChannelCallback(void *Context) static void NetVscOnChannelCallback(void *Context)
@ -1292,7 +1259,6 @@ static void NetVscOnChannelCallback(void *Context)
if (!netDevice) { if (!netDevice) {
DPRINT_ERR(NETVSC, "net device (%p) shutting down..." DPRINT_ERR(NETVSC, "net device (%p) shutting down..."
"ignoring inbound packets", netDevice); "ignoring inbound packets", netDevice);
DPRINT_EXIT(NETVSC);
goto out; goto out;
} }
@ -1356,7 +1322,6 @@ static void NetVscOnChannelCallback(void *Context)
} while (1); } while (1);
PutNetDevice(device); PutNetDevice(device);
DPRINT_EXIT(NETVSC);
out: out:
kfree(buffer); kfree(buffer);
return; return;

View file

@ -90,7 +90,6 @@ static int netvsc_open(struct net_device *net)
DPRINT_ERR(NETVSC_DRV, "unable to open device...link is down."); DPRINT_ERR(NETVSC_DRV, "unable to open device...link is down.");
} }
DPRINT_EXIT(NETVSC_DRV);
return ret; return ret;
} }
@ -106,8 +105,6 @@ static int netvsc_close(struct net_device *net)
if (ret != 0) if (ret != 0)
DPRINT_ERR(NETVSC_DRV, "unable to close device (ret %d).", ret); DPRINT_ERR(NETVSC_DRV, "unable to close device (ret %d).", ret);
DPRINT_EXIT(NETVSC_DRV);
return ret; return ret;
} }
@ -129,8 +126,6 @@ static void netvsc_xmit_completion(void *context)
if ((net_device_ctx->avail += num_pages) >= PACKET_PAGES_HIWATER) if ((net_device_ctx->avail += num_pages) >= PACKET_PAGES_HIWATER)
netif_wake_queue(net); netif_wake_queue(net);
} }
DPRINT_EXIT(NETVSC_DRV);
} }
static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net) static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
@ -217,7 +212,6 @@ static int netvsc_start_xmit(struct sk_buff *skb, struct net_device *net)
netvsc_xmit_completion(packet); netvsc_xmit_completion(packet);
} }
DPRINT_EXIT(NETVSC_DRV);
return NETDEV_TX_OK; return NETDEV_TX_OK;
} }
@ -243,7 +237,6 @@ static void netvsc_linkstatus_callback(struct hv_device *device_obj,
netif_carrier_off(net); netif_carrier_off(net);
netif_stop_queue(net); netif_stop_queue(net);
} }
DPRINT_EXIT(NETVSC_DRV);
} }
/* /*
@ -311,8 +304,6 @@ static int netvsc_recv_callback(struct hv_device *device_obj,
DPRINT_DBG(NETVSC_DRV, "# of recvs %lu total size %lu", DPRINT_DBG(NETVSC_DRV, "# of recvs %lu total size %lu",
net->stats.rx_packets, net->stats.rx_bytes); net->stats.rx_packets, net->stats.rx_bytes);
DPRINT_EXIT(NETVSC_DRV);
return 0; return 0;
} }
@ -408,7 +399,6 @@ static int netvsc_probe(struct device *device)
free_netdev(net); free_netdev(net);
} }
DPRINT_EXIT(NETVSC_DRV);
return ret; return ret;
} }
@ -426,14 +416,11 @@ static int netvsc_remove(struct device *device)
if (net == NULL) { if (net == NULL) {
DPRINT_INFO(NETVSC, "no net device to remove"); DPRINT_INFO(NETVSC, "no net device to remove");
DPRINT_EXIT(NETVSC_DRV);
return 0; return 0;
} }
if (!net_drv_obj->Base.OnDeviceRemove) { if (!net_drv_obj->Base.OnDeviceRemove)
DPRINT_EXIT(NETVSC_DRV);
return -1; return -1;
}
/* Stop outbound asap */ /* Stop outbound asap */
netif_stop_queue(net); netif_stop_queue(net);
@ -452,7 +439,6 @@ static int netvsc_remove(struct device *device)
} }
free_netdev(net); free_netdev(net);
DPRINT_EXIT(NETVSC_DRV);
return ret; return ret;
} }
@ -497,8 +483,6 @@ static void netvsc_drv_exit(void)
vmbus_child_driver_unregister(drv_ctx); vmbus_child_driver_unregister(drv_ctx);
DPRINT_EXIT(NETVSC_DRV);
return; return;
} }
@ -527,8 +511,6 @@ static int netvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
/* The driver belongs to vmbus */ /* The driver belongs to vmbus */
ret = vmbus_child_driver_register(drv_ctx); ret = vmbus_child_driver_register(drv_ctx);
DPRINT_EXIT(NETVSC_DRV);
return ret; return ret;
} }
@ -548,24 +530,17 @@ MODULE_DEVICE_TABLE(dmi, hv_netvsc_dmi_table);
static int __init netvsc_init(void) static int __init netvsc_init(void)
{ {
int ret;
DPRINT_INFO(NETVSC_DRV, "Netvsc initializing...."); DPRINT_INFO(NETVSC_DRV, "Netvsc initializing....");
if (!dmi_check_system(hv_netvsc_dmi_table)) if (!dmi_check_system(hv_netvsc_dmi_table))
return -ENODEV; return -ENODEV;
ret = netvsc_drv_init(NetVscInitialize); return netvsc_drv_init(NetVscInitialize);
DPRINT_EXIT(NETVSC_DRV);
return ret;
} }
static void __exit netvsc_exit(void) static void __exit netvsc_exit(void)
{ {
netvsc_drv_exit(); netvsc_drv_exit();
DPRINT_EXIT(NETVSC_DRV);
} }
static const struct pci_device_id __initconst static const struct pci_device_id __initconst

View file

@ -380,9 +380,6 @@ int RingBufferWrite(RING_BUFFER_INFO *OutRingInfo,
byteAvailToWrite); byteAvailToWrite);
spin_unlock_irqrestore(&OutRingInfo->ring_lock, flags); spin_unlock_irqrestore(&OutRingInfo->ring_lock, flags);
DPRINT_EXIT(VMBUS);
return -1; return -1;
} }
@ -414,9 +411,6 @@ int RingBufferWrite(RING_BUFFER_INFO *OutRingInfo,
/* DumpRingInfo(OutRingInfo, "AFTER "); */ /* DumpRingInfo(OutRingInfo, "AFTER "); */
spin_unlock_irqrestore(&OutRingInfo->ring_lock, flags); spin_unlock_irqrestore(&OutRingInfo->ring_lock, flags);
DPRINT_EXIT(VMBUS);
return 0; return 0;
} }

View file

@ -263,7 +263,6 @@ static int RndisFilterSendRequest(struct rndis_device *Device,
packet->Completion.Send.SendCompletionTid = (unsigned long)Device; packet->Completion.Send.SendCompletionTid = (unsigned long)Device;
ret = gRndisFilter.InnerDriver.OnSend(Device->NetDevice->Device, packet); ret = gRndisFilter.InnerDriver.OnSend(Device->NetDevice->Device, packet);
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -321,8 +320,6 @@ static void RndisFilterReceiveResponse(struct rndis_device *Device,
Response->Message.InitializeComplete.RequestId, Response->Message.InitializeComplete.RequestId,
Response->NdisMessageType); Response->NdisMessageType);
} }
DPRINT_EXIT(NETVSC);
} }
static void RndisFilterReceiveIndicateStatus(struct rndis_device *Device, static void RndisFilterReceiveIndicateStatus(struct rndis_device *Device,
@ -371,8 +368,6 @@ static void RndisFilterReceiveData(struct rndis_device *Device,
gRndisFilter.InnerDriver.OnReceiveCallback(Device->NetDevice->Device, gRndisFilter.InnerDriver.OnReceiveCallback(Device->NetDevice->Device,
Packet); Packet);
DPRINT_EXIT(NETVSC);
} }
static int RndisFilterOnReceive(struct hv_device *Device, static int RndisFilterOnReceive(struct hv_device *Device,
@ -390,7 +385,6 @@ static int RndisFilterOnReceive(struct hv_device *Device,
if (!netDevice->Extension) { if (!netDevice->Extension) {
DPRINT_ERR(NETVSC, "got rndis message but no rndis device..." DPRINT_ERR(NETVSC, "got rndis message but no rndis device..."
"dropping this message!"); "dropping this message!");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
@ -398,7 +392,6 @@ static int RndisFilterOnReceive(struct hv_device *Device,
if (rndisDevice->State == RNDIS_DEV_UNINITIALIZED) { if (rndisDevice->State == RNDIS_DEV_UNINITIALIZED) {
DPRINT_ERR(NETVSC, "got rndis message but rndis device " DPRINT_ERR(NETVSC, "got rndis message but rndis device "
"uninitialized...dropping this message!"); "uninitialized...dropping this message!");
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
@ -423,7 +416,6 @@ static int RndisFilterOnReceive(struct hv_device *Device,
"bytes got %u)...dropping this message!", "bytes got %u)...dropping this message!",
rndisHeader->MessageLength, rndisHeader->MessageLength,
Packet->TotalDataBufferLength); Packet->TotalDataBufferLength);
DPRINT_EXIT(NETVSC);
return -1; return -1;
} }
#endif #endif
@ -471,7 +463,6 @@ static int RndisFilterOnReceive(struct hv_device *Device,
break; break;
} }
DPRINT_EXIT(NETVSC);
return 0; return 0;
} }
@ -526,7 +517,6 @@ static int RndisFilterQueryDevice(struct rndis_device *Device, u32 Oid,
Cleanup: Cleanup:
if (request) if (request)
PutRndisRequest(Device, request); PutRndisRequest(Device, request);
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -602,8 +592,6 @@ Cleanup:
if (request) if (request)
PutRndisRequest(Device, request); PutRndisRequest(Device, request);
Exit: Exit:
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -644,8 +632,6 @@ int RndisFilterInit(struct netvsc_driver *Driver)
/* Driver->QueryLinkStatus = RndisFilterQueryDeviceLinkStatus; */ /* Driver->QueryLinkStatus = RndisFilterQueryDeviceLinkStatus; */
Driver->OnReceiveCallback = RndisFilterOnReceive; Driver->OnReceiveCallback = RndisFilterOnReceive;
DPRINT_EXIT(NETVSC);
return 0; return 0;
} }
@ -694,7 +680,6 @@ static int RndisFilterInitDevice(struct rndis_device *Device)
Cleanup: Cleanup:
if (request) if (request)
PutRndisRequest(Device, request); PutRndisRequest(Device, request);
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -722,7 +707,6 @@ static void RndisFilterHaltDevice(struct rndis_device *Device)
Cleanup: Cleanup:
if (request) if (request)
PutRndisRequest(Device, request); PutRndisRequest(Device, request);
DPRINT_EXIT(NETVSC);
return; return;
} }
@ -740,7 +724,6 @@ static int RndisFilterOpenDevice(struct rndis_device *Device)
if (ret == 0) if (ret == 0)
Device->State = RNDIS_DEV_DATAINITIALIZED; Device->State = RNDIS_DEV_DATAINITIALIZED;
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -755,8 +738,6 @@ static int RndisFilterCloseDevice(struct rndis_device *Device)
if (ret == 0) if (ret == 0)
Device->State = RNDIS_DEV_INITIALIZED; Device->State = RNDIS_DEV_INITIALIZED;
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -769,10 +750,8 @@ static int RndisFilterOnDeviceAdd(struct hv_device *Device,
struct netvsc_device_info *deviceInfo = AdditionalInfo; struct netvsc_device_info *deviceInfo = AdditionalInfo;
rndisDevice = GetRndisDevice(); rndisDevice = GetRndisDevice();
if (!rndisDevice) { if (!rndisDevice)
DPRINT_EXIT(NETVSC);
return -1; return -1;
}
DPRINT_DBG(NETVSC, "rndis device object allocated - %p", rndisDevice); DPRINT_DBG(NETVSC, "rndis device object allocated - %p", rndisDevice);
@ -784,7 +763,6 @@ static int RndisFilterOnDeviceAdd(struct hv_device *Device,
ret = gRndisFilter.InnerDriver.Base.OnDeviceAdd(Device, AdditionalInfo); ret = gRndisFilter.InnerDriver.Base.OnDeviceAdd(Device, AdditionalInfo);
if (ret != 0) { if (ret != 0) {
kfree(rndisDevice); kfree(rndisDevice);
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -825,8 +803,6 @@ static int RndisFilterOnDeviceAdd(struct hv_device *Device,
DPRINT_INFO(NETVSC, "Device 0x%p link state %s", rndisDevice, DPRINT_INFO(NETVSC, "Device 0x%p link state %s", rndisDevice,
((deviceInfo->LinkState) ? ("down") : ("up"))); ((deviceInfo->LinkState) ? ("down") : ("up")));
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -844,44 +820,31 @@ static int RndisFilterOnDeviceRemove(struct hv_device *Device)
/* Pass control to inner driver to remove the device */ /* Pass control to inner driver to remove the device */
gRndisFilter.InnerDriver.Base.OnDeviceRemove(Device); gRndisFilter.InnerDriver.Base.OnDeviceRemove(Device);
DPRINT_EXIT(NETVSC);
return 0; return 0;
} }
static void RndisFilterOnCleanup(struct hv_driver *Driver) static void RndisFilterOnCleanup(struct hv_driver *Driver)
{ {
DPRINT_EXIT(NETVSC);
} }
int RndisFilterOnOpen(struct hv_device *Device) int RndisFilterOnOpen(struct hv_device *Device)
{ {
int ret;
struct netvsc_device *netDevice = Device->Extension; struct netvsc_device *netDevice = Device->Extension;
if (!netDevice) if (!netDevice)
return -EINVAL; return -EINVAL;
ret = RndisFilterOpenDevice(netDevice->Extension); return RndisFilterOpenDevice(netDevice->Extension);
DPRINT_EXIT(NETVSC);
return ret;
} }
int RndisFilterOnClose(struct hv_device *Device) int RndisFilterOnClose(struct hv_device *Device)
{ {
int ret;
struct netvsc_device *netDevice = Device->Extension; struct netvsc_device *netDevice = Device->Extension;
if (!netDevice) if (!netDevice)
return -EINVAL; return -EINVAL;
ret = RndisFilterCloseDevice(netDevice->Extension); return RndisFilterCloseDevice(netDevice->Extension);
DPRINT_EXIT(NETVSC);
return ret;
} }
static int RndisFilterOnSend(struct hv_device *Device, static int RndisFilterOnSend(struct hv_device *Device,
@ -937,8 +900,6 @@ static int RndisFilterOnSend(struct hv_device *Device,
filterPacket->CompletionContext; filterPacket->CompletionContext;
} }
DPRINT_EXIT(NETVSC);
return ret; return ret;
} }
@ -948,13 +909,10 @@ static void RndisFilterOnSendCompletion(void *Context)
/* Pass it back to the original handler */ /* Pass it back to the original handler */
filterPacket->OnCompletion(filterPacket->CompletionContext); filterPacket->OnCompletion(filterPacket->CompletionContext);
DPRINT_EXIT(NETVSC);
} }
static void RndisFilterOnSendRequestCompletion(void *Context) static void RndisFilterOnSendRequestCompletion(void *Context)
{ {
/* Noop */ /* Noop */
DPRINT_EXIT(NETVSC);
} }

View file

@ -186,7 +186,6 @@ static int StorVscChannelInit(struct hv_device *Device)
if (!storDevice) { if (!storDevice) {
DPRINT_ERR(STORVSC, "unable to get stor device..." DPRINT_ERR(STORVSC, "unable to get stor device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(STORVSC);
return -1; return -1;
} }
@ -344,8 +343,6 @@ Cleanup:
request->WaitEvent = NULL; request->WaitEvent = NULL;
nomem: nomem:
PutStorDevice(Device); PutStorDevice(Device);
DPRINT_EXIT(STORVSC);
return ret; return ret;
} }
@ -360,7 +357,6 @@ static void StorVscOnIOCompletion(struct hv_device *Device,
if (!storDevice) { if (!storDevice) {
DPRINT_ERR(STORVSC, "unable to get stor device..." DPRINT_ERR(STORVSC, "unable to get stor device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(STORVSC);
return; return;
} }
@ -412,8 +408,6 @@ static void StorVscOnIOCompletion(struct hv_device *Device,
atomic_dec(&storDevice->NumOutstandingRequests); atomic_dec(&storDevice->NumOutstandingRequests);
PutStorDevice(Device); PutStorDevice(Device);
DPRINT_EXIT(STORVSC);
} }
static void StorVscOnReceive(struct hv_device *Device, static void StorVscOnReceive(struct hv_device *Device,
@ -453,7 +447,6 @@ static void StorVscOnChannelCallback(void *context)
if (!storDevice) { if (!storDevice) {
DPRINT_ERR(STORVSC, "unable to get stor device..." DPRINT_ERR(STORVSC, "unable to get stor device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(STORVSC);
return; return;
} }
@ -497,8 +490,6 @@ static void StorVscOnChannelCallback(void *context)
} while (1); } while (1);
PutStorDevice(device); PutStorDevice(device);
DPRINT_EXIT(STORVSC);
return; return;
} }
@ -578,8 +569,6 @@ static int StorVscOnDeviceAdd(struct hv_device *Device, void *AdditionalInfo)
storDevice->TargetId); storDevice->TargetId);
Cleanup: Cleanup:
DPRINT_EXIT(STORVSC);
return ret; return ret;
} }
@ -617,8 +606,6 @@ static int StorVscOnDeviceRemove(struct hv_device *Device)
Device->Driver->VmbusChannelInterface.Close(Device); Device->Driver->VmbusChannelInterface.Close(Device);
FreeStorDevice(storDevice); FreeStorDevice(storDevice);
DPRINT_EXIT(STORVSC);
return 0; return 0;
} }
@ -635,7 +622,6 @@ int StorVscOnHostReset(struct hv_device *Device)
if (!storDevice) { if (!storDevice) {
DPRINT_ERR(STORVSC, "unable to get stor device..." DPRINT_ERR(STORVSC, "unable to get stor device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(STORVSC);
return -1; return -1;
} }
@ -677,7 +663,6 @@ int StorVscOnHostReset(struct hv_device *Device)
Cleanup: Cleanup:
PutStorDevice(Device); PutStorDevice(Device);
DPRINT_EXIT(STORVSC);
return ret; return ret;
} }
@ -708,7 +693,6 @@ static int StorVscOnIORequest(struct hv_device *Device,
if (!storDevice) { if (!storDevice) {
DPRINT_ERR(STORVSC, "unable to get stor device..." DPRINT_ERR(STORVSC, "unable to get stor device..."
"device being destroyed?"); "device being destroyed?");
DPRINT_EXIT(STORVSC);
return -2; return -2;
} }
@ -774,8 +758,6 @@ static int StorVscOnIORequest(struct hv_device *Device,
atomic_inc(&storDevice->NumOutstandingRequests); atomic_inc(&storDevice->NumOutstandingRequests);
PutStorDevice(Device); PutStorDevice(Device);
DPRINT_EXIT(STORVSC);
return ret; return ret;
} }
@ -784,7 +766,6 @@ static int StorVscOnIORequest(struct hv_device *Device,
*/ */
static void StorVscOnCleanup(struct hv_driver *Driver) static void StorVscOnCleanup(struct hv_driver *Driver)
{ {
DPRINT_EXIT(STORVSC);
} }
/* /*
@ -837,7 +818,5 @@ int StorVscInitialize(struct hv_driver *Driver)
storDriver->OnIORequest = StorVscOnIORequest; storDriver->OnIORequest = StorVscOnIORequest;
DPRINT_EXIT(STORVSC);
return 0; return 0;
} }

View file

@ -173,8 +173,6 @@ static int storvsc_drv_init(int (*drv_init)(struct hv_driver *drv))
/* The driver belongs to vmbus */ /* The driver belongs to vmbus */
ret = vmbus_child_driver_register(drv_ctx); ret = vmbus_child_driver_register(drv_ctx);
DPRINT_EXIT(STORVSC_DRV);
return ret; return ret;
} }
@ -215,9 +213,6 @@ static void storvsc_drv_exit(void)
storvsc_drv_obj->Base.OnCleanup(&storvsc_drv_obj->Base); storvsc_drv_obj->Base.OnCleanup(&storvsc_drv_obj->Base);
vmbus_child_driver_unregister(drv_ctx); vmbus_child_driver_unregister(drv_ctx);
DPRINT_EXIT(STORVSC_DRV);
return; return;
} }
@ -265,8 +260,6 @@ static int storvsc_probe(struct device *device)
if (!host_device_ctx->request_pool) { if (!host_device_ctx->request_pool) {
scsi_host_put(host); scsi_host_put(host);
DPRINT_EXIT(STORVSC_DRV);
return -ENOMEM; return -ENOMEM;
} }
@ -278,8 +271,6 @@ static int storvsc_probe(struct device *device)
DPRINT_ERR(STORVSC_DRV, "unable to add scsi vsc device"); DPRINT_ERR(STORVSC_DRV, "unable to add scsi vsc device");
kmem_cache_destroy(host_device_ctx->request_pool); kmem_cache_destroy(host_device_ctx->request_pool);
scsi_host_put(host); scsi_host_put(host);
DPRINT_EXIT(STORVSC_DRV);
return -1; return -1;
} }
@ -303,15 +294,10 @@ static int storvsc_probe(struct device *device)
kmem_cache_destroy(host_device_ctx->request_pool); kmem_cache_destroy(host_device_ctx->request_pool);
scsi_host_put(host); scsi_host_put(host);
DPRINT_EXIT(STORVSC_DRV);
return -1; return -1;
} }
scsi_scan_host(host); scsi_scan_host(host);
DPRINT_EXIT(STORVSC_DRV);
return ret; return ret;
} }
@ -334,10 +320,8 @@ static int storvsc_remove(struct device *device)
(struct host_device_context *)host->hostdata; (struct host_device_context *)host->hostdata;
if (!storvsc_drv_obj->Base.OnDeviceRemove) { if (!storvsc_drv_obj->Base.OnDeviceRemove)
DPRINT_EXIT(STORVSC_DRV);
return -1; return -1;
}
/* /*
* Call to the vsc driver to let it know that the device is being * Call to the vsc driver to let it know that the device is being
@ -360,9 +344,6 @@ static int storvsc_remove(struct device *device)
DPRINT_INFO(STORVSC, "releasing host adapter (%p)...", host); DPRINT_INFO(STORVSC, "releasing host adapter (%p)...", host);
scsi_host_put(host); scsi_host_put(host);
DPRINT_EXIT(STORVSC_DRV);
return ret; return ret;
} }
@ -417,8 +398,6 @@ static void storvsc_commmand_completion(struct hv_storvsc_request *request)
scsi_done_fn(scmnd); scsi_done_fn(scmnd);
kmem_cache_free(host_device_ctx->request_pool, cmd_request); kmem_cache_free(host_device_ctx->request_pool, cmd_request);
DPRINT_EXIT(STORVSC_DRV);
} }
static int do_bounce_buffer(struct scatterlist *sgl, unsigned int sg_count) static int do_bounce_buffer(struct scatterlist *sgl, unsigned int sg_count)
@ -800,8 +779,6 @@ retry_request:
ret = SCSI_MLQUEUE_DEVICE_BUSY; ret = SCSI_MLQUEUE_DEVICE_BUSY;
} }
DPRINT_EXIT(STORVSC_DRV);
return ret; return ret;
} }
@ -866,16 +843,12 @@ static int storvsc_host_reset_handler(struct scsi_cmnd *scmnd)
/* Invokes the vsc to reset the host/bus */ /* Invokes the vsc to reset the host/bus */
ret = StorVscOnHostReset(&device_ctx->device_obj); ret = StorVscOnHostReset(&device_ctx->device_obj);
if (ret != 0) { if (ret != 0)
DPRINT_EXIT(STORVSC_DRV);
return ret; return ret;
}
DPRINT_INFO(STORVSC_DRV, "sdev (%p) dev obj (%p) - host reseted", DPRINT_INFO(STORVSC_DRV, "sdev (%p) dev obj (%p) - host reseted",
scmnd->device, &device_ctx->device_obj); scmnd->device, &device_ctx->device_obj);
DPRINT_EXIT(STORVSC_DRV);
return ret; return ret;
} }
@ -965,7 +938,6 @@ static int __init storvsc_init(void)
DPRINT_INFO(STORVSC_DRV, "Storvsc initializing...."); DPRINT_INFO(STORVSC_DRV, "Storvsc initializing....");
ret = storvsc_drv_init(StorVscInitialize); ret = storvsc_drv_init(StorVscInitialize);
DPRINT_EXIT(STORVSC_DRV);
return ret; return ret;
} }

View file

@ -58,7 +58,6 @@ static struct hv_device *gDevice; /* vmbus root device */
static void VmbusGetChannelOffers(void) static void VmbusGetChannelOffers(void)
{ {
VmbusChannelRequestOffers(); VmbusChannelRequestOffers();
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -133,8 +132,6 @@ static int VmbusOnDeviceAdd(struct hv_device *dev, void *AdditionalInfo)
ret = VmbusConnect(); ret = VmbusConnect();
/* VmbusSendEvent(device->localPortId+1); */ /* VmbusSendEvent(device->localPortId+1); */
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -148,8 +145,6 @@ static int VmbusOnDeviceRemove(struct hv_device *dev)
VmbusChannelReleaseUnattachedChannels(); VmbusChannelReleaseUnattachedChannels();
VmbusDisconnect(); VmbusDisconnect();
on_each_cpu(HvSynicCleanup, NULL, 1); on_each_cpu(HvSynicCleanup, NULL, 1);
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -161,7 +156,6 @@ static void VmbusOnCleanup(struct hv_driver *drv)
/* struct vmbus_driver *driver = (struct vmbus_driver *)drv; */ /* struct vmbus_driver *driver = (struct vmbus_driver *)drv; */
HvCleanup(); HvCleanup();
DPRINT_EXIT(VMBUS);
} }
/* /*
@ -252,7 +246,6 @@ static int VmbusOnISR(struct hv_driver *drv)
ret |= 0x2; ret |= 0x2;
} }
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }
@ -296,7 +289,5 @@ int VmbusInitialize(struct hv_driver *drv)
ret); ret);
gDriver = drv; gDriver = drv;
DPRINT_EXIT(VMBUS);
return ret; return ret;
} }

View file

@ -355,8 +355,6 @@ static int vmbus_bus_init(int (*drv_init)(struct hv_driver *drv))
vmbus_drv_obj->GetChannelOffers(); vmbus_drv_obj->GetChannelOffers();
cleanup: cleanup:
DPRINT_EXIT(VMBUS_DRV);
return ret; return ret;
} }
@ -388,10 +386,6 @@ static void vmbus_bus_exit(void)
tasklet_kill(&vmbus_drv_ctx->msg_dpc); tasklet_kill(&vmbus_drv_ctx->msg_dpc);
tasklet_kill(&vmbus_drv_ctx->event_dpc); tasklet_kill(&vmbus_drv_ctx->event_dpc);
DPRINT_EXIT(VMBUS_DRV);
return;
} }
@ -422,8 +416,6 @@ int vmbus_child_driver_register(struct driver_context *driver_ctx)
vmbus_drv_obj->GetChannelOffers(); vmbus_drv_obj->GetChannelOffers();
DPRINT_EXIT(VMBUS_DRV);
return ret; return ret;
} }
EXPORT_SYMBOL(vmbus_child_driver_register); EXPORT_SYMBOL(vmbus_child_driver_register);
@ -447,8 +439,6 @@ void vmbus_child_driver_unregister(struct driver_context *driver_ctx)
driver_unregister(&driver_ctx->driver); driver_unregister(&driver_ctx->driver);
driver_ctx->driver.bus = NULL; driver_ctx->driver.bus = NULL;
DPRINT_EXIT(VMBUS_DRV);
} }
EXPORT_SYMBOL(vmbus_child_driver_unregister); EXPORT_SYMBOL(vmbus_child_driver_unregister);
@ -500,8 +490,6 @@ static struct hv_device *vmbus_child_device_create(struct hv_guid *type,
if (!child_device_ctx) { if (!child_device_ctx) {
DPRINT_ERR(VMBUS_DRV, DPRINT_ERR(VMBUS_DRV,
"unable to allocate device_context for child device"); "unable to allocate device_context for child device");
DPRINT_EXIT(VMBUS_DRV);
return NULL; return NULL;
} }
@ -533,8 +521,6 @@ static struct hv_device *vmbus_child_device_create(struct hv_guid *type,
memcpy(&child_device_ctx->class_id, type, sizeof(struct hv_guid)); memcpy(&child_device_ctx->class_id, type, sizeof(struct hv_guid));
memcpy(&child_device_ctx->device_id, instance, sizeof(struct hv_guid)); memcpy(&child_device_ctx->device_id, instance, sizeof(struct hv_guid));
DPRINT_EXIT(VMBUS_DRV);
return child_device_obj; return child_device_obj;
} }
@ -579,8 +565,6 @@ static int vmbus_child_device_register(struct hv_device *root_device_obj,
DPRINT_INFO(VMBUS_DRV, "child device (%p) registered", DPRINT_INFO(VMBUS_DRV, "child device (%p) registered",
&child_device_ctx->device); &child_device_ctx->device);
DPRINT_EXIT(VMBUS_DRV);
return ret; return ret;
} }
@ -603,8 +587,6 @@ static void vmbus_child_device_unregister(struct hv_device *device_obj)
DPRINT_INFO(VMBUS_DRV, "child device (%p) unregistered", DPRINT_INFO(VMBUS_DRV, "child device (%p) unregistered",
&device_ctx->device); &device_ctx->device);
DPRINT_EXIT(VMBUS_DRV);
} }
/* /*
@ -612,7 +594,6 @@ static void vmbus_child_device_unregister(struct hv_device *device_obj)
*/ */
static void vmbus_child_device_destroy(struct hv_device *device_obj) static void vmbus_child_device_destroy(struct hv_device *device_obj)
{ {
DPRINT_EXIT(VMBUS_DRV);
} }
/* /*
@ -687,8 +668,6 @@ static int vmbus_uevent(struct device *device, struct kobj_uevent_env *env)
if (ret) if (ret)
return ret; return ret;
DPRINT_EXIT(VMBUS_DRV);
return 0; return 0;
} }
@ -719,9 +698,6 @@ static int vmbus_match(struct device *device, struct device_driver *driver)
match = 1; match = 1;
} }
DPRINT_EXIT(VMBUS_DRV);
return match; return match;
} }
@ -743,7 +719,6 @@ static void vmbus_probe_failed_cb(struct work_struct *context)
device_unregister(&device_ctx->device); device_unregister(&device_ctx->device);
/* put_device(&device_ctx->device); */ /* put_device(&device_ctx->device); */
DPRINT_EXIT(VMBUS_DRV);
} }
/* /*
@ -775,8 +750,6 @@ static int vmbus_probe(struct device *child_device)
child_device->driver->name); child_device->driver->name);
ret = -1; ret = -1;
} }
DPRINT_EXIT(VMBUS_DRV);
return ret; return ret;
} }
@ -794,7 +767,6 @@ static int vmbus_remove(struct device *child_device)
* No-op since it is statically defined and handle in * No-op since it is statically defined and handle in
* vmbus_bus_exit() * vmbus_bus_exit()
*/ */
DPRINT_EXIT(VMBUS_DRV);
return 0; return 0;
} }
@ -815,8 +787,6 @@ static int vmbus_remove(struct device *child_device)
} }
} }
DPRINT_EXIT(VMBUS_DRV);
return 0; return 0;
} }
@ -833,15 +803,12 @@ static void vmbus_shutdown(struct device *child_device)
* No-op since it is statically defined and handle in * No-op since it is statically defined and handle in
* vmbus_bus_exit() * vmbus_bus_exit()
*/ */
DPRINT_EXIT(VMBUS_DRV);
return; return;
} }
/* The device may not be attached yet */ /* The device may not be attached yet */
if (!child_device->driver) { if (!child_device->driver)
DPRINT_EXIT(VMBUS_DRV);
return; return;
}
driver_ctx = driver_to_driver_context(child_device->driver); driver_ctx = driver_to_driver_context(child_device->driver);
@ -849,8 +816,6 @@ static void vmbus_shutdown(struct device *child_device)
if (driver_ctx->shutdown) if (driver_ctx->shutdown)
driver_ctx->shutdown(child_device); driver_ctx->shutdown(child_device);
DPRINT_EXIT(VMBUS_DRV);
return; return;
} }
@ -864,7 +829,6 @@ static void vmbus_bus_release(struct device *device)
* of a problem design, this MUST BE FIXED! */ * of a problem design, this MUST BE FIXED! */
dev_err(device, "%s needs to be fixed!\n", __func__); dev_err(device, "%s needs to be fixed!\n", __func__);
WARN_ON(1); WARN_ON(1);
DPRINT_EXIT(VMBUS_DRV);
} }
/* /*
@ -878,9 +842,6 @@ static void vmbus_device_release(struct device *device)
kfree(device_ctx); kfree(device_ctx);
/* !!DO NOT REFERENCE device_ctx anymore at this point!! */ /* !!DO NOT REFERENCE device_ctx anymore at this point!! */
DPRINT_EXIT(VMBUS_DRV);
return;
} }
/* /*
@ -894,8 +855,6 @@ static void vmbus_msg_dpc(unsigned long data)
/* Call to bus driver to handle interrupt */ /* Call to bus driver to handle interrupt */
vmbus_drv_obj->OnMsgDpc(&vmbus_drv_obj->Base); vmbus_drv_obj->OnMsgDpc(&vmbus_drv_obj->Base);
DPRINT_EXIT(VMBUS_DRV);
} }
/* /*
@ -909,8 +868,6 @@ static void vmbus_event_dpc(unsigned long data)
/* Call to bus driver to handle interrupt */ /* Call to bus driver to handle interrupt */
vmbus_drv_obj->OnEventDpc(&vmbus_drv_obj->Base); vmbus_drv_obj->OnEventDpc(&vmbus_drv_obj->Base);
DPRINT_EXIT(VMBUS_DRV);
} }
static irqreturn_t vmbus_isr(int irq, void *dev_id) static irqreturn_t vmbus_isr(int irq, void *dev_id)
@ -931,10 +888,8 @@ static irqreturn_t vmbus_isr(int irq, void *dev_id)
if (test_bit(1, (unsigned long *)&ret)) if (test_bit(1, (unsigned long *)&ret))
tasklet_schedule(&g_vmbus_drv.event_dpc); tasklet_schedule(&g_vmbus_drv.event_dpc);
DPRINT_EXIT(VMBUS_DRV);
return IRQ_HANDLED; return IRQ_HANDLED;
} else { } else {
DPRINT_EXIT(VMBUS_DRV);
return IRQ_NONE; return IRQ_NONE;
} }
} }
@ -954,8 +909,6 @@ MODULE_DEVICE_TABLE(dmi, microsoft_hv_dmi_table);
static int __init vmbus_init(void) static int __init vmbus_init(void)
{ {
int ret = 0;
DPRINT_INFO(VMBUS_DRV, DPRINT_INFO(VMBUS_DRV,
"Vmbus initializing.... current log level 0x%x (%x,%x)", "Vmbus initializing.... current log level 0x%x (%x,%x)",
vmbus_loglevel, HIWORD(vmbus_loglevel), LOWORD(vmbus_loglevel)); vmbus_loglevel, HIWORD(vmbus_loglevel), LOWORD(vmbus_loglevel));
@ -964,18 +917,13 @@ static int __init vmbus_init(void)
if (!dmi_check_system(microsoft_hv_dmi_table)) if (!dmi_check_system(microsoft_hv_dmi_table))
return -ENODEV; return -ENODEV;
ret = vmbus_bus_init(VmbusInitialize); return vmbus_bus_init(VmbusInitialize);
DPRINT_EXIT(VMBUS_DRV);
return ret;
} }
static void __exit vmbus_exit(void) static void __exit vmbus_exit(void)
{ {
vmbus_bus_exit(); vmbus_bus_exit();
/* Todo: it is used for loglevel, to be ported to new kernel. */ /* Todo: it is used for loglevel, to be ported to new kernel. */
DPRINT_EXIT(VMBUS_DRV);
return;
} }
/* /*