[ovs-dev] [PATCH 17/40] datapath-windows: Add function annotations for OvsReleaseDatapath
Alin Serdean
aserdean at cloudbasesolutions.com
Fri Jul 14 04:40:54 UTC 2017
The function should be aware that it requires a certain dispatch level,
restores the dispatch level, requires lock held and releases a lock.
This patch adds annotation for that.
Signed-off-by: Alin Gabriel Serdean <aserdean at cloudbasesolutions.com>
---
datapath-windows/ovsext/Switch.h | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/datapath-windows/ovsext/Switch.h b/datapath-windows/ovsext/Switch.h
index 5e856e2..18a9ec6 100644
--- a/datapath-windows/ovsext/Switch.h
+++ b/datapath-windows/ovsext/Switch.h
@@ -210,6 +210,10 @@ OvsAcquireDatapathWrite(OVS_DATAPATH *datapath,
dispatch ? NDIS_RWL_AT_DISPATCH_LEVEL : 0);
}
+_IRQL_requires_(DISPATCH_LEVEL)
+_IRQL_restores_global_(OldIrql, lockState)
+_Requires_lock_held_(datapath->lock)
+_Releases_lock_(datapath->lock)
static __inline VOID
OvsReleaseDatapath(OVS_DATAPATH *datapath,
LOCK_STATE_EX *lockState)
--
2.10.2.windows.1
More information about the dev
mailing list