iommu/amd: Remove device binding reference count
authorJoerg Roedel <jroedel@suse.de>
Tue, 5 Aug 2014 15:34:25 +0000 (17:34 +0200)
committerJoerg Roedel <jroedel@suse.de>
Tue, 26 Aug 2014 09:37:52 +0000 (11:37 +0200)
This reference count is not used anymore, as all devices in
an alias group are now attached and detached together.

Signed-off-by: Joerg Roedel <jroedel@suse.de>
drivers/iommu/amd_iommu.c

index a5e6b0a2de1609163dd9e26670835962b399dbaf..989c1ae039795aeb2bec7d5260ad710d85fcfb06 100644 (file)
@@ -96,7 +96,6 @@ struct iommu_dev_data {
        struct list_head alias_list;      /* Link alias-groups together */
        struct iommu_dev_data *alias_data;/* The alias dev_data */
        struct protection_domain *domain; /* Domain the device is bound to */
-       atomic_t bind;                    /* Domain attach reference count */
        u16 devid;                        /* PCI Device ID */
        bool iommu_v2;                    /* Device can make use of IOMMUv2 */
        bool passthrough;                 /* Default for device is pt_domain */
@@ -139,7 +138,6 @@ static struct iommu_dev_data *alloc_dev_data(u16 devid)
        INIT_LIST_HEAD(&dev_data->alias_list);
 
        dev_data->devid = devid;
-       atomic_set(&dev_data->bind, 0);
 
        spin_lock_irqsave(&dev_data_list_lock, flags);
        list_add_tail(&dev_data->dev_data_list, &dev_data_list);
@@ -3179,7 +3177,6 @@ static void cleanup_domain(struct protection_domain *domain)
                entry = list_first_entry(&domain->dev_list,
                                         struct iommu_dev_data, list);
                __detach_device(entry);
-               atomic_set(&entry->bind, 0);
        }
 
        write_unlock_irqrestore(&amd_iommu_devtable_lock, flags);
This page took 0.026125 seconds and 5 git commands to generate.