Skip to contentSkip to conversation

irda/sa1100_ir: check return value of startup hook

PATCH New Dmitry Artamonow 1 participant 1 message Oct 9, 2009 Network drivers

lore
Share & tools
lore
#0 lore raw

PATCH v2 1/1 irda/sa1100_ir: check return value of startup hook

---
 drivers/net/irda/sa1100_ir.c |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)
drivers/net/irda/sa1100_ir.c +5 -2
index 38bf7cf..c412e80 100644
@@ -232,8 +232,11 @@ static int sa1100_irda_startup(struct sa1100_irda *si)
 	/*
 	 * Ensure that the ports for this device are setup correctly.
 	 */
-	if (si->pdata->startup)
-		si->pdata->startup(si->dev);
+	if (si->pdata->startup)	{
+		ret = si->pdata->startup(si->dev);
+		if (ret)
+			return ret;
+	}
 
 	/*
 	 * Configure PPC for IRDA - we want to drive TXD2 low.
Signature · 4 lines
1.6.3.4


--opJtzjQTFsWo+cga--