virtio_pci(4): Fix typo in read_ivar method
Prior to this revision, vtpci's BUS_READ_IVAR method on VIRTIO_IVAR_SUBVENDOR accidentally returned the PCI subdevice. The typo seems to have been introduced with the original commit adding VIRTIO_IVAR_{{SUB,}DEVICE,{SUB,}VENDOR} to virtio_pci. The commit log and code strongly suggest that the ivar was intended to return the subvendor rather than the subdevice; it was likely just a copy/paste mistake. Go ahead and rectify that.
This commit is contained in:
parent
13da854552
commit
5b32304d38
@ -408,7 +408,7 @@ vtpci_read_ivar(device_t dev, device_t child, int index, uintptr_t *result)
|
||||
*result = pci_get_device(dev);
|
||||
break;
|
||||
case VIRTIO_IVAR_SUBVENDOR:
|
||||
*result = pci_get_subdevice(dev);
|
||||
*result = pci_get_subvendor(dev);
|
||||
break;
|
||||
default:
|
||||
return (ENOENT);
|
||||
|
Loading…
x
Reference in New Issue
Block a user