Page MenuHomeFreeBSD

Eliminate misleading comments and dead code in lacp_port_create()
ClosedPublic

Authored by rpokala on Jan 23 2017, 8:19 AM.
Tags
None
Referenced Files
F122081962: D9302.diff
Wed, Jul 2, 2:50 AM
Unknown Object (File)
Sat, Jun 28, 3:10 AM
Unknown Object (File)
Wed, Jun 18, 1:49 AM
Unknown Object (File)
Tue, Jun 17, 11:25 PM
Unknown Object (File)
Thu, Jun 5, 1:56 PM
Unknown Object (File)
Tue, Jun 3, 2:35 AM
Unknown Object (File)
Jun 2 2025, 2:24 AM
Unknown Object (File)
May 15 2025, 2:06 PM
Subscribers

Details

Summary

Variables "fast" and "active" are both constant in lacp_port_create(), but
comments mispleadingly suggest that "fast" can be changed via ioctl. The
constant values control the value of "lp->lp_state", so it too is constant,
and the code for assigning different value to it is essentially dead.

Remove both "fast" and "active", and set "lp->lp_state" unconditionally;
that gets rid of the dead code and misleading comments.

CID: 1305692
CID: 1305734

Diff Detail

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

Event Timeline

rpokala retitled this revision from to Eliminate misleading comments and dead code in lacp_port_create().
rpokala updated this object.
rpokala edited the test plan for this revision. (Show Details)
rpokala added a reviewer: hiren.
rpokala added a subscriber: asomers.
hiren edited subscribers, added: hiren; removed: asomers.
asomers edited edge metadata.
This revision is now accepted and ready to land.Jan 23 2017, 3:36 PM

Thanks. I'm tinderboxing right now, will submit when that's done.

This revision was automatically updated to reflect the committed changes.