[PATCH 1/3] mmc/sdhci-spear: No need to check 'pdev == NULL' in probe

Viresh Kumar viresh.kumar at st.com
Tue Mar 27 14:10:34 EST 2012


pdev is guaranteed to be valid in probe. And so check is not required to check
if it is non-NULL. Remove it.

Signed-off-by: Viresh Kumar <viresh.kumar at st.com>
---
 drivers/mmc/host/sdhci-spear.c |    2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/mmc/host/sdhci-spear.c b/drivers/mmc/host/sdhci-spear.c
index 6dfa82e..15191c1 100644
--- a/drivers/mmc/host/sdhci-spear.c
+++ b/drivers/mmc/host/sdhci-spear.c
@@ -75,8 +75,6 @@ static int __devinit sdhci_probe(struct platform_device *pdev)
 	struct spear_sdhci *sdhci;
 	int ret;
 
-	BUG_ON(pdev == NULL);
-
 	iomem = platform_get_resource(pdev, IORESOURCE_MEM, 0);
 	if (!iomem) {
 		ret = -ENOMEM;
-- 
1.7.10.rc2.10.gb47606



More information about the devicetree-discuss mailing list