| Updated: October 28, 2024 |
Add a PCI device to a SMMU object, or remove it
#include <smmu.h>
int smmu_device_add_pci(struct smmu_object *const sop,
unsigned const pbus,
unsigned const pdev,
unsigned const pfunc);
For pbus, pdev, and pfunc, you can use the SMMU_PCI_FIELD_ANY constant for wildcarding.
If you use wildcarding for all bus, device and function combinations, smmu_device_add_pci() checks the buses, devices, and functions on the entire system, which may take a long time.
To avoid this, use wildcarding for only one or two of bus, device, function.
The smmu_device_add_pci() function is a convenience function. It calls smmu_device_add_generic() to add a Peripheral Component Interconnect (PCI) device to a SMMU object.
To remove a PCI device from SMMU objects, call this function with the sop argument set to NULL.
Failure: when attempting to: