Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge tag 'iommu-fixes-v3.12-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu

Pull iommu fixes from Joerg Roedel:
"A couple of fixes from the IOMMU side:

- some small fixes for the new ARM-SMMU driver
- a register offset correction for VT-d
- add MAINTAINERS entry for drivers/iommu

Overall no really big or intrusive changes"

* tag 'iommu-fixes-v3.12-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu:
x86/iommu: correct ICS register offset
MAINTAINERS: add overall IOMMU section
iommu/arm-smmu: don't enable SMMU device until probing has completed
iommu/arm-smmu: fix iommu_present() test in init
iommu/arm-smmu: fix a signedness bug

+15 -7
+7
MAINTAINERS
··· 4476 4476 S: Maintained 4477 4477 F: drivers/tty/serial/ioc3_serial.c 4478 4478 4479 + IOMMU DRIVERS 4480 + M: Joerg Roedel <joro@8bytes.org> 4481 + L: iommu@lists.linux-foundation.org 4482 + T: git git://git.kernel.org/pub/scm/linux/kernel/git/joro/iommu.git 4483 + S: Maintained 4484 + F: drivers/iommu/ 4485 + 4479 4486 IP MASQUERADING 4480 4487 M: Juanjo Ciarlante <jjciarla@raiz.uncu.edu.ar> 4481 4488 S: Maintained
+7 -6
drivers/iommu/arm-smmu.c
··· 377 377 u32 cbar; 378 378 pgd_t *pgd; 379 379 }; 380 + #define INVALID_IRPTNDX 0xff 380 381 381 382 #define ARM_SMMU_CB_ASID(cfg) ((cfg)->cbndx) 382 383 #define ARM_SMMU_CB_VMID(cfg) ((cfg)->cbndx + 1) ··· 841 840 if (IS_ERR_VALUE(ret)) { 842 841 dev_err(smmu->dev, "failed to request context IRQ %d (%u)\n", 843 842 root_cfg->irptndx, irq); 844 - root_cfg->irptndx = -1; 843 + root_cfg->irptndx = INVALID_IRPTNDX; 845 844 goto out_free_context; 846 845 } 847 846 ··· 870 869 writel_relaxed(0, cb_base + ARM_SMMU_CB_SCTLR); 871 870 arm_smmu_tlb_inv_context(root_cfg); 872 871 873 - if (root_cfg->irptndx != -1) { 872 + if (root_cfg->irptndx != INVALID_IRPTNDX) { 874 873 irq = smmu->irqs[smmu->num_global_irqs + root_cfg->irptndx]; 875 874 free_irq(irq, domain); 876 875 } ··· 1858 1857 goto out_put_parent; 1859 1858 } 1860 1859 1861 - arm_smmu_device_reset(smmu); 1862 - 1863 1860 for (i = 0; i < smmu->num_global_irqs; ++i) { 1864 1861 err = request_irq(smmu->irqs[i], 1865 1862 arm_smmu_global_fault, ··· 1875 1876 spin_lock(&arm_smmu_devices_lock); 1876 1877 list_add(&smmu->list, &arm_smmu_devices); 1877 1878 spin_unlock(&arm_smmu_devices_lock); 1879 + 1880 + arm_smmu_device_reset(smmu); 1878 1881 return 0; 1879 1882 1880 1883 out_free_irqs: ··· 1967 1966 return ret; 1968 1967 1969 1968 /* Oh, for a proper bus abstraction */ 1970 - if (!iommu_present(&platform_bus_type)); 1969 + if (!iommu_present(&platform_bus_type)) 1971 1970 bus_set_iommu(&platform_bus_type, &arm_smmu_ops); 1972 1971 1973 - if (!iommu_present(&amba_bustype)); 1972 + if (!iommu_present(&amba_bustype)) 1974 1973 bus_set_iommu(&amba_bustype, &arm_smmu_ops); 1975 1974 1976 1975 return 0;
+1 -1
include/linux/intel-iommu.h
··· 55 55 #define DMAR_IQT_REG 0x88 /* Invalidation queue tail register */ 56 56 #define DMAR_IQ_SHIFT 4 /* Invalidation queue head/tail shift */ 57 57 #define DMAR_IQA_REG 0x90 /* Invalidation queue addr register */ 58 - #define DMAR_ICS_REG 0x98 /* Invalidation complete status register */ 58 + #define DMAR_ICS_REG 0x9c /* Invalidation complete status register */ 59 59 #define DMAR_IRTA_REG 0xb8 /* Interrupt remapping table addr register */ 60 60 61 61 #define OFFSET_STRIDE (9)