Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1207017 > unrolled thread

[PATCH 8/9] iommu/msm: Use BUG_ON instead of if () BUG()

Started byJoerg Roedel <joro@8bytes.org>
First post2015-08-13 19:40 +0200
Last post2015-08-13 19:40 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 8/9] iommu/msm: Use BUG_ON instead of if () BUG() Joerg Roedel <joro@8bytes.org> - 2015-08-13 19:40 +0200

#1207017 — [PATCH 8/9] iommu/msm: Use BUG_ON instead of if () BUG()

FromJoerg Roedel <joro@8bytes.org>
Date2015-08-13 19:40 +0200
Subject[PATCH 8/9] iommu/msm: Use BUG_ON instead of if () BUG()
Message-ID<pX4DW-1Gi-49@gated-at.bofh.it>
From: Joerg Roedel <jroedel@suse.de>

Found by a coccicheck script.

Signed-off-by: Joerg Roedel <jroedel@suse.de>
---
 drivers/iommu/msm_iommu.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/iommu/msm_iommu.c b/drivers/iommu/msm_iommu.c
index 15a2063..e321fa5 100644
--- a/drivers/iommu/msm_iommu.c
+++ b/drivers/iommu/msm_iommu.c
@@ -106,8 +106,8 @@ static int __flush_iotlb(struct iommu_domain *domain)
 #endif
 
 	list_for_each_entry(ctx_drvdata, &priv->list_attached, attached_elm) {
-		if (!ctx_drvdata->pdev || !ctx_drvdata->pdev->dev.parent)
-			BUG();
+
+		BUG_ON(!ctx_drvdata->pdev || !ctx_drvdata->pdev->dev.parent);
 
 		iommu_drvdata = dev_get_drvdata(ctx_drvdata->pdev->dev.parent);
 		BUG_ON(!iommu_drvdata);
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web