sctp: add SCTP_PR_SUPPORTED on sctp sockopt
According to section 4.5 of rfc7496, prsctp_enable should be per asoc. We will add prsctp_enable to both asoc and ep, and replace the places where it used net.sctp->prsctp_enable with asoc->prsctp_enable. ep->prsctp_enable will be initialized with net.sctp->prsctp_enable, and asoc->prsctp_enable will be initialized with ep->prsctp_enable. We can also modify it's value through sockopt SCTP_PR_SUPPORTED. Signed-off-by: Xin Long <lucien.xin@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
bac65c4b39
commit
28aa4c26fc
@@ -1256,7 +1256,8 @@ struct sctp_endpoint {
|
||||
/* SCTP-AUTH: endpoint shared keys */
|
||||
struct list_head endpoint_shared_keys;
|
||||
__u16 active_key_id;
|
||||
__u8 auth_enable;
|
||||
__u8 auth_enable:1,
|
||||
prsctp_enable:1;
|
||||
};
|
||||
|
||||
/* Recover the outter endpoint structure. */
|
||||
@@ -1848,7 +1849,8 @@ struct sctp_association {
|
||||
__u16 active_key_id;
|
||||
|
||||
__u8 need_ecne:1, /* Need to send an ECNE Chunk? */
|
||||
temp:1; /* Is it a temporary association? */
|
||||
temp:1, /* Is it a temporary association? */
|
||||
prsctp_enable:1;
|
||||
|
||||
struct sctp_priv_assoc_stats stats;
|
||||
};
|
||||
|
Reference in New Issue
Block a user