diff mbox

[v2,06/21] OMAP: DSS2: Taal: Fix request_irq() error handling

Message ID b88fcf26f978d38a25000c2f472a4ad8f79ac285.1272621452.git.ext-jani.1.nikula@nokia.com (mailing list archive)
State New, archived
Delegated to: Tomi Valkeinen
Headers show

Commit Message

Jani Nikula May 3, 2010, 6:18 a.m. UTC
None
diff mbox

Patch

diff --git a/drivers/video/omap2/displays/panel-taal.c b/drivers/video/omap2/displays/panel-taal.c
index 3729ec2..98f882a 100644
--- a/drivers/video/omap2/displays/panel-taal.c
+++ b/drivers/video/omap2/displays/panel-taal.c
@@ -601,7 +601,7 @@  static int taal_probe(struct omap_dss_device *dssdev)
 		if (r) {
 			dev_err(&dssdev->dev, "IRQ request failed\n");
 			gpio_free(gpio);
-			goto err3;
+			goto err4;
 		}
 
 		init_completion(&td->te_completion);
@@ -612,18 +612,18 @@  static int taal_probe(struct omap_dss_device *dssdev)
 	r = sysfs_create_group(&dssdev->dev.kobj, &taal_attr_group);
 	if (r) {
 		dev_err(&dssdev->dev, "failed to create sysfs files\n");
-		goto err4;
+		goto err5;
 	}
 
 	taal_hw_reset(dssdev);
 
 	return 0;
+err5:
+	if (td->use_ext_te)
+		free_irq(gpio_to_irq(dssdev->phy.dsi.ext_te_gpio), dssdev);
 err4:
-	if (td->use_ext_te) {
-		int gpio = dssdev->phy.dsi.ext_te_gpio;
-		free_irq(gpio_to_irq(gpio), dssdev);
-		gpio_free(gpio);
-	}
+	if (td->use_ext_te)
+		gpio_free(dssdev->phy.dsi.ext_te_gpio);
 err3:
 	backlight_device_unregister(bldev);
 err2: