Page MenuHomeFreeBSD

Split arpresolve() into fast/slow path.
ClosedPublic

Authored by melifaro on Aug 14 2015, 5:31 PM.
Tags
None
Referenced Files
F151332763: D3383.id7949.diff
Tue, Apr 7, 4:15 PM
Unknown Object (File)
Mon, Apr 6, 4:28 PM
Unknown Object (File)
Sat, Apr 4, 9:02 AM
Unknown Object (File)
Fri, Apr 3, 10:14 PM
Unknown Object (File)
Mon, Mar 30, 7:56 AM
Unknown Object (File)
Wed, Mar 25, 5:47 AM
Unknown Object (File)
Tue, Mar 24, 9:14 AM
Unknown Object (File)
Tue, Mar 24, 2:40 AM
Subscribers

Details

Summary

This change isolates the most common case (e.g. successful lookup)
from more complicates scenarios. It also (tries to) make code
more simple by avoiding retry: cycle.

The actual goal is to prepare code to the upcoming change that will
allow LL address retrieval without acquiring LLE lock at all.

Side effects:
Most of the change is just loop unrolling (e.g. splitting first iteration
from second one). However, in cases when we don't have LLE at all
we will do 2 LLE lookups instead of one. Since this situation should be rare
and in general lookups are fast I don't think there is a problem here.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 116
Build 116: arc lint + arc unit

Event Timeline

melifaro retitled this revision from to Split arpresolve() into fast/slow path..
melifaro updated this object.
melifaro edited the test plan for this revision. (Show Details)
melifaro added a reviewer: network.
ae added a reviewer: ae.
ae added a subscriber: ae.

I guess this isn't the last change and you will refactor this code in future. But in case of two lookups, you just can add some flag argument to arpresolve_full and don't do second lookup.

sys/netinet/if_ether.c
348

You forgot to fix function name

This revision is now accepted and ready to land.Aug 16 2015, 9:29 AM
melifaro edited edge metadata.

Aboid second lookup in case of non-existing lle.

This revision now requires review to proceed.Aug 16 2015, 12:12 PM
ae edited edge metadata.
This revision is now accepted and ready to land.Aug 16 2015, 12:16 PM
This revision was automatically updated to reflect the committed changes.