• Home
  • Raw
  • Download

Lines Matching full:devid

106 	u16 devid;  member
124 u16 devid; member
144 u16 devid; member
297 PCI_BUS_NUM(iommu->devid), PCI_SLOT(iommu->devid), in get_global_efr()
298 PCI_FUNC(iommu->devid)); in get_global_efr()
592 if (dev->devid > last_devid) in find_last_devid_from_ivhd()
593 last_devid = dev->devid; in find_last_devid_from_ivhd()
1059 u16 devid, u8 bit) in __set_dev_entry_bit() argument
1064 dev_table[devid].data[i] |= (1UL << _bit); in __set_dev_entry_bit()
1067 static void set_dev_entry_bit(struct amd_iommu *iommu, u16 devid, u8 bit) in set_dev_entry_bit() argument
1071 return __set_dev_entry_bit(dev_table, devid, bit); in set_dev_entry_bit()
1075 u16 devid, u8 bit) in __get_dev_entry_bit() argument
1080 return (dev_table[devid].data[i] & (1UL << _bit)) >> _bit; in __get_dev_entry_bit()
1083 static int get_dev_entry_bit(struct amd_iommu *iommu, u16 devid, u8 bit) in get_dev_entry_bit() argument
1087 return __get_dev_entry_bit(dev_table, devid, bit); in get_dev_entry_bit()
1095 u32 lo, hi, devid, old_devtb_size; in __copy_device_table() local
1141 for (devid = 0; devid <= pci_seg->last_bdf; ++devid) { in __copy_device_table()
1142 pci_seg->old_dev_tbl_cpy[devid] = old_devtb[devid]; in __copy_device_table()
1143 dom_id = old_devtb[devid].data[1] & DEV_DOMID_MASK; in __copy_device_table()
1144 dte_v = old_devtb[devid].data[0] & DTE_FLAG_V; in __copy_device_table()
1147 pci_seg->old_dev_tbl_cpy[devid].data[0] = old_devtb[devid].data[0]; in __copy_device_table()
1148 pci_seg->old_dev_tbl_cpy[devid].data[1] = old_devtb[devid].data[1]; in __copy_device_table()
1151 if (old_devtb[devid].data[0] & DTE_FLAG_GV) { in __copy_device_table()
1154 pci_seg->old_dev_tbl_cpy[devid].data[1] &= ~tmp; in __copy_device_table()
1157 pci_seg->old_dev_tbl_cpy[devid].data[0] &= ~tmp; in __copy_device_table()
1161 irq_v = old_devtb[devid].data[2] & DTE_IRQ_REMAP_ENABLE; in __copy_device_table()
1162 int_ctl = old_devtb[devid].data[2] & DTE_IRQ_REMAP_INTCTL_MASK; in __copy_device_table()
1163 int_tab_len = old_devtb[devid].data[2] & DTE_INTTABLEN_MASK; in __copy_device_table()
1167 pr_err("Wrong old irq remapping flag: %#x\n", devid); in __copy_device_table()
1172 pci_seg->old_dev_tbl_cpy[devid].data[2] = old_devtb[devid].data[2]; in __copy_device_table()
1207 void amd_iommu_apply_erratum_63(struct amd_iommu *iommu, u16 devid) in amd_iommu_apply_erratum_63() argument
1211 sysmgt = get_dev_entry_bit(iommu, devid, DEV_ENTRY_SYSMGT1) | in amd_iommu_apply_erratum_63()
1212 (get_dev_entry_bit(iommu, devid, DEV_ENTRY_SYSMGT2) << 1); in amd_iommu_apply_erratum_63()
1215 set_dev_entry_bit(iommu, devid, DEV_ENTRY_IW); in amd_iommu_apply_erratum_63()
1223 u16 devid, u32 flags, u32 ext_flags) in set_dev_entry_from_acpi() argument
1226 set_dev_entry_bit(iommu, devid, DEV_ENTRY_INIT_PASS); in set_dev_entry_from_acpi()
1228 set_dev_entry_bit(iommu, devid, DEV_ENTRY_EINT_PASS); in set_dev_entry_from_acpi()
1230 set_dev_entry_bit(iommu, devid, DEV_ENTRY_NMI_PASS); in set_dev_entry_from_acpi()
1232 set_dev_entry_bit(iommu, devid, DEV_ENTRY_SYSMGT1); in set_dev_entry_from_acpi()
1234 set_dev_entry_bit(iommu, devid, DEV_ENTRY_SYSMGT2); in set_dev_entry_from_acpi()
1236 set_dev_entry_bit(iommu, devid, DEV_ENTRY_LINT0_PASS); in set_dev_entry_from_acpi()
1238 set_dev_entry_bit(iommu, devid, DEV_ENTRY_LINT1_PASS); in set_dev_entry_from_acpi()
1240 amd_iommu_apply_erratum_63(iommu, devid); in set_dev_entry_from_acpi()
1242 amd_iommu_set_rlookup_table(iommu, devid); in set_dev_entry_from_acpi()
1245 int __init add_special_device(u8 type, u8 id, u32 *devid, bool cmd_line) in add_special_device() argument
1264 *devid = entry->devid; in add_special_device()
1274 entry->devid = *devid; in add_special_device()
1282 static int __init add_acpi_hid_device(u8 *hid, u8 *uid, u32 *devid, in add_acpi_hid_device() argument
1296 *devid = entry->devid; in add_acpi_hid_device()
1306 entry->devid = *devid; in add_acpi_hid_device()
1308 entry->root_devid = (entry->devid & (~0x7)); in add_acpi_hid_device()
1325 &early_ioapic_map[i].devid, in add_early_maps()
1334 &early_hpet_map[i].devid, in add_early_maps()
1343 &early_acpihid_map[i].devid, in add_early_maps()
1361 u16 devid = 0, devid_start = 0, devid_to = 0, seg_id; in init_iommu_from_acpi() local
1409 DUMP_printk(" DEV_SELECT\t\t\t devid: %04x:%02x:%02x.%x " in init_iommu_from_acpi()
1411 seg_id, PCI_BUS_NUM(e->devid), in init_iommu_from_acpi()
1412 PCI_SLOT(e->devid), in init_iommu_from_acpi()
1413 PCI_FUNC(e->devid), in init_iommu_from_acpi()
1416 devid = e->devid; in init_iommu_from_acpi()
1417 set_dev_entry_from_acpi(iommu, devid, e->flags, 0); in init_iommu_from_acpi()
1422 "devid: %04x:%02x:%02x.%x flags: %02x\n", in init_iommu_from_acpi()
1423 seg_id, PCI_BUS_NUM(e->devid), in init_iommu_from_acpi()
1424 PCI_SLOT(e->devid), in init_iommu_from_acpi()
1425 PCI_FUNC(e->devid), in init_iommu_from_acpi()
1428 devid_start = e->devid; in init_iommu_from_acpi()
1435 DUMP_printk(" DEV_ALIAS\t\t\t devid: %04x:%02x:%02x.%x " in init_iommu_from_acpi()
1437 seg_id, PCI_BUS_NUM(e->devid), in init_iommu_from_acpi()
1438 PCI_SLOT(e->devid), in init_iommu_from_acpi()
1439 PCI_FUNC(e->devid), in init_iommu_from_acpi()
1445 devid = e->devid; in init_iommu_from_acpi()
1447 set_dev_entry_from_acpi(iommu, devid , e->flags, 0); in init_iommu_from_acpi()
1449 pci_seg->alias_table[devid] = devid_to; in init_iommu_from_acpi()
1454 "devid: %04x:%02x:%02x.%x flags: %02x " in init_iommu_from_acpi()
1456 seg_id, PCI_BUS_NUM(e->devid), in init_iommu_from_acpi()
1457 PCI_SLOT(e->devid), in init_iommu_from_acpi()
1458 PCI_FUNC(e->devid), in init_iommu_from_acpi()
1464 devid_start = e->devid; in init_iommu_from_acpi()
1472 DUMP_printk(" DEV_EXT_SELECT\t\t devid: %04x:%02x:%02x.%x " in init_iommu_from_acpi()
1474 seg_id, PCI_BUS_NUM(e->devid), in init_iommu_from_acpi()
1475 PCI_SLOT(e->devid), in init_iommu_from_acpi()
1476 PCI_FUNC(e->devid), in init_iommu_from_acpi()
1479 devid = e->devid; in init_iommu_from_acpi()
1480 set_dev_entry_from_acpi(iommu, devid, e->flags, in init_iommu_from_acpi()
1485 DUMP_printk(" DEV_EXT_SELECT_RANGE\t devid: " in init_iommu_from_acpi()
1487 seg_id, PCI_BUS_NUM(e->devid), in init_iommu_from_acpi()
1488 PCI_SLOT(e->devid), in init_iommu_from_acpi()
1489 PCI_FUNC(e->devid), in init_iommu_from_acpi()
1492 devid_start = e->devid; in init_iommu_from_acpi()
1499 DUMP_printk(" DEV_RANGE_END\t\t devid: %04x:%02x:%02x.%x\n", in init_iommu_from_acpi()
1500 seg_id, PCI_BUS_NUM(e->devid), in init_iommu_from_acpi()
1501 PCI_SLOT(e->devid), in init_iommu_from_acpi()
1502 PCI_FUNC(e->devid)); in init_iommu_from_acpi()
1504 devid = e->devid; in init_iommu_from_acpi()
1505 for (dev_i = devid_start; dev_i <= devid; ++dev_i) { in init_iommu_from_acpi()
1518 u32 devid; in init_iommu_from_acpi() local
1522 devid = PCI_SEG_DEVID_TO_SBDF(seg_id, (e->ext >> 8)); in init_iommu_from_acpi()
1534 seg_id, PCI_BUS_NUM(devid), in init_iommu_from_acpi()
1535 PCI_SLOT(devid), in init_iommu_from_acpi()
1536 PCI_FUNC(devid)); in init_iommu_from_acpi()
1538 ret = add_special_device(type, handle, &devid, false); in init_iommu_from_acpi()
1543 * add_special_device might update the devid in case a in init_iommu_from_acpi()
1547 set_dev_entry_from_acpi(iommu, devid, e->flags, 0); in init_iommu_from_acpi()
1552 u32 devid; in init_iommu_from_acpi() local
1595 devid = PCI_SEG_DEVID_TO_SBDF(seg_id, e->devid); in init_iommu_from_acpi()
1598 PCI_BUS_NUM(devid), in init_iommu_from_acpi()
1599 PCI_SLOT(devid), in init_iommu_from_acpi()
1600 PCI_FUNC(devid)); in init_iommu_from_acpi()
1604 ret = add_acpi_hid_device(hid, uid, &devid, false); in init_iommu_from_acpi()
1609 * add_special_device might update the devid in case a in init_iommu_from_acpi()
1613 set_dev_entry_from_acpi(iommu, devid, e->flags, 0); in init_iommu_from_acpi()
1807 iommu->devid = h->devid; in init_iommu_one()
1901 iommu->pci_seg->rlookup_table[iommu->devid] = NULL; in init_iommu_one_late()
1918 u16 devid = ivhd->devid; in get_highest_supported_ivhd_type() local
1924 if (ivhd->devid == devid) in get_highest_supported_ivhd_type()
1953 h->pci_seg, PCI_BUS_NUM(h->devid), in init_iommu_all()
1954 PCI_SLOT(h->devid), PCI_FUNC(h->devid), in init_iommu_all()
2079 PCI_BUS_NUM(iommu->devid), in iommu_init_pci()
2080 iommu->devid & 0xff); in iommu_init_pci()
2580 e->devid_start = e->devid_end = m->devid; in init_unity_map_range()
2589 e->devid_start = m->devid; in init_unity_map_range()
2646 u32 devid; in init_device_table_dma() local
2652 for (devid = 0; devid <= pci_seg->last_bdf; ++devid) { in init_device_table_dma()
2653 __set_dev_entry_bit(dev_table, devid, DEV_ENTRY_VALID); in init_device_table_dma()
2655 __set_dev_entry_bit(dev_table, devid, DEV_ENTRY_TRANSLATION); in init_device_table_dma()
2661 u32 devid; in uninit_device_table_dma() local
2667 for (devid = 0; devid <= pci_seg->last_bdf; ++devid) { in uninit_device_table_dma()
2668 dev_table[devid].data[0] = 0ULL; in uninit_device_table_dma()
2669 dev_table[devid].data[1] = 0ULL; in uninit_device_table_dma()
2676 u32 devid; in init_device_table() local
2682 for (devid = 0; devid <= pci_seg->last_bdf; ++devid) in init_device_table()
2684 devid, DEV_ENTRY_IRQ_TBL_EN); in init_device_table()
2797 iommu->index, iommu->devid, in iommu_enable_irtcachedis()
3025 int devid, id = mpc_ioapic_id(idx); in check_ioapic_information() local
3027 devid = get_ioapic_devid(id); in check_ioapic_information()
3028 if (devid < 0) { in check_ioapic_information()
3032 } else if (devid == IOAPIC_SB_DEVID) { in check_ioapic_information()
3541 u32 devid; in parse_ivrs_ioapic() local
3564 devid = IVRS_GET_SBDF_ID(seg, bus, dev, fn); in parse_ivrs_ioapic()
3569 early_ioapic_map[i].devid = devid; in parse_ivrs_ioapic()
3579 u32 devid; in parse_ivrs_hpet() local
3602 devid = IVRS_GET_SBDF_ID(seg, bus, dev, fn); in parse_ivrs_hpet()
3607 early_hpet_map[i].devid = devid; in parse_ivrs_hpet()
3679 early_acpihid_map[i].devid = IVRS_GET_SBDF_ID(seg, bus, dev, fn); in parse_ivrs_acpihid()