History

sctp: add SCTP_PR_ASSOC_STATUS on sctp sockopt

This patch adds SCTP_PR_ASSOC_STATUS to sctp sockopt, which is used to dump the prsctp statistics info from the asoc. The prsctp statistics includes abandoned_sent/unsent from the asoc. abandoned_sent is the count of the packets we drop packets from retransmit/transmited queue, and abandoned_unsent is the count of the packets we drop from out_queue according to the policy. Note: another option for prsctp statistics dump described in rfc is SCTP_PR_STREAM_STATUS, which is used to dump the prsctp statistics info from each stream. But by now, linux doesn't yet have per stream statistics info, it needs rfc6525 to be implemented. As the prsctp statistics for each stream has to be based on per stream statistics, we will delay it until rfc6525 is done in linux.

Xin Long committed 10 years ago

Commit 826d2531 parent f959fb43 files · +77 −0Browse files

Showing the changes to include/uapi/linux (1 of 3 files). Show all

Unified · Split

include/uapi/linux/sctp.h+12−0
@@ -114,6 +114,7 @@ typedef __s32 sctp_assoc_t; · 113 unmodified lines
114114 #define SCTP_GET_ASSOC_STATS 112 /* Read only */
115115 #define SCTP_PR_SUPPORTED 113
116116 #define SCTP_DEFAULT_PRINFO 114
117+#define SCTP_PR_ASSOC_STATUS 115
117118
118119 /* PR-SCTP policies */
119120 #define SCTP_PR_SCTP_NONE 0x0000
@@ -926,6 +927,17 @@ struct sctp_paddrthlds { · 806 unmodified lines
926927 __u16 spt_pathpfthld;
927928 };
928929
930+/*
931+ * Socket Option for Getting the Association/Stream-Specific PR-SCTP Status
932+ */
933+struct sctp_prstatus {
934+ sctp_assoc_t sprstat_assoc_id;
935+ __u16 sprstat_sid;
936+ __u16 sprstat_policy;
937+ __u64 sprstat_abandoned_unsent;
938+ __u64 sprstat_abandoned_sent;
939+};
940+
929941 struct sctp_default_prinfo {
930942 sctp_assoc_t pr_assoc_id;
931943 __u32 pr_value;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t