]> git.baikalelectronics.ru Git - kernel.git/commit
mptcp: unify ADD_ADDR and echo suboptions writing
authorGeliang Tang <geliangtang@gmail.com>
Wed, 9 Dec 2020 23:51:18 +0000 (15:51 -0800)
committerDavid S. Miller <davem@davemloft.net>
Thu, 10 Dec 2020 03:02:15 +0000 (19:02 -0800)
commitc4da34fab4e37e7af7093d90277cad953fd944f8
tree8689e4da35064c05e70fe8e14c6da5fd03f1faad
parent22ca52c40c145eedefcb2eb51720b5e13b7bf57c
mptcp: unify ADD_ADDR and echo suboptions writing

There are two differences between ADD_ADDR suboption and ADD_ADDR echo
suboption: The length of the former is 8 octets longer than the length
of the latter. The former's echo-flag is 0, and latter's echo-flag is 1.

This patch added two local variables, len and echo, to unify ADD_ADDR
and ADD_ADDR echo suboptions writing.

Signed-off-by: Geliang Tang <geliangtang@gmail.com>
Signed-off-by: Mat Martineau <mathew.j.martineau@linux.intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/mptcp/options.c