- 10 8月, 2012 2 次提交
-
-
由 Joerg Roedel 提交于
The check in the for-loop is broken. Fix it and the boot-crash it causes in AMD IOMMUv2 systems. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Seth Forshee 提交于
The ACPI tables in the Macbook Air 5,1 define a single IOAPIC with id 2, but the only remapping unit described in the DMAR table matches id 0. Interrupt remapping fails as a result, and the kernel panics with the message "timer doesn't work through Interrupt-remapped IO-APIC." To fix this, check each IOAPIC for a corresponding IOMMU. If an IOMMU is not found, do not allow IRQ remapping to be enabled. v2: Move check to parse_ioapics_under_ir(), raise log level to KERN_ERR, and add FW_BUG to the log message v3: Skip check if IOMMU doesn't support interrupt remapping and remove existing check that the IOMMU count equals the IOAPIC count Acked-by: NSuresh Siddha <suresh.b.siddha@intel.com> Signed-off-by: NSeth Forshee <seth.forshee@canonical.com> Acked-by: NYinghai Lu <yinghai@kernel.org> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
- 07 8月, 2012 3 次提交
-
-
由 Alex Williamson 提交于
SR-IOV can create buses without a bridge. There may be other cases where this happens as well. In these cases skip to the parent bus and continue testing devices there. Signed-off-by: NAlex Williamson <alex.williamson@redhat.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Alex Williamson 提交于
SR-IOV can create buses without a bridge. There may be other cases where this happens as well. In these cases skip to the parent bus and continue testing devices there. Signed-off-by: NAlex Williamson <alex.williamson@redhat.com> Tested-by: NDavid Ahern <dsahern@gmail.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
The pci_request_acs() function needs to be called before PCI probing to be effective. So move it to another call-place to ensure that. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
- 03 8月, 2012 5 次提交
-
-
由 Sachin Kamat 提交于
Fixes the following build error introduced by commit 3177bb76 ("iommu/exynos: Implement DOMAIN_ATTR_GEOMETRY attribute"): drivers/iommu/exynos-iommu.c: In function ‘exynos_iommu_domain_init’: drivers/iommu/exynos-iommu.c:735:2: error: ‘dom’ undeclared (first use in this function) Signed-off-by: NSachin Kamat <sachin.kamat@linaro.org> Acked-by: NKukjin Kim <kgene.kim@samsung.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi Doyu 提交于
err initial value should be -EAGAIN. Otherwise 2nd iteration always fails in the case as[0] is occupied. Signed-off-by: NHiroshi Doyu <hdoyu@nvidia.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi Doyu 提交于
Small clean up with lesser nest for readability. Signed-off-by: NHiroshi Doyu <hdoyu@nvidia.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Julia Lawall 提交于
Add missing free_domain_mem on failure path after alloc_domain. A simplified version of the semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // <smpl> @km exists@ local idexpression e; expression e1,e2,e3; type T,T1; identifier f; @@ * e = alloc_domain(...) ... when any when != e = e1 when != e1 = (T)e when != e1(...,(T)e,...) when != &e->f if(...) { ... when != e2(...,(T1)e,...) when != e3 = e when forall ( return <+...e...+>; | * return ...; ) } // </smpl> Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Julia Lawall 提交于
If list_for_each_entry, etc complete a traversal of the list, the iterator variable ends up pointing to an address at an offset from the list head, and not a meaningful structure. Thus this value should not be used after the end of the iterator. Replace c->dev by dev, which is the value that c->dev has been compared to. This problem was found using Coccinelle (http://coccinelle.lip6.fr/). Signed-off-by: NJulia Lawall <Julia.Lawall@lip6.fr> Acked-by: NStephen Warren <swarren@wwwdotorg.org> Acked-by: NHiroshi DOYU <hdoyu@nvidia.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
- 24 7月, 2012 1 次提交
-
-
由 Masanari Iida 提交于
Correct spelling typo in debug messages and comments in drivers/iommu. Signed-off-by: NMasanari Iida <standby24x7@gmail.com> Signed-off-by: NJiri Kosina <jkosina@suse.cz>
-
- 19 7月, 2012 2 次提交
-
-
由 Joerg Roedel 提交于
This did not work because devices are not put into the pt_domain. Fix this. Cc: stable@vger.kernel.org Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
Add missing spin_lock initialization in amd_iommu_bind_pasid() function and make lockdep happy again. Cc: stable@vger.kernel.org # >= v3.3 Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
- 17 7月, 2012 12 次提交
-
-
由 Joerg Roedel 提交于
This step makes it very easy to keep track about the current intialization state of the iommu driver. With this change we can initialize the IOMMU hardware to a point where it can remap interrupts and later resume the initializion to enable dma remapping. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
This function will initialize everthing necessary so that devices can do DMA. This includes dma_ops and iommu_ops. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
The message belongs there anyway, so move it to that function. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
Split the enable_iommus() routine so that a part of it can run in early code. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
Split out the code to parse the ACPI table and setup relevant data structures into a new function. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
This function will be called before the PCI subsystem is initialized. Therefore dev_name doen't work and IOMMU information can't be printed to the klog as before. Move the code to print that information to a later point where PCI initializtion has already happened. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
For interrupt remapping the relevant IOMMU initialization needs to run earlier at boot when the PCI subsystem is not yet initialized. To support that this patch splits the parts of IOMMU initialization which need PCI accesses out of the initial setup path so that this can be done later. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
This makes it easier to propagate errors while parsing the IVRS table and makes the amd_iommu_init_err hack obsolete. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
A few sparse warnings fire in drivers/iommu/amd_iommu_init.c. Fix most of them with this patch. Also fix the sparse warnings in drivers/iommu/irq_remapping.c while at it. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
Instead of taking as->lock before calling alloc_pdir() and releasing it in that function to allocate memory, just take the lock only in the alloc_pdir function and run the loop without any lock held. This simplifies the complicated lock->unlock->alloc->lock->unlock sequence into alloc->lock->unlock. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi DOYU 提交于
alloc_pdir() is called from smmu_iommu_domain_init() with spin_lock held. memory allocations in alloc_pdir() had to be atomic. Instead of converting into atomic allocation, this patch once releases a lock, does the allocation, holds the lock again and then sees if it's raced or not in order to avoid introducing mutex and preallocation. Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Reported-by: NChris Wright <chrisw@sous-sol.org> Cc: Chris Wright <chrisw@sous-sol.org> Acked-by: NStephen Warren <swarren@wwwdotorg.org> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi DOYU 提交于
alloc_pdir() is called with smmu->as[?].pdir_page == NULL. No need to check pdir_page again inside alloc_pdir(). Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Acked-by: NStephen Warren <swarren@wwwdotorg.org> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
- 11 7月, 2012 7 次提交
-
-
由 Joerg Roedel 提交于
Implement the attribute for the Samsung Exynos IOMMU driver. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi DOYU 提交于
Implement the attribute for the Tegra IOMMU drivers. Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
Implement the attribute for the MSM IOMMU driver. Acked-by: NDavid Brown <davidb@codeaurora.org> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
Implement the attribute for the OMAP IOMMU driver. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
Implement the attribute for the Intel IOMMU driver. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
Implement the attribute itself and add the code for the AMD IOMMU driver. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Joerg Roedel 提交于
This patch introduces an extension to the iommu-api to get and set attributes for an iommu_domain. Two functions are introduced for this: * iommu_domain_get_attr() * iommu_domain_set_attr() These functions will be used to make the iommu-api suitable for GART-like IOMMUs and to implement hardware-specifc api-extensions. Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
- 02 7月, 2012 2 次提交
-
-
由 Dan Carpenter 提交于
write_file_bool() modifies 32 bits of data, so "amd_iommu_unmap_flush" needs to be 32 bits as well or we'll corrupt memory. Fortunately it looks like the data is aligned with a gap after the declaration so this is harmless in production. Signed-off-by: NDan Carpenter <dan.carpenter@oracle.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi DOYU 提交于
allo_pdir() is called in smmu_iommu_domain_init() with spin_lock held. memory allocations in it have to be atomic/unsleepable. Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Reported-by: NChris Wright <chrisw@sous-sol.org> Acked-by: NChris Wright <chrisw@sous-sol.org> Cc: stable@vger.kernel.org Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
- 25 6月, 2012 6 次提交
-
-
由 Hiroshi Doyu 提交于
For the compiler warning, uninitizlized var when getting value by a pointer. Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi Doyu 提交于
Remove unnecessary cleanup procedures with devm_*() functions. Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Acked-by: NStephen Warren <swarren@wwwdotorg.org> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi Doyu 提交于
To simplify the code, alloc necessary data at once. Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Acked-by: NStephen Warren <swarren@wwwdotorg.org> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi Doyu 提交于
The necessary info is expected to pass from DT. For more precise resource reservation, there shouldn't be any overlapping of register range between SMMU and MC. SMMU register offset needs to be calculated correctly, based on its register bank. Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Acked-by: NStephen Warren <swarren@wwwdotorg.org> Acked-by: NGrant Likely <grant.likely@secretlab.ca> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Hiroshi Doyu 提交于
This code was based on: "arch/microblaze/kernel/prom_parse.c" "arch/powerpc/kernel/prom_parse.c" Can replace "of_parse_dma_window()" in the above. This supports different formats flexibly. "prefix" can be configured if any. "busno" and "index" are optionally specified. Set NULL and 0 if not used. Signed-off-by: NHiroshi DOYU <hdoyu@nvidia.com> Acked-by: NStephen Warren <swarren@wwwdotorg.org> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-
由 Alex Williamson 提交于
Work around broken devices and adhere to ACS support when determining IOMMU grouping. Signed-off-by: NAlex Williamson <alex.williamson@redhat.com> Signed-off-by: NJoerg Roedel <joerg.roedel@amd.com>
-