-
Notifications
You must be signed in to change notification settings - Fork 20
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add initial PCI support #238
Conversation
Signed-off-by: Connor Davis <[email protected]>
572bfe7
to
2c52337
Compare
de68ca8
to
f42d113
Compare
FYI I was going to add support for mapping BARs as a follow on commit, but wanted to get early feedback before starting that. In case you wanted to keep the issue open until the BAR mapping stuff is in |
269c2f8
to
94acba2
Compare
Nah no need to delay, let's get this PR in. |
Add probe_pci, probe_pci_bus, probe_pci_dev and init_pci functions. init_pci is called from kernel_start to setup the PCI subsystem. In turn, init_pci calls probe_pci, which initializes the host bridge and then recursively enumerates the rest of the PCI devices on the system by calling probe_pci_bus/probe_pci_dev. Each device's basic config space is stored in the pcidev_t structure, along with a pointer to the device's parent bridge and a list_head_t node. When a device is found, it is added to the global pci_list structure for later reference. Signed-off-by: Connor Davis <[email protected]>
should be good to go now |
The first patch of this series fixes a small typo. The second adds code for enumerating PCI devices