Page MenuHomeFreeBSD

iflib: don't update the admin status in if_media_status
Needs ReviewPublic

Authored by gallatin on Sat, Dec 6, 2:12 AM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Dec 30, 1:40 PM
Unknown Object (File)
Tue, Dec 30, 2:05 AM
Unknown Object (File)
Fri, Dec 19, 10:09 AM
Unknown Object (File)
Thu, Dec 18, 9:27 AM
Unknown Object (File)
Thu, Dec 18, 2:03 AM
Unknown Object (File)
Tue, Dec 16, 4:48 PM
Unknown Object (File)
Mon, Dec 15, 6:50 PM
Unknown Object (File)
Mon, Dec 15, 7:56 AM

Details

Reviewers
kbowling
markj
mjg
glebius
shurd
Group Reviewers
iflib
Summary

When _task_fn_admin() is active, it will regularly call IFDI_UPDATE_ADMIN_STATUS(). So there is no need to do it in iflib_media_status. This can be fairly expensive on some drivers (long DELAY bussywait loops waiting for a NIC command), and there is no need to pause a userspace app in this DELAY() if it is happening asynchronously anyway.

Note the logic to detect if _task_fn_admin() is regularly calling IFDI_UPDATE_ADMIN_STATUS() was copied from that function.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped