From 6cd0feeb830adf831c7459e4b610d14993eff02d Mon Sep 17 00:00:00 2001 From: ami-GS <1991.daiki@gmail.com> Date: Thu, 12 Dec 2024 17:03:22 -0800 Subject: [PATCH] make status code valid for both user/kernel --- src/platform/datapath_raw_xdp_wincommon.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/platform/datapath_raw_xdp_wincommon.h b/src/platform/datapath_raw_xdp_wincommon.h index d6a31de304..895264cc35 100644 --- a/src/platform/datapath_raw_xdp_wincommon.h +++ b/src/platform/datapath_raw_xdp_wincommon.h @@ -1543,13 +1543,13 @@ CxPlatXdpExecute( CxPlatZeroMemory( &Queue->RxIoSqe.DatapathSqe.Sqe.Overlapped, sizeof(Queue->RxIoSqe.DatapathSqe.Sqe.Overlapped)); - HRESULT hr = + QUIC_STATUS hr = XskNotifyAsync( Queue->RxXsk, XSK_NOTIFY_FLAG_WAIT_RX, &Queue->RxIoSqe.DatapathSqe.Sqe.Overlapped); - if (hr == HRESULT_FROM_WIN32(ERROR_IO_PENDING)) { + if (hr == QUIC_STATUS_PENDING) { Queue->RxQueued = TRUE; - } else if (hr == S_OK) { + } else if (hr == QUIC_STATUS_SUCCESS) { Partition->Ec.Ready = TRUE; } else { QuicTraceEvent( @@ -1567,13 +1567,13 @@ CxPlatXdpExecute( CxPlatZeroMemory( &Queue->TxIoSqe.DatapathSqe.Sqe.Overlapped, sizeof(Queue->TxIoSqe.DatapathSqe.Sqe.Overlapped)); - HRESULT hr = + QUIC_STATUS hr = XskNotifyAsync( Queue->TxXsk, XSK_NOTIFY_FLAG_WAIT_TX, &Queue->TxIoSqe.DatapathSqe.Sqe.Overlapped); - if (hr == HRESULT_FROM_WIN32(ERROR_IO_PENDING)) { + if (hr == QUIC_STATUS_PENDING) { Queue->TxQueued = TRUE; - } else if (hr == S_OK) { + } else if (hr == QUIC_STATUS_SUCCESS) { Partition->Ec.Ready = TRUE; } else { QuicTraceEvent(