Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F109421907
D39311.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D39311.diff
View Options
diff --git a/usr.sbin/bhyve/pci_lpc.c b/usr.sbin/bhyve/pci_lpc.c
--- a/usr.sbin/bhyve/pci_lpc.c
+++ b/usr.sbin/bhyve/pci_lpc.c
@@ -480,6 +480,8 @@
}
}
+ warnx("%s: Unable to find host selector of LPC bridge.", __func__);
+
return (-1);
}
@@ -487,6 +489,7 @@
pci_lpc_init(struct pci_devinst *pi, nvlist_t *nvl)
{
struct pcisel sel = { 0 };
+ struct pcisel *selp = NULL;
uint16_t device, subdevice, subvendor, vendor;
uint8_t revid;
@@ -511,15 +514,15 @@
if (lpc_init(pi->pi_vmctx) != 0)
return (-1);
- if (pci_lpc_get_sel(&sel) != 0)
- return (-1);
+ if (pci_lpc_get_sel(&sel) == 0)
+ selp = &sel;
- vendor = pci_config_read_reg(&sel, nvl, PCIR_VENDOR, 2, LPC_VENDOR);
- device = pci_config_read_reg(&sel, nvl, PCIR_DEVICE, 2, LPC_DEV);
- revid = pci_config_read_reg(&sel, nvl, PCIR_REVID, 1, LPC_REVID);
- subvendor = pci_config_read_reg(&sel, nvl, PCIR_SUBVEND_0, 2,
+ vendor = pci_config_read_reg(selp, nvl, PCIR_VENDOR, 2, LPC_VENDOR);
+ device = pci_config_read_reg(selp, nvl, PCIR_DEVICE, 2, LPC_DEV);
+ revid = pci_config_read_reg(selp, nvl, PCIR_REVID, 1, LPC_REVID);
+ subvendor = pci_config_read_reg(selp, nvl, PCIR_SUBVEND_0, 2,
LPC_SUBVEND_0);
- subdevice = pci_config_read_reg(&sel, nvl, PCIR_SUBDEV_0, 2,
+ subdevice = pci_config_read_reg(selp, nvl, PCIR_SUBDEV_0, 2,
LPC_SUBDEV_0);
/* initialize config space */
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Feb 5, 8:49 PM (20 h, 38 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
16480612
Default Alt Text
D39311.diff (1 KB)
Attached To
Mode
D39311: bhyve: do not exit if LPC finds no host selector
Attached
Detach File
Event Timeline
Log In to Comment