Skip to content
Commit d9ef2e7b authored by Ihar Hrachyshka's avatar Ihar Hrachyshka Committed by David S. Miller
Browse files

arp: postpone addr_type calculation to as late as possible

The addr_type retrieval can be costly, so it's worth trying to avoid its
calculation as much as possible. This patch makes it calculated only
for gratuitous ARP packets. This is especially important since later we
may want to move is_garp calculation outside of arp_accept block, at
which point the costly operation will be executed for all setups.

The patch is the result of a discussion in net-dev:
http://marc.info/?l=linux-netdev&m=149506354216994



Suggested-by: default avatarJulian Anastasov <ja@ssi.bg>
Signed-off-by: default avatarIhar Hrachyshka <ihrachys@redhat.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 6fd05633
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment