diff options
author | Suresh Siddha <suresh.b.siddha@intel.com> | 2009-10-02 11:01:22 -0700 |
---|---|---|
committer | David Woodhouse <David.Woodhouse@intel.com> | 2009-10-05 07:55:26 +0100 |
commit | 751cafe3aeceb9ff887c97237f6daaf596c9e547 (patch) | |
tree | 810ea3e51dd942afb850e3523b97d61f296dcff0 /drivers/pci | |
parent | ee34b32d8c2950f66038c8975747ef9aec855289 (diff) | |
download | kernel_samsung_crespo-751cafe3aeceb9ff887c97237f6daaf596c9e547.zip kernel_samsung_crespo-751cafe3aeceb9ff887c97237f6daaf596c9e547.tar.gz kernel_samsung_crespo-751cafe3aeceb9ff887c97237f6daaf596c9e547.tar.bz2 |
dmar: Allocate queued invalidation structure using numa locality info
Allocate queued invalidation descriptor structures using numa locality info.
Signed-off-by: Suresh Siddha <suresh.b.siddha@intel.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
Diffstat (limited to 'drivers/pci')
-rw-r--r-- | drivers/pci/dmar.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/pci/dmar.c b/drivers/pci/dmar.c index 5779565..63aa529 100644 --- a/drivers/pci/dmar.c +++ b/drivers/pci/dmar.c @@ -1040,6 +1040,7 @@ static void __dmar_enable_qi(struct intel_iommu *iommu) int dmar_enable_qi(struct intel_iommu *iommu) { struct q_inval *qi; + struct page *desc_page; if (!ecap_qis(iommu->ecap)) return -ENOENT; @@ -1056,13 +1057,16 @@ int dmar_enable_qi(struct intel_iommu *iommu) qi = iommu->qi; - qi->desc = (void *)(get_zeroed_page(GFP_ATOMIC)); - if (!qi->desc) { + + desc_page = alloc_pages_node(iommu->node, GFP_ATOMIC | __GFP_ZERO, 0); + if (!desc_page) { kfree(qi); iommu->qi = 0; return -ENOMEM; } + qi->desc = page_address(desc_page); + qi->desc_status = kmalloc(QI_LENGTH * sizeof(int), GFP_ATOMIC); if (!qi->desc_status) { free_page((unsigned long) qi->desc); |