Lines Matching refs:dev
469 virtio_blk_init(struct vmctx *ctx, struct pci_vdev *dev, char *opts) in virtio_blk_init() argument
505 dev->slot, dev->func) >= sizeof(bident)) { in virtio_blk_init()
659 virtio_linkup(&blk->base, &(blk->ops), blk, dev, blk->vqs, BACKEND_VBSU); in virtio_blk_init()
702 pci_set_cfgdata16(dev, PCIR_DEVICE, VIRTIO_DEV_BLOCK); in virtio_blk_init()
703 pci_set_cfgdata16(dev, PCIR_VENDOR, VIRTIO_VENDOR); in virtio_blk_init()
704 pci_set_cfgdata8(dev, PCIR_CLASS, PCIC_STORAGE); in virtio_blk_init()
705 pci_set_cfgdata16(dev, PCIR_SUBDEV_0, VIRTIO_TYPE_BLOCK); in virtio_blk_init()
707 pci_set_cfgdata16(dev, PCIR_SUBVEND_0, ORACLE_VENDOR_ID); in virtio_blk_init()
709 pci_set_cfgdata16(dev, PCIR_SUBVEND_0, VIRTIO_VENDOR); in virtio_blk_init()
735 virtio_blk_deinit(struct vmctx *ctx, struct pci_vdev *dev, char *opts) in virtio_blk_deinit() argument
740 if (dev->arg) { in virtio_blk_deinit()
742 blk = (struct virtio_blk *) dev->arg; in virtio_blk_deinit()
814 virtio_blk_rescan(struct vmctx *ctx, struct pci_vdev *dev, char *newpath) in virtio_blk_rescan() argument
819 struct virtio_blk *blk = (struct virtio_blk *) dev->arg; in virtio_blk_rescan()
838 dev->slot, dev->func) >= sizeof(bident)) { in virtio_blk_rescan()
852 pr_err("name=%s, Path=%s, ident=%s\n", dev->name, newpath, bident); in virtio_blk_rescan()
867 virtio_config_changed(dev->arg); in virtio_blk_rescan()
881 struct pci_vdev *dev; in vm_monitor_blkrescan() local
903 dev = pci_get_vdev_info(slot); in vm_monitor_blkrescan()
904 if (dev == NULL) { in vm_monitor_blkrescan()
910 if (strstr(dev->name, "virtio-blk") == NULL) { in vm_monitor_blkrescan()
912 pr_err("virtio-blk only supports rescan: found %s at slot %d\n", dev->name, slot); in vm_monitor_blkrescan()
914 error = virtio_blk_rescan(ctx, dev, str_newpath); in vm_monitor_blkrescan()