Page MenuHomeFreeBSD

Fix probe priority for PCI busses
ClosedPublic

Authored by marcel on Jun 1 2015, 4:19 AM.
Tags
None
Referenced Files
Unknown Object (File)
Sat, Jan 24, 8:48 PM
Unknown Object (File)
Sat, Jan 24, 4:45 PM
Unknown Object (File)
Mon, Jan 19, 9:22 PM
Unknown Object (File)
Nov 4 2025, 4:13 PM
Unknown Object (File)
Nov 4 2025, 4:13 PM
Unknown Object (File)
Nov 4 2025, 4:13 PM
Unknown Object (File)
Nov 4 2025, 1:47 PM
Unknown Object (File)
Oct 6 2025, 10:08 AM
Subscribers

Details

Summary

The proto(4) driver attaches to any PCI device that has a type 1 header. As such, its probe function returns a priority of "hoover". It only attaches when no other driver exists. Unfortunately, when the proto(4) driver is compiled into the kernel, the entire system become useless, because the PCI bridge drivers do not follow the standard priority scheme. Instead they return a hardcoded -10000. Since this is effectively yielding a lower priority than "hoover", the photo(4) driver gets to be attached instead of the bridge drivers.

There doesn't seem to be a good reason for why -10000 (or any priority lower than "hoover") would make sense in how the priority scheme has been designed.

Test Plan

With proto(4) compiled into the kernel (or preloaded):

  • proto(4) attaches before the change.
  • bridge drivers attach after this change.

Diff Detail

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

Event Timeline

marcel retitled this revision from to Fix probe priority for PCI busses.
marcel updated this object.
marcel edited the test plan for this revision. (Show Details)
marcel added a reviewer: jhb.
marcel set the repository for this revision to rS FreeBSD src repository - subversion.