]> git.baikalelectronics.ru Git - kernel.git/commit
sctp: do not update transport pathmtu if SPP_PMTUD_ENABLE is not set
authorXin Long <lucien.xin@gmail.com>
Wed, 21 Jul 2021 18:45:54 +0000 (14:45 -0400)
committerDavid S. Miller <davem@davemloft.net>
Wed, 21 Jul 2021 21:17:58 +0000 (14:17 -0700)
commit4b9f23250fa58f3a711e6dc5b41c3a5340ab7eb8
treecf16b67c5599314cd1873615f56815475ca457cf
parentf9f94b306a2982ffc654f6e113a2573454db468a
sctp: do not update transport pathmtu if SPP_PMTUD_ENABLE is not set

Currently, in sctp_packet_config(), sctp_transport_pmtu_check() is
called to update transport pathmtu with dst's mtu when dst's mtu
has been changed by non sctp stack like xfrm.

However, this should only happen when SPP_PMTUD_ENABLE is set, no
matter where dst's mtu changed. This patch is to fix by checking
SPP_PMTUD_ENABLE flag before calling sctp_transport_pmtu_check().

Thanks Jacek for reporting and looking into this issue.

v1->v2:
  - add the missing "{" to fix the build error.

Fixes: 104574141336 ('Revert "sctp: remove sctp_transport_pmtu_check"')
Reported-by: Jacek Szafraniec <jacek.szafraniec@nokia.com>
Tested-by: Jacek Szafraniec <jacek.szafraniec@nokia.com>
Signed-off-by: Xin Long <lucien.xin@gmail.com>
Acked-by: Marcelo Ricardo Leitner <marcelo.leitner@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/sctp/output.c