Skip to content

Commit 94c793a

Browse files
arndbjoergroedel
authored andcommitted
iommu/amd: Hide unused iommu_table_lock
The newly introduced lock is only used when CONFIG_IRQ_REMAP is enabled: drivers/iommu/amd_iommu.c:86:24: error: 'iommu_table_lock' defined but not used [-Werror=unused-variable] static DEFINE_SPINLOCK(iommu_table_lock); This moves the definition next to the user, within the #ifdef protected section of the file. Fixes: ea6166f ("iommu/amd: Split irq_lookup_table out of the amd_iommu_devtable_lock") Signed-off-by: Arnd Bergmann <[email protected]> Acked-by: Sebastian Andrzej Siewior <[email protected]> Signed-off-by: Joerg Roedel <[email protected]>
1 parent aa7528f commit 94c793a

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/iommu/amd_iommu.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,6 @@
8383

8484
static DEFINE_SPINLOCK(amd_iommu_devtable_lock);
8585
static DEFINE_SPINLOCK(pd_bitmap_lock);
86-
static DEFINE_SPINLOCK(iommu_table_lock);
8786

8887
/* List of all available dev_data structures */
8988
static LLIST_HEAD(dev_data_list);
@@ -3562,6 +3561,7 @@ EXPORT_SYMBOL(amd_iommu_device_info);
35623561
*****************************************************************************/
35633562

35643563
static struct irq_chip amd_ir_chip;
3564+
static DEFINE_SPINLOCK(iommu_table_lock);
35653565

35663566
static void set_dte_irq_entry(u16 devid, struct irq_remap_table *table)
35673567
{

0 commit comments

Comments
 (0)