1
0
mirror of https://git.FreeBSD.org/src.git synced 2025-01-26 16:18:31 +00:00

Add PNP info to PCI attachment of ena driver

Make unsigned values uint16_t for pnp table. They are properly
uint16_t befause they are 16-bit PCI IDs. The PNP_INFO language has no
type for bare unsigned.

Reviewed by: imp, chuck
Submitted by: Lakhan Shiva Kamireddy <lakhanshiva@gmail.com>
Sponsored by: Google, Inc. (GSoC 2018)
Pull Request: https://github.com/bsdimp/freebsd/pull/5
This commit is contained in:
Warner Losh 2018-07-08 20:39:38 +00:00
parent 63c017dae5
commit 40abe76bf0
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=336099
2 changed files with 4 additions and 2 deletions

View File

@ -3947,6 +3947,8 @@ static driver_t ena_driver = {
devclass_t ena_devclass;
DRIVER_MODULE(ena, pci, ena_driver, ena_devclass, 0, 0);
MODULE_PNP_INFO("U16:vendor; U16:device", pci, ena, ena_vendor_info_array,
sizeof(ena_vendor_info_array[0]), nitems(ena_vendor_info_array) - 1);
MODULE_DEPEND(ena, pci, 1, 1, 1);
MODULE_DEPEND(ena, ether, 1, 1, 1);

View File

@ -151,8 +151,8 @@ struct msix_entry {
};
typedef struct _ena_vendor_info_t {
unsigned int vendor_id;
unsigned int device_id;
uint16_t vendor_id;
uint16_t device_id;
unsigned int index;
} ena_vendor_info_t;