Page MenuHomeFreeBSD

Switch to linker sets to find the xport callback object.
ClosedPublic

Authored by imp on Jul 22 2016, 8:09 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Jan 21, 8:52 PM
Unknown Object (File)
Jan 16 2025, 9:32 AM
Unknown Object (File)
Jan 15 2025, 4:41 PM
Unknown Object (File)
Jan 8 2025, 7:43 PM
Unknown Object (File)
Dec 31 2024, 4:04 AM
Unknown Object (File)
Nov 25 2024, 5:08 AM
Unknown Object (File)
Nov 23 2024, 3:12 AM
Unknown Object (File)
Nov 19 2024, 1:18 PM
Subscribers

Details

Summary

Switch to linker sets to find the xport callback object. This
eliminates the need to special case everything in cam_xpt for new
transports. It is now a failure to not have a transport object when
registering the bus as well.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

imp retitled this revision from to Switch to linker sets to find the xport callback object..
imp updated this object.
imp edited the test plan for this revision. (Show Details)
  • Switch to linker sets to find the xport callback object. This
  • Include NVMe transport and direct access devices on amd64.
  • Switch to linker sets to find the protocol callback object.
chuck_tuffli.net added inline comments.
sys/cam/cam_xpt.c
3915 ↗(On Diff #18685)

Won't this behave differently compared to the original? Should this be

new_bus->xport = &xport_default;

?

sys/cam/cam_xpt.c
3915 ↗(On Diff #18685)

That assignment was never needed, since it was redundant after line 3889 (new file numbering). It also underscores that fact that you're no longer allowed to create a transport of an unknown / unspecified type.

sys/cam/cam_xpt.c
3915 ↗(On Diff #18685)

Ah, I figured there was a good reason, but wanted to ask.

scottl edited edge metadata.
This revision is now accepted and ready to land.Jul 25 2016, 4:41 PM
This revision was automatically updated to reflect the committed changes.