Page MenuHomeFreeBSD

MFC r270212,r270332 (pci(4) MSI-X enable/disable methods from head)
ClosedPublic

Authored by ngie on Dec 29 2015, 6:28 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Jun 23, 11:18 PM
Unknown Object (File)
Jan 24 2024, 11:19 PM
Unknown Object (File)
Dec 20 2023, 12:49 AM
Unknown Object (File)
Dec 16 2023, 9:26 AM
Unknown Object (File)
Dec 16 2023, 9:25 AM
Unknown Object (File)
Sep 25 2023, 3:46 PM
Unknown Object (File)
Aug 3 2023, 2:36 AM
Unknown Object (File)
Jul 16 2023, 6:48 AM

Details

Summary

MFC r270212,r270332 (pci(4) MSI-X enable/disable methods from head)

Rationale for the MFC:

This is needed to diff reduce with head and make bringing in code needed for
libnv/nv(9) possible with less conflicts, so ixgbe(4) can be MFCed (see
https://reviews.freebsd.org/D4249)

The sponsored by/differential revision/reviewed by lines have been omitted,
but will be included in the MFC commit message.

MFC r270212,r270332:

r270212 (by royger):

pci: make MSI(-X) enable and disable methods of the PCI bus

Make the functions pci_disable_msi, pci_enable_msi and pci_enable_msix
methods of the newbus PCI bus. This code should not include any
functional change.

dev/pci/pci.c:

  • Convert the mentioned functions to newbus methods.
  • Fix the callers of the converted functions.

sys/dev/pci/pci_private.h:
dev/pci/pci_if.m:

  • Declare the new methods.

dev/pci/pcivar.h:

  • Add helpers to call the newbus methods.

ofed/include/linux/pci.h:

  • Add define to prevent the ofed version of pci_enable_msix from clashing with the FreeBSD native version.

r270332 (by royger):

pci: add a new pci_child_added newbus method.

This is needed so when running under Xen the calls to pci_child_added
can be intercepted and a custom Xen method can be used to register
those devices with Xen. This should not include any functional
change, since the Xen implementation will be added in a following
patch and the native implementation is a noop.

dev/pci/pci.c:
dev/pci/pci_if.m:
dev/pci/pci_private.h:
dev/pci/pcivar.h:

  • Add the pci_child_added newbus method.
Test Plan
  • I have booted with my VM several times with this change without issues.
  • Going to rebuild and boot the kernel on my Haswell machine

Diff Detail

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

Event Timeline

ngie retitled this revision from to MFC r270212,r270332 (pci(4) enable/disable methods from head).
ngie updated this object.
ngie edited the test plan for this revision. (Show Details)
ngie added a reviewer: royger.
ngie added subscribers: erj, sbruno, rstone and 2 others.
ngie retitled this revision from MFC r270212,r270332 (pci(4) enable/disable methods from head) to MFC r270212,r270332 (pci(4) MSI-X enable/disable methods from head).Dec 29 2015, 6:29 PM
ngie updated this object.
ngie added a subscriber: hselasky.
hselasky added a reviewer: hselasky.

sys/ofed bits look OK.

This revision is now accepted and ready to land.Dec 29 2015, 7:18 PM
royger edited edge metadata.

LGTM