Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 282802
b: refs/heads/master
c: 8fbdce6
h: refs/heads/master
v: v3
  • Loading branch information
Alex Williamson authored and Joerg Roedel committed Nov 15, 2011
1 parent 0c05a3b commit f0fc9f0
Show file tree
Hide file tree
Showing 2 changed files with 14 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: 70ae6f0d55bd216b2f773fa5fa5018c0490a9e50
refs/heads/master: 8fbdce659549d93dfb257ec4eabacf63a188e506
13 changes: 13 additions & 0 deletions trunk/drivers/iommu/amd_iommu.c
Original file line number Diff line number Diff line change
Expand Up @@ -2773,6 +2773,18 @@ static int amd_iommu_domain_has_cap(struct iommu_domain *domain,
return 0;
}

static int amd_iommu_device_group(struct device *dev, unsigned int *groupid)
{
struct iommu_dev_data *dev_data = dev->archdata.iommu;

if (!dev_data)
return -ENODEV;

*groupid = amd_iommu_alias_table[dev_data->devid];

return 0;
}

static struct iommu_ops amd_iommu_ops = {
.domain_init = amd_iommu_domain_init,
.domain_destroy = amd_iommu_domain_destroy,
Expand All @@ -2782,6 +2794,7 @@ static struct iommu_ops amd_iommu_ops = {
.unmap = amd_iommu_unmap,
.iova_to_phys = amd_iommu_iova_to_phys,
.domain_has_cap = amd_iommu_domain_has_cap,
.device_group = amd_iommu_device_group,
};

/*****************************************************************************
Expand Down

0 comments on commit f0fc9f0

Please sign in to comment.