mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-24 13:00:54 +07:00
sctp: not traverse asoc trans list if non-ipv6 trans exists for ipv6_flowlabel
When users set params.spp_address and get a trans, ipv6_flowlabel flag
should be applied into this trans. But even if this one is not an ipv6
trans, it should not go to apply it into all other transes of the asoc
but simply ignore it.
Fixes: 0b0dce7a36
("sctp: add spp_ipv6_flowlabel and spp_dscp for sctp_paddrparams")
Signed-off-by: Xin Long <lucien.xin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
af8a2b8ba7
commit
741880e1f2
@ -2658,10 +2658,12 @@ static int sctp_apply_peer_addr_params(struct sctp_paddrparams *params,
|
||||
}
|
||||
|
||||
if (params->spp_flags & SPP_IPV6_FLOWLABEL) {
|
||||
if (trans && trans->ipaddr.sa.sa_family == AF_INET6) {
|
||||
trans->flowlabel = params->spp_ipv6_flowlabel &
|
||||
SCTP_FLOWLABEL_VAL_MASK;
|
||||
trans->flowlabel |= SCTP_FLOWLABEL_SET_MASK;
|
||||
if (trans) {
|
||||
if (trans->ipaddr.sa.sa_family == AF_INET6) {
|
||||
trans->flowlabel = params->spp_ipv6_flowlabel &
|
||||
SCTP_FLOWLABEL_VAL_MASK;
|
||||
trans->flowlabel |= SCTP_FLOWLABEL_SET_MASK;
|
||||
}
|
||||
} else if (asoc) {
|
||||
struct sctp_transport *t;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user