vgadev 132 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 134 drivers/gpu/vga/vgaarb.c list_for_each_entry(vgadev, &vga_list, list) vgadev 135 drivers/gpu/vga/vgaarb.c if (pdev == vgadev->pdev) vgadev 136 drivers/gpu/vga/vgaarb.c return vgadev; vgadev 220 drivers/gpu/vga/vgaarb.c static inline void vga_irq_set_state(struct vga_device *vgadev, bool state) vgadev 222 drivers/gpu/vga/vgaarb.c if (vgadev->irq_set_state) vgadev 223 drivers/gpu/vga/vgaarb.c vgadev->irq_set_state(vgadev->cookie, state); vgadev 241 drivers/gpu/vga/vgaarb.c static struct vga_device *__vga_tryget(struct vga_device *vgadev, vgadev 244 drivers/gpu/vga/vgaarb.c struct device *dev = &vgadev->pdev->dev; vgadev 254 drivers/gpu/vga/vgaarb.c (vgadev->decodes & VGA_RSRC_LEGACY_IO)) vgadev 257 drivers/gpu/vga/vgaarb.c (vgadev->decodes & VGA_RSRC_LEGACY_MEM)) vgadev 261 drivers/gpu/vga/vgaarb.c vgaarb_dbg(dev, "%s: owns: %d\n", __func__, vgadev->owns); vgadev 264 drivers/gpu/vga/vgaarb.c wants = rsrc & ~vgadev->owns; vgadev 283 drivers/gpu/vga/vgaarb.c if (vgadev == conflict) vgadev 289 drivers/gpu/vga/vgaarb.c if (!vga_conflicts(vgadev->pdev, conflict->pdev)) vgadev 298 drivers/gpu/vga/vgaarb.c if (vgadev->pdev->bus != conflict->pdev->bus) { vgadev 361 drivers/gpu/vga/vgaarb.c if (!vgadev->bridge_has_one_vga) { vgadev 371 drivers/gpu/vga/vgaarb.c pci_set_vga_state(vgadev->pdev, true, pci_bits, flags); vgadev 373 drivers/gpu/vga/vgaarb.c if (!vgadev->bridge_has_one_vga) vgadev 374 drivers/gpu/vga/vgaarb.c vga_irq_set_state(vgadev, true); vgadev 376 drivers/gpu/vga/vgaarb.c vgadev->owns |= wants; vgadev 378 drivers/gpu/vga/vgaarb.c vgadev->locks |= (rsrc & VGA_RSRC_LEGACY_MASK); vgadev 380 drivers/gpu/vga/vgaarb.c vgadev->io_lock_cnt++; vgadev 382 drivers/gpu/vga/vgaarb.c vgadev->mem_lock_cnt++; vgadev 384 drivers/gpu/vga/vgaarb.c vgadev->io_norm_cnt++; vgadev 386 drivers/gpu/vga/vgaarb.c vgadev->mem_norm_cnt++; vgadev 391 drivers/gpu/vga/vgaarb.c static void __vga_put(struct vga_device *vgadev, unsigned int rsrc) vgadev 393 drivers/gpu/vga/vgaarb.c struct device *dev = &vgadev->pdev->dev; vgadev 394 drivers/gpu/vga/vgaarb.c unsigned int old_locks = vgadev->locks; vgadev 401 drivers/gpu/vga/vgaarb.c if ((rsrc & VGA_RSRC_NORMAL_IO) && vgadev->io_norm_cnt > 0) { vgadev 402 drivers/gpu/vga/vgaarb.c vgadev->io_norm_cnt--; vgadev 403 drivers/gpu/vga/vgaarb.c if (vgadev->decodes & VGA_RSRC_LEGACY_IO) vgadev 406 drivers/gpu/vga/vgaarb.c if ((rsrc & VGA_RSRC_NORMAL_MEM) && vgadev->mem_norm_cnt > 0) { vgadev 407 drivers/gpu/vga/vgaarb.c vgadev->mem_norm_cnt--; vgadev 408 drivers/gpu/vga/vgaarb.c if (vgadev->decodes & VGA_RSRC_LEGACY_MEM) vgadev 411 drivers/gpu/vga/vgaarb.c if ((rsrc & VGA_RSRC_LEGACY_IO) && vgadev->io_lock_cnt > 0) vgadev 412 drivers/gpu/vga/vgaarb.c vgadev->io_lock_cnt--; vgadev 413 drivers/gpu/vga/vgaarb.c if ((rsrc & VGA_RSRC_LEGACY_MEM) && vgadev->mem_lock_cnt > 0) vgadev 414 drivers/gpu/vga/vgaarb.c vgadev->mem_lock_cnt--; vgadev 419 drivers/gpu/vga/vgaarb.c if (vgadev->io_lock_cnt == 0) vgadev 420 drivers/gpu/vga/vgaarb.c vgadev->locks &= ~VGA_RSRC_LEGACY_IO; vgadev 421 drivers/gpu/vga/vgaarb.c if (vgadev->mem_lock_cnt == 0) vgadev 422 drivers/gpu/vga/vgaarb.c vgadev->locks &= ~VGA_RSRC_LEGACY_MEM; vgadev 427 drivers/gpu/vga/vgaarb.c if (old_locks != vgadev->locks) vgadev 467 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev, *conflict; vgadev 481 drivers/gpu/vga/vgaarb.c vgadev = vgadev_find(pdev); vgadev 482 drivers/gpu/vga/vgaarb.c if (vgadev == NULL) { vgadev 487 drivers/gpu/vga/vgaarb.c conflict = __vga_tryget(vgadev, rsrc); vgadev 534 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 546 drivers/gpu/vga/vgaarb.c vgadev = vgadev_find(pdev); vgadev 547 drivers/gpu/vga/vgaarb.c if (vgadev == NULL) { vgadev 551 drivers/gpu/vga/vgaarb.c if (__vga_tryget(vgadev, rsrc)) vgadev 571 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 580 drivers/gpu/vga/vgaarb.c vgadev = vgadev_find(pdev); vgadev 581 drivers/gpu/vga/vgaarb.c if (vgadev == NULL) vgadev 583 drivers/gpu/vga/vgaarb.c __vga_put(vgadev, rsrc); vgadev 598 drivers/gpu/vga/vgaarb.c static void vga_arbiter_check_bridge_sharing(struct vga_device *vgadev) vgadev 604 drivers/gpu/vga/vgaarb.c vgadev->bridge_has_one_vga = true; vgadev 610 drivers/gpu/vga/vgaarb.c new_bus = vgadev->pdev->bus; vgadev 638 drivers/gpu/vga/vgaarb.c if (bridge && bridge == vgadev->pdev->bus->self) vgadev 639 drivers/gpu/vga/vgaarb.c vgadev->bridge_has_one_vga = false; vgadev 656 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 667 drivers/gpu/vga/vgaarb.c vgadev = kzalloc(sizeof(struct vga_device), GFP_KERNEL); vgadev 668 drivers/gpu/vga/vgaarb.c if (vgadev == NULL) { vgadev 683 drivers/gpu/vga/vgaarb.c vgadev->pdev = pdev; vgadev 686 drivers/gpu/vga/vgaarb.c vgadev->decodes = VGA_RSRC_LEGACY_IO | VGA_RSRC_LEGACY_MEM | vgadev 696 drivers/gpu/vga/vgaarb.c vgadev->owns |= VGA_RSRC_LEGACY_IO; vgadev 698 drivers/gpu/vga/vgaarb.c vgadev->owns |= VGA_RSRC_LEGACY_MEM; vgadev 709 drivers/gpu/vga/vgaarb.c vgadev->owns = 0; vgadev 720 drivers/gpu/vga/vgaarb.c ((vgadev->owns & VGA_RSRC_LEGACY_MASK) == VGA_RSRC_LEGACY_MASK)) { vgadev 725 drivers/gpu/vga/vgaarb.c vga_arbiter_check_bridge_sharing(vgadev); vgadev 728 drivers/gpu/vga/vgaarb.c list_add_tail(&vgadev->list, &vga_list); vgadev 731 drivers/gpu/vga/vgaarb.c vga_iostate_to_str(vgadev->decodes), vgadev 732 drivers/gpu/vga/vgaarb.c vga_iostate_to_str(vgadev->owns), vgadev 733 drivers/gpu/vga/vgaarb.c vga_iostate_to_str(vgadev->locks)); vgadev 739 drivers/gpu/vga/vgaarb.c kfree(vgadev); vgadev 745 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 750 drivers/gpu/vga/vgaarb.c vgadev = vgadev_find(pdev); vgadev 751 drivers/gpu/vga/vgaarb.c if (vgadev == NULL) { vgadev 759 drivers/gpu/vga/vgaarb.c if (vgadev->decodes & (VGA_RSRC_LEGACY_IO | VGA_RSRC_LEGACY_MEM)) vgadev 763 drivers/gpu/vga/vgaarb.c list_del(&vgadev->list); vgadev 774 drivers/gpu/vga/vgaarb.c kfree(vgadev); vgadev 779 drivers/gpu/vga/vgaarb.c static inline void vga_update_device_decodes(struct vga_device *vgadev, vgadev 782 drivers/gpu/vga/vgaarb.c struct device *dev = &vgadev->pdev->dev; vgadev 785 drivers/gpu/vga/vgaarb.c old_decodes = vgadev->decodes; vgadev 787 drivers/gpu/vga/vgaarb.c decodes_unlocked = vgadev->locks & decodes_removed; vgadev 788 drivers/gpu/vga/vgaarb.c vgadev->decodes = new_decodes; vgadev 792 drivers/gpu/vga/vgaarb.c vga_iostate_to_str(vgadev->decodes), vgadev 793 drivers/gpu/vga/vgaarb.c vga_iostate_to_str(vgadev->owns)); vgadev 798 drivers/gpu/vga/vgaarb.c vgadev->io_lock_cnt = 0; vgadev 800 drivers/gpu/vga/vgaarb.c vgadev->mem_lock_cnt = 0; vgadev 801 drivers/gpu/vga/vgaarb.c __vga_put(vgadev, decodes_unlocked); vgadev 818 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 824 drivers/gpu/vga/vgaarb.c vgadev = vgadev_find(pdev); vgadev 825 drivers/gpu/vga/vgaarb.c if (vgadev == NULL) vgadev 829 drivers/gpu/vga/vgaarb.c if (userspace && vgadev->set_vga_decode) vgadev 833 drivers/gpu/vga/vgaarb.c vga_update_device_decodes(vgadev, decodes); vgadev 886 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 890 drivers/gpu/vga/vgaarb.c vgadev = vgadev_find(pdev); vgadev 891 drivers/gpu/vga/vgaarb.c if (!vgadev) vgadev 894 drivers/gpu/vga/vgaarb.c vgadev->irq_set_state = irq_set_state; vgadev 895 drivers/gpu/vga/vgaarb.c vgadev->set_vga_decode = set_vga_decode; vgadev 896 drivers/gpu/vga/vgaarb.c vgadev->cookie = cookie; vgadev 1007 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 1032 drivers/gpu/vga/vgaarb.c vgadev = vgadev_find(pdev); vgadev 1033 drivers/gpu/vga/vgaarb.c if (vgadev == NULL) { vgadev 1048 drivers/gpu/vga/vgaarb.c vga_iostate_to_str(vgadev->decodes), vgadev 1049 drivers/gpu/vga/vgaarb.c vga_iostate_to_str(vgadev->owns), vgadev 1050 drivers/gpu/vga/vgaarb.c vga_iostate_to_str(vgadev->locks), vgadev 1051 drivers/gpu/vga/vgaarb.c vgadev->io_lock_cnt, vgadev->mem_lock_cnt); vgadev 1227 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 1255 drivers/gpu/vga/vgaarb.c vgadev = vgadev_find(pdev); vgadev 1256 drivers/gpu/vga/vgaarb.c pr_debug("vgadev %p\n", vgadev); vgadev 1257 drivers/gpu/vga/vgaarb.c if (vgadev == NULL) { vgadev 1392 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 1401 drivers/gpu/vga/vgaarb.c list_for_each_entry(vgadev, &vga_list, list) { vgadev 1406 drivers/gpu/vga/vgaarb.c if (vgadev->set_vga_decode) { vgadev 1407 drivers/gpu/vga/vgaarb.c new_decodes = vgadev->set_vga_decode(vgadev->cookie, vgadev 1409 drivers/gpu/vga/vgaarb.c vga_update_device_decodes(vgadev, new_decodes); vgadev 1457 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 1472 drivers/gpu/vga/vgaarb.c list_for_each_entry(vgadev, &vga_list, list) { vgadev 1473 drivers/gpu/vga/vgaarb.c struct device *dev = &vgadev->pdev->dev; vgadev 1485 drivers/gpu/vga/vgaarb.c flags = pci_resource_flags(vgadev->pdev, i); vgadev 1490 drivers/gpu/vga/vgaarb.c start = pci_resource_start(vgadev->pdev, i); vgadev 1491 drivers/gpu/vga/vgaarb.c end = pci_resource_end(vgadev->pdev, i); vgadev 1501 drivers/gpu/vga/vgaarb.c else if (vgadev->pdev != vga_default_device()) vgadev 1503 drivers/gpu/vga/vgaarb.c vga_set_default_device(vgadev->pdev); vgadev 1509 drivers/gpu/vga/vgaarb.c list_for_each_entry(vgadev, &vga_list, list) { vgadev 1510 drivers/gpu/vga/vgaarb.c struct device *dev = &vgadev->pdev->dev; vgadev 1513 drivers/gpu/vga/vgaarb.c pdev = vgadev->pdev; vgadev 1524 drivers/gpu/vga/vgaarb.c vgadev = list_first_entry_or_null(&vga_list, vgadev 1526 drivers/gpu/vga/vgaarb.c if (vgadev) { vgadev 1527 drivers/gpu/vga/vgaarb.c struct device *dev = &vgadev->pdev->dev; vgadev 1529 drivers/gpu/vga/vgaarb.c vga_set_default_device(vgadev->pdev); vgadev 1538 drivers/gpu/vga/vgaarb.c struct vga_device *vgadev; vgadev 1554 drivers/gpu/vga/vgaarb.c list_for_each_entry(vgadev, &vga_list, list) { vgadev 1555 drivers/gpu/vga/vgaarb.c struct device *dev = &vgadev->pdev->dev; vgadev 1557 drivers/gpu/vga/vgaarb.c if (vgadev->bridge_has_one_vga)