Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 145904
b: refs/heads/master
c: 7d7a110
h: refs/heads/master
v: v3
  • Loading branch information
Joerg Roedel committed May 28, 2009
1 parent 8e98581 commit 31da977
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: bfd1be1857e5a3385bf146e02e6dc3dd4241bec1
refs/heads/master: 7d7a110c6127b7fc683dc6d764555f2dbd22b054
1 change: 1 addition & 0 deletions trunk/arch/x86/include/asm/amd_iommu.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ extern int amd_iommu_init_dma_ops(void);
extern void amd_iommu_detect(void);
extern irqreturn_t amd_iommu_int_handler(int irq, void *data);
extern void amd_iommu_flush_all_domains(void);
extern void amd_iommu_flush_all_devices(void);
#else
static inline int amd_iommu_init(void) { return -ENODEV; }
static inline void amd_iommu_detect(void) { }
Expand Down
18 changes: 18 additions & 0 deletions trunk/arch/x86/kernel/amd_iommu.c
Original file line number Diff line number Diff line change
Expand Up @@ -460,6 +460,24 @@ void amd_iommu_flush_all_domains(void)
}
}

void amd_iommu_flush_all_devices(void)
{
struct amd_iommu *iommu;
int i;

for (i = 0; i <= amd_iommu_last_bdf; ++i) {
if (amd_iommu_pd_table[i] == NULL)
continue;

iommu = amd_iommu_rlookup_table[i];
if (!iommu)
continue;

iommu_queue_inv_dev_entry(iommu, i);
iommu_completion_wait(iommu);
}
}

/****************************************************************************
*
* The functions below are used the create the page table mappings for
Expand Down

0 comments on commit 31da977

Please sign in to comment.