Signed-off-by: Ankur Sharma <[email protected]>
---
datapath-windows/ovsext/User.c | 6 ++++--
datapath-windows/ovsext/User.h | 6 +++---
2 files changed, 7 insertions(+), 5 deletions(-)
diff --git a/datapath-windows/ovsext/User.c b/datapath-windows/ovsext/User.c
index 42b251f..cce99a5 100644
--- a/datapath-windows/ovsext/User.c
+++ b/datapath-windows/ovsext/User.c
@@ -141,6 +141,7 @@ OvsSubscribeDpIoctl(PVOID instanceP,
OvsReleaseCtrlLock();
return STATUS_INVALID_PARAMETER;
}
+ OvsReleaseCtrlLock();
if (instance->packetQueue && !join) {
/* unsubscribe */
@@ -171,7 +172,6 @@ OvsSubscribeDpIoctl(PVOID instanceP,
OvsAddPidInstance(gOvsSwitchContext, pid, instance);
OvsReleaseCtrlLock();
-
} else {
/* user mode should call only once for subscribe */
return STATUS_INVALID_PARAMETER;
@@ -1009,7 +1009,9 @@ OvsCreateQueueNlPacket(PVOID userData,
return NULL;
}
- if (!OvsGetPid(vport, nb, &pid)) {
+ OvsGetPid(vport, nb, &pid);
+
+ if (!pid) {
/*
* There is no userspace queue created yet, so there is no point for
* creating a new packet to be queued.
diff --git a/datapath-windows/ovsext/User.h b/datapath-windows/ovsext/User.h
index 47fb10b..139b0ca 100644
--- a/datapath-windows/ovsext/User.h
+++ b/datapath-windows/ovsext/User.h
@@ -1,4 +1,4 @@
-/*
+ /*
* Copyright (c) 2014 VMware, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
@@ -49,6 +49,7 @@ typedef struct _OVS_USER_PACKET_QUEUE {
} OVS_USER_PACKET_QUEUE, *POVS_USER_PACKET_QUEUE;
typedef struct _OVS_PACKET_QUEUE_ELEM {
+ UINT32 upcallPid;
LIST_ENTRY link;
OVS_PACKET_HDR_INFO hdrInfo;
OVS_PACKET_INFO packet;
@@ -78,8 +79,7 @@ POVS_PACKET_QUEUE_ELEM OvsCreateQueueNlPacket(PVOID userData,
BOOLEAN isRecv,
POVS_PACKET_HDR_INFO hdrInfo);
-VOID OvsQueuePackets(UINT32 queueId, PLIST_ENTRY packetList,
- UINT32 numElems);
+VOID OvsQueuePackets(PLIST_ENTRY packetList, UINT32 numElems);
NTSTATUS OvsCreateAndAddPackets(PVOID userData,
UINT32 userDataLen,
UINT32 cmd,
--
1.9.1
_______________________________________________
dev mailing list
[email protected]
http://openvswitch.org/mailman/listinfo/dev