]> git.baikalelectronics.ru Git - kernel.git/commit
sctp: remove useless code from sctp_apply_peer_addr_params
authorMarcelo Ricardo Leitner <marcelo.leitner@gmail.com>
Fri, 13 Jan 2017 20:31:15 +0000 (18:31 -0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 16 Jan 2017 18:51:40 +0000 (13:51 -0500)
commitb600301909660302e37f1eb7a6bb147bad8fc2c9
tree787cb59a24cddd1b38a42f7e1122e0ec7f979fc3
parent8d1b85486c81cde0a45fa2830fe82d566927733e
sctp: remove useless code from sctp_apply_peer_addr_params

sctp_frag_point() doesn't store anything, and thus just calling it
cannot do anything useful.

sctp_apply_peer_addr_params is only called by
sctp_setsockopt_peer_addr_params. When operating on an asoc,
sctp_setsockopt_peer_addr_params will call sctp_apply_peer_addr_params
once for the asoc, and then once for each transport this asoc has,
meaning that the frag_point will be recomputed when updating the
transports and calling it when updating the asoc is not necessary.
IOW, no action is needed here and we can remove this call.

Signed-off-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
Acked-by: Neil Horman <nhorman@tuxdriver.com>
Reviewed-by: Xin Long <lucien.xin@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sctp/socket.c