Enable kernel space pci_find_device()

This commit is contained in:
Sebastian Huber 2023-04-05 14:27:27 +02:00 committed by Christian Mauderer
parent e9acd95722
commit 42add0b7f1
3 changed files with 2 additions and 2 deletions

View File

@ -471,7 +471,6 @@ pci_find_dbsf(uint32_t domain, uint8_t bus, uint8_t slot, uint8_t func)
return (NULL);
}
#ifndef __rtems__
/* Find a device_t by vendor/device ID */
device_t
@ -488,7 +487,6 @@ pci_find_device(uint16_t vendor, uint16_t device)
return (NULL);
}
#endif /* __rtems__ */
device_t
pci_find_class(uint8_t class, uint8_t subclass)

View File

@ -3847,6 +3847,7 @@
#define pci_find_cap_method _bsd_pci_find_cap_method
#define pci_find_class _bsd_pci_find_class
#define pci_find_dbsf _bsd_pci_find_dbsf
#define pci_find_device _bsd_pci_find_device
#define pci_find_extcap_method _bsd_pci_find_extcap_method
#define pci_find_htcap_method _bsd_pci_find_htcap_method
#define pci_find_next_cap_method _bsd_pci_find_next_cap_method

View File

@ -52,6 +52,7 @@ __FBSDID("$FreeBSD$");
#include <machine/resource.h>
#include <rtems/bsd/local/pcib_if.h>
#undef pci_find_device
#define pci_find_device rtems_pci_find_device
#if HAVE_RTEMS_PCI_H
#include <rtems/pci.h>