Author: cem Date: Sat May 25 01:59:24 2019 New Revision: 348262 URL: https://svnweb.freebsd.org/changeset/base/348262
Log: 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. Modified: head/sys/dev/virtio/pci/virtio_pci.c Modified: head/sys/dev/virtio/pci/virtio_pci.c ============================================================================== --- head/sys/dev/virtio/pci/virtio_pci.c Sat May 25 01:58:00 2019 (r348261) +++ head/sys/dev/virtio/pci/virtio_pci.c Sat May 25 01:59:24 2019 (r348262) @@ -408,7 +408,7 @@ vtpci_read_ivar(device_t dev, device_t child, int inde *result = pci_get_device(dev); break; case VIRTIO_IVAR_SUBVENDOR: - *result = pci_get_subdevice(dev); + *result = pci_get_subvendor(dev); break; default: return (ENOENT); _______________________________________________ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"