LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [PATCH -next] intel-iommu: fix a variable set but not used
@ 2019-05-31 20:16 Qian Cai
  2019-06-03  9:58 ` Joerg Roedel
  0 siblings, 1 reply; 2+ messages in thread
From: Qian Cai @ 2019-05-31 20:16 UTC (permalink / raw)
  To: jroedel; +Cc: jamessewart, baolu.lu, dwmw2, iommu, linux-kernel, Qian Cai

The commit "iommu/vt-d: Delegate the dma domain to upper layer" left an
unused variable,

drivers/iommu/intel-iommu.c: In function 'disable_dmar_iommu':
drivers/iommu/intel-iommu.c:1652:23: warning: variable 'domain' set but
not used [-Wunused-but-set-variable]

Signed-off-by: Qian Cai <cai@lca.pw>
---
 drivers/iommu/intel-iommu.c | 4 ----
 1 file changed, 4 deletions(-)

diff --git a/drivers/iommu/intel-iommu.c b/drivers/iommu/intel-iommu.c
index b431cc6f6ba4..073c547f247a 100644
--- a/drivers/iommu/intel-iommu.c
+++ b/drivers/iommu/intel-iommu.c
@@ -1649,16 +1649,12 @@ static void disable_dmar_iommu(struct intel_iommu *iommu)
 
 	spin_lock_irqsave(&device_domain_lock, flags);
 	list_for_each_entry_safe(info, tmp, &device_domain_list, global) {
-		struct dmar_domain *domain;
-
 		if (info->iommu != iommu)
 			continue;
 
 		if (!info->dev || !info->domain)
 			continue;
 
-		domain = info->domain;
-
 		__dmar_remove_one_dev_info(info);
 	}
 	spin_unlock_irqrestore(&device_domain_lock, flags);
-- 
1.8.3.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH -next] intel-iommu: fix a variable set but not used
  2019-05-31 20:16 [PATCH -next] intel-iommu: fix a variable set but not used Qian Cai
@ 2019-06-03  9:58 ` Joerg Roedel
  0 siblings, 0 replies; 2+ messages in thread
From: Joerg Roedel @ 2019-06-03  9:58 UTC (permalink / raw)
  To: Qian Cai; +Cc: jamessewart, baolu.lu, dwmw2, iommu, linux-kernel

On Fri, May 31, 2019 at 04:16:02PM -0400, Qian Cai wrote:
> The commit "iommu/vt-d: Delegate the dma domain to upper layer" left an
> unused variable,
> 
> drivers/iommu/intel-iommu.c: In function 'disable_dmar_iommu':
> drivers/iommu/intel-iommu.c:1652:23: warning: variable 'domain' set but
> not used [-Wunused-but-set-variable]
> 
> Signed-off-by: Qian Cai <cai@lca.pw>
> ---
>  drivers/iommu/intel-iommu.c | 4 ----
>  1 file changed, 4 deletions(-)

Applied, thanks.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2019-06-03  9:58 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-05-31 20:16 [PATCH -next] intel-iommu: fix a variable set but not used Qian Cai
2019-06-03  9:58 ` Joerg Roedel

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).