From 3f17438e95a36a00cf861cc1557e999a4bb793cf Mon Sep 17 00:00:00 2001 From: Gaurav Singh Date: Wed, 4 Dec 2024 01:48:18 +0530 Subject: [PATCH] removed IgnoreCE --- src/core/frame.c | 31 ++++--------------------------- src/core/frame.h | 2 -- src/core/send.c | 1 - 3 files changed, 4 insertions(+), 30 deletions(-) diff --git a/src/core/frame.c b/src/core/frame.c index b9aa854f56..3f45f6abfa 100644 --- a/src/core/frame.c +++ b/src/core/frame.c @@ -1234,18 +1234,6 @@ QuicDatagramFrameDecode( return TRUE; } -typedef struct QUIC_ACK_FREQUENCY_EXTRAS { - - union { - struct { - uint8_t IgnoreCE : 1; - uint8_t Reserved : 6; - }; - uint8_t Value; - }; - -} QUIC_ACK_FREQUENCY_EXTRAS; - _Success_(return != FALSE) BOOLEAN QuicAckFrequencyFrameEncode( @@ -1260,25 +1248,18 @@ QuicAckFrequencyFrameEncode( QuicVarIntSize(Frame->SequenceNumber) + QuicVarIntSize(Frame->PacketTolerance) + QuicVarIntSize(Frame->UpdateMaxAckDelay) + - QuicVarIntSize(Frame->ReorderingThreshold) + - sizeof(QUIC_ACK_FREQUENCY_EXTRAS); + QuicVarIntSize(Frame->ReorderingThreshold); if (BufferLength < *Offset + RequiredLength) { return FALSE; } - CXPLAT_DBG_ASSERT(Frame->IgnoreCE <= 1); // IgnoreCE should only be 0 or 1. - - QUIC_ACK_FREQUENCY_EXTRAS Extras = { .Value = 0 }; - Extras.IgnoreCE = Frame->IgnoreCE; - Buffer = Buffer + *Offset; Buffer = QuicVarIntEncode(QUIC_FRAME_ACK_FREQUENCY, Buffer); Buffer = QuicVarIntEncode(Frame->SequenceNumber, Buffer); Buffer = QuicVarIntEncode(Frame->PacketTolerance, Buffer); Buffer = QuicVarIntEncode(Frame->UpdateMaxAckDelay, Buffer); Buffer = QuicVarIntEncode(Frame->ReorderingThreshold, Buffer); - QuicUint8Encode(Extras.Value, Buffer); *Offset += RequiredLength; return TRUE; @@ -1294,15 +1275,12 @@ QuicAckFrequencyFrameDecode( _Out_ QUIC_ACK_FREQUENCY_EX* Frame ) { - QUIC_ACK_FREQUENCY_EXTRAS Extras; if (!QuicVarIntDecode(BufferLength, Buffer, Offset, &Frame->SequenceNumber) || !QuicVarIntDecode(BufferLength, Buffer, Offset, &Frame->PacketTolerance) || !QuicVarIntDecode(BufferLength, Buffer, Offset, &Frame->UpdateMaxAckDelay) || - !QuicVarIntDecode(BufferLength, Buffer, Offset, &Frame->ReorderingThreshold) || - !QuicUint8tDecode(BufferLength, Buffer, Offset, &Extras.Value)) { + !QuicVarIntDecode(BufferLength, Buffer, Offset, &Frame->ReorderingThreshold)) { return FALSE; } - Frame->IgnoreCE = Extras.IgnoreCE; return TRUE; } @@ -1962,15 +1940,14 @@ QuicFrameLog( QuicTraceLogVerbose( FrameLogAckFrequency, - "[%c][%cX][%llu] ACK_FREQUENCY SeqNum:%llu PktTolerance:%llu MaxAckDelay:%llu ReorderThreshold:%llu IgnoreCE:%hhu", + "[%c][%cX][%llu] ACK_FREQUENCY SeqNum:%llu PktTolerance:%llu MaxAckDelay:%llu ReorderThreshold:%llu", PtkConnPre(Connection), PktRxPre(Rx), PacketNumber, Frame.SequenceNumber, Frame.PacketTolerance, Frame.UpdateMaxAckDelay, - Frame.ReorderingThreshold, - Frame.IgnoreCE); + Frame.ReorderingThreshold); break; } diff --git a/src/core/frame.h b/src/core/frame.h index 9e448d83f0..8ff32fb9c2 100644 --- a/src/core/frame.h +++ b/src/core/frame.h @@ -847,8 +847,6 @@ typedef struct QUIC_ACK_FREQUENCY_EX { QUIC_VAR_INT PacketTolerance; QUIC_VAR_INT UpdateMaxAckDelay; // In microseconds (us) QUIC_VAR_INT ReorderingThreshold; - BOOLEAN IgnoreCE; - } QUIC_ACK_FREQUENCY_EX; _Success_(return != FALSE) diff --git a/src/core/send.c b/src/core/send.c index c0664bf718..2552774e5d 100644 --- a/src/core/send.c +++ b/src/core/send.c @@ -897,7 +897,6 @@ QuicSendWriteFrames( Frame.PacketTolerance = Connection->PeerPacketTolerance; Frame.UpdateMaxAckDelay = MS_TO_US(QuicConnGetAckDelay(Connection)); Frame.ReorderingThreshold = Connection->PeerReorderingThreshold; - Frame.IgnoreCE = FALSE; if (QuicAckFrequencyFrameEncode( &Frame,