Page MenuHomeFreeBSD

nd6: Do not enter net_epoch under nd6_prelist_add
AcceptedPublic

Authored by pouria on Sat, Mar 28, 8:01 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Mar 31, 3:13 AM
Unknown Object (File)
Mon, Mar 30, 7:38 PM
Unknown Object (File)
Mon, Mar 30, 1:11 PM

Details

Reviewers
markj
glebius
bz
zlei
Group Reviewers
network
Summary

nd6_prefix_onlink will enter net_epoch when necessary.
Also, exit net_epoch earlier in nd6_prefix_onlink,
Because we acquired a reference to ifa, and we got our ifa
from the pr->ndpr_ifp, we don't need to stay under epoch.
While here, style it.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 71777
Build 68660: arc lint + arc unit

Event Timeline

This revision is now accepted and ready to land.Sun, Mar 29, 7:07 AM

The commit title needs to be fixed though, "Don NOT" -> "Do not"

pouria retitled this revision from ndp: Don NOT enter net_epoch under nd6_prelist_add to ndp: Do not enter net_epoch under nd6_prelist_add.Sun, Mar 29, 11:00 AM
zlei added inline comments.
sys/netinet6/nd6_rtr.c
1420

This change looks good to me.

2168

I'd recommend against this.

A recursive NET_EPOCH_ENTER() has less performance impact vs a re-enter epoch.

CC @glebius for this change.

pouria retitled this revision from ndp: Do not enter net_epoch under nd6_prelist_add to nd6: Do not enter net_epoch under nd6_prelist_add.Wed, Apr 1, 4:52 PM
pouria added inline comments.
sys/netinet6/nd6_rtr.c
2168

Will wait for @glebius response