The host selector is only required when the user likes to use the same
LPC device IDs as the physical LPC device. This is an uncommon use case.
For that reason, it makes no sense to exit when we don't find the host
selector.
Details
Details
- Reviewers
jhb markj - Group Reviewers
bhyve - Commits
- rG0d29d750b9a7: bhyve: do not exit if LPC finds no host selector
Diff Detail
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
usr.sbin/bhyve/pci_lpc.c | ||
---|---|---|
525 | That's true. Thanks. I need an invalid sel value. sel is only required if the user specifies host as LPC ID. So, if no LPC is found, it's not an error but sel should be set to an invalid value. If you have a better solution, feel free to post it. |
usr.sbin/bhyve/pci_lpc.c | ||
---|---|---|
525 | Can't you just pass NULL instead of &sel if we fail to find a matching LPC? That is: selp = &sel; if (pci_lpc_get_sel(selp) != 0) selp = NULL; vendor = pci_config_read_reg(selp, ...); ... |
usr.sbin/bhyve/pci_lpc.c | ||
---|---|---|
525 | Here's what I've done for the illumos port |