Skip to content

Commit

Permalink
use common members
Browse files Browse the repository at this point in the history
  • Loading branch information
ami-GS committed Nov 14, 2024
1 parent 56c8ce0 commit 84593b2
Showing 1 changed file with 3 additions and 39 deletions.
42 changes: 3 additions & 39 deletions src/platform/platform_internal.h
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,8 @@ typedef struct _WSK_DATAGRAM_SOCKET {
// Per-port state.
//
typedef struct CXPLAT_SOCKET {
CXPLAT_SOCKET_COMMON;

//
// Flag indicates the binding has a default remote destination.
//
Expand All @@ -213,11 +215,6 @@ typedef struct CXPLAT_SOCKET {
//
BOOLEAN PcpBinding : 1;

//
// Parent datapath.
//
CXPLAT_DATAPATH* Datapath;

//
// UDP socket used for sending/receiving datagrams.
//
Expand All @@ -231,27 +228,6 @@ typedef struct CXPLAT_SOCKET {
//
CXPLAT_EVENT WskCompletionEvent;

// TODO: set. use QUICADDR by using CXPLAT_SOCKET_COMMON ---
//
// The local address and UDP port.
//
SOCKADDR_INET LocalAddress;

//
// The remote address and UDP port.
//
SOCKADDR_INET RemoteAddress;

//
// The local interface's MTU.
//
UINT16 Mtu;

//
// Client context pointer.
//
void *ClientContext;

//
// IRP used for socket functions.
//
Expand Down Expand Up @@ -311,23 +287,13 @@ typedef struct CXPLAT_DATAPATH_PROC_CONTEXT {
typedef struct CXPLAT_DATAPATH {
CXPLAT_DATAPATH_COMMON;

//
// Set of supported features.
//
uint32_t Features;

//
// The registration with WinSock Kernel.
//
WSK_REGISTRATION WskRegistration;
WSK_PROVIDER_NPI WskProviderNpi;
WSK_CLIENT_DATAGRAM_DISPATCH WskDispatch;

//
// The UDP callback function pointers.
//
// CXPLAT_UDP_DATAPATH_CALLBACKS UdpHandlers;

//
// The size of the buffer to allocate for client's receive context structure.
//
Expand All @@ -344,9 +310,7 @@ typedef struct CXPLAT_DATAPATH {
//
uint32_t ProcCount;

uint8_t UseTcp : 1; // TODO: set. always false?

CXPLAT_DATAPATH_RAW* RawDataPath; // TODO: set.
uint8_t UseTcp : 1; // Not supported. always false

//
// Per-processor completion contexts.
Expand Down

0 comments on commit 84593b2

Please sign in to comment.