[ovs-dev] [PATCH] datapath-windows: Fix static analysis in Stt.c

Alin Gabriel Serdean aserdean at ovn.org
Thu Feb 8 17:30:41 UTC 2018


The WDK 10 static analysis complains:
stt.c(427): warning C30030: Warning: Allocating executable memory via
specifying a MM_PAGE_PRIORITY type without a bitwise OR with
MdlMappingNoExecute.

Signed-off-by: Alin Gabriel Serdean <aserdean at ovn.org>
---
 datapath-windows/ovsext/Stt.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/datapath-windows/ovsext/Stt.c b/datapath-windows/ovsext/Stt.c
index e3c4b4686..0220a6e80 100644
--- a/datapath-windows/ovsext/Stt.c
+++ b/datapath-windows/ovsext/Stt.c
@@ -424,8 +424,8 @@ OvsValidateTCPChecksum(PNET_BUFFER_LIST curNbl,
     NDIS_STATUS status;
 
     curMdl = NET_BUFFER_CURRENT_MDL(curNb);
-    buf = (PUINT8)MmGetSystemAddressForMdlSafe(curMdl, LowPagePriority)
-        + NET_BUFFER_CURRENT_MDL_OFFSET(curNb);
+    buf = (PUINT8)OvsGetMdlWithLowPriority(curMdl)
+          + NET_BUFFER_CURRENT_MDL_OFFSET(curNb);
     if (!buf) {
         status = NDIS_STATUS_INVALID_PACKET;
         return status;
-- 
2.16.1.windows.1



More information about the dev mailing list