iPXE
Data Fields
tcp_connection Struct Reference

A TCP connection. More...

Data Fields

struct refcnt refcnt
 Reference counter. More...
 
struct list_head list
 List of TCP connections. More...
 
unsigned int flags
 Flags. More...
 
struct interface xfer
 Data transfer interface. More...
 
struct sockaddr_tcpip peer
 Remote socket address. More...
 
unsigned int local_port
 Local port. More...
 
size_t mss
 Maximum segment size. More...
 
unsigned int tcp_state
 Current TCP state. More...
 
unsigned int prev_tcp_state
 Previous TCP state. More...
 
uint32_t snd_seq
 Current sequence number. More...
 
uint32_t snd_sent
 Unacknowledged sequence count. More...
 
uint32_t snd_win
 Send window. More...
 
uint32_t rcv_ack
 Current acknowledgement number. More...
 
uint32_t rcv_win
 Receive window. More...
 
uint32_t ts_val
 Received timestamp value. More...
 
uint32_t ts_recent
 Most recent received timestamp that advanced the window. More...
 
uint8_t snd_win_scale
 Send window scale. More...
 
uint8_t rcv_win_scale
 Receive window scale. More...
 
struct tcp_sack_block sack [TCP_SACK_MAX]
 Selective acknowledgement list (in host-endian order) More...
 
struct list_head tx_queue
 Transmit queue. More...
 
struct list_head rx_queue
 Receive queue. More...
 
struct process process
 Transmission process. More...
 
struct retry_timer timer
 Retransmission timer. More...
 
struct retry_timer keepalive
 Keepalive timer. More...
 
struct retry_timer wait
 Shutdown (TIME_WAIT) timer. More...
 
struct pending_operation pending_flags
 Pending operations for SYN and FIN. More...
 
struct pending_operation pending_data
 Pending operations for transmit queue. More...
 

Detailed Description

A TCP connection.

Definition at line 33 of file tcp.c.

Field Documentation

◆ refcnt

struct refcnt tcp_connection::refcnt

Reference counter.

Definition at line 35 of file tcp.c.

Referenced by tcp_close(), and tcp_open().

◆ list

struct list_head tcp_connection::list

List of TCP connections.

Definition at line 37 of file tcp.c.

Referenced by tcp_close(), tcp_demux(), tcp_first_unclosed(), tcp_first_unfinished(), tcp_open(), and tcp_shutdown().

◆ flags

unsigned int tcp_connection::flags

◆ xfer

struct interface tcp_connection::xfer

Data transfer interface.

Definition at line 43 of file tcp.c.

Referenced by tcp_close(), tcp_open(), tcp_rx(), tcp_rx_data(), and tcp_xmit_sack().

◆ peer

struct sockaddr_tcpip tcp_connection::peer

Remote socket address.

Definition at line 46 of file tcp.c.

Referenced by tcp_open(), and tcp_xmit_sack().

◆ local_port

unsigned int tcp_connection::local_port

Local port.

Definition at line 48 of file tcp.c.

Referenced by tcp_demux(), tcp_open(), and tcp_xmit_sack().

◆ mss

size_t tcp_connection::mss

Maximum segment size.

Definition at line 50 of file tcp.c.

Referenced by tcp_open(), and tcp_xmit_sack().

◆ tcp_state

unsigned int tcp_connection::tcp_state

◆ prev_tcp_state

unsigned int tcp_connection::prev_tcp_state

Previous TCP state.

Maintained only for debug messages

Definition at line 58 of file tcp.c.

Referenced by tcp_dump_state(), and tcp_open().

◆ snd_seq

uint32_t tcp_connection::snd_seq

Current sequence number.

Equivalent to SND.UNA in RFC 793 terminology.

Definition at line 63 of file tcp.c.

Referenced by tcp_close(), tcp_expired(), tcp_open(), tcp_rx_ack(), tcp_wait_expired(), and tcp_xmit_sack().

◆ snd_sent

uint32_t tcp_connection::snd_sent

Unacknowledged sequence count.

Equivalent to (SND.NXT-SND.UNA) in RFC 793 terminology.

Definition at line 68 of file tcp.c.

Referenced by tcp_expired(), tcp_rx_ack(), tcp_wait_expired(), and tcp_xmit_sack().

◆ snd_win

uint32_t tcp_connection::snd_win

Send window.

Equivalent to SND.WND in RFC 793 terminology

Definition at line 73 of file tcp.c.

Referenced by tcp_rx_ack(), and tcp_xmit_win().

◆ rcv_ack

uint32_t tcp_connection::rcv_ack

Current acknowledgement number.

Equivalent to RCV.NXT in RFC 793 terminology.

Definition at line 78 of file tcp.c.

Referenced by tcp_expired(), tcp_process_rx_queue(), tcp_rx(), tcp_rx_data(), tcp_rx_enqueue(), tcp_rx_fin(), tcp_rx_rst(), tcp_rx_seq(), tcp_rx_syn(), tcp_sack_block(), tcp_wait_expired(), tcp_xmit(), and tcp_xmit_sack().

◆ rcv_win

uint32_t tcp_connection::rcv_win

Receive window.

Equivalent to RCV.WND in RFC 793 terminology.

Definition at line 83 of file tcp.c.

Referenced by tcp_rx_enqueue(), tcp_rx_rst(), tcp_rx_seq(), and tcp_xmit_sack().

◆ ts_val

uint32_t tcp_connection::ts_val

Received timestamp value.

Updated when a packet is received; copied to ts_recent when the window is advanced.

Definition at line 89 of file tcp.c.

Referenced by tcp_rx(), and tcp_rx_seq().

◆ ts_recent

uint32_t tcp_connection::ts_recent

Most recent received timestamp that advanced the window.

Equivalent to TS.Recent in RFC 1323 terminology.

Definition at line 94 of file tcp.c.

Referenced by tcp_rx_seq(), and tcp_xmit_sack().

◆ snd_win_scale

uint8_t tcp_connection::snd_win_scale

Send window scale.

Equivalent to Snd.Wind.Scale in RFC 1323 terminology

Definition at line 99 of file tcp.c.

Referenced by tcp_rx(), and tcp_rx_syn().

◆ rcv_win_scale

uint8_t tcp_connection::rcv_win_scale

Receive window scale.

Equivalent to Rcv.Wind.Scale in RFC 1323 terminology

Definition at line 104 of file tcp.c.

Referenced by tcp_rx_syn(), and tcp_xmit_sack().

◆ sack

struct tcp_sack_block tcp_connection::sack[TCP_SACK_MAX]

Selective acknowledgement list (in host-endian order)

Definition at line 107 of file tcp.c.

Referenced by tcp_rx_seq(), tcp_sack(), and tcp_xmit_sack().

◆ tx_queue

struct list_head tcp_connection::tx_queue

Transmit queue.

Definition at line 110 of file tcp.c.

Referenced by tcp_close(), tcp_open(), tcp_process_tx_queue(), tcp_rx_ack(), tcp_xfer_deliver(), and tcp_xfer_window().

◆ rx_queue

struct list_head tcp_connection::rx_queue

Receive queue.

Definition at line 112 of file tcp.c.

Referenced by tcp_close(), tcp_discard(), tcp_open(), tcp_process_rx_queue(), tcp_rx(), tcp_rx_enqueue(), tcp_sack_block(), and tcp_xmit_sack().

◆ process

struct process tcp_connection::process

Transmission process.

Definition at line 114 of file tcp.c.

Referenced by tcp_close(), tcp_first_unfinished(), tcp_open(), and tcp_rx().

◆ timer

struct retry_timer tcp_connection::timer

Retransmission timer.

Definition at line 116 of file tcp.c.

Referenced by tcp_close(), tcp_open(), tcp_rx_ack(), and tcp_xmit_sack().

◆ keepalive

struct retry_timer tcp_connection::keepalive

Keepalive timer.

Definition at line 118 of file tcp.c.

Referenced by tcp_close(), tcp_keepalive_expired(), tcp_open(), and tcp_rx_ack().

◆ wait

struct retry_timer tcp_connection::wait

Shutdown (TIME_WAIT) timer.

Definition at line 120 of file tcp.c.

Referenced by tcp_close(), tcp_open(), tcp_rx(), and tcp_wait_expired().

◆ pending_flags

struct pending_operation tcp_connection::pending_flags

Pending operations for SYN and FIN.

Definition at line 123 of file tcp.c.

Referenced by tcp_close(), tcp_open(), and tcp_rx_ack().

◆ pending_data

struct pending_operation tcp_connection::pending_data

Pending operations for transmit queue.

Definition at line 125 of file tcp.c.

Referenced by tcp_close(), tcp_process_tx_queue(), and tcp_xfer_deliver().


The documentation for this struct was generated from the following file: