]> git.baikalelectronics.ru Git - kernel.git/commit
net: ipv4: Move ip_options_fragment() out of loop
authorYajun Deng <yajun.deng@linux.dev>
Mon, 23 Aug 2021 03:17:59 +0000 (11:17 +0800)
committerDavid S. Miller <davem@davemloft.net>
Tue, 24 Aug 2021 08:24:18 +0000 (09:24 +0100)
commitfd1d4ca91b23b638789099ab418630bd44e56808
treeed998403ce6e3908ee8f94a7a301cc161feff285
parent8bba5dd20905a8ee3e869016abc54f759b7fd11e
net: ipv4: Move ip_options_fragment() out of loop

The ip_options_fragment() only called when iter->offset is equal to zero,
so move it out of loop, and inline 'Copy the flags to each fragment.'
As also, remove the unused parameter in ip_frag_ipcb().

Signed-off-by: Yajun Deng <yajun.deng@linux.dev>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/ipv4/ip_output.c