diff mbox

[RFC,22/37] cbus: tahvo: don't assign ret inside if ()

Message ID 1270656268-7034-23-git-send-email-felipe.balbi@nokia.com (mailing list archive)
State Accepted, archived
Delegated to: Tony Lindgren
Headers show

Commit Message

Felipe Balbi April 7, 2010, 4:04 p.m. UTC
None
diff mbox

Patch

diff --git a/drivers/cbus/tahvo.c b/drivers/cbus/tahvo.c
index e14108f..fc25a89 100644
--- a/drivers/cbus/tahvo.c
+++ b/drivers/cbus/tahvo.c
@@ -340,7 +340,8 @@  static int __devinit tahvo_probe(struct device *dev)
 		return -ENODEV;
 	}
 
-	if ((ret = gpio_request(tahvo_irq_pin, "TAHVO irq")) < 0) {
+	ret = gpio_request(tahvo_irq_pin, "TAHVO irq");
+	if (ret) {
 		printk(KERN_ERR PFX "Unable to reserve IRQ GPIO\n");
 		return ret;
 	}
@@ -424,10 +425,12 @@  static int __init tahvo_init(void)
 
 	init_completion(&device_release);
 
-	if ((ret = driver_register(&tahvo_driver)) < 0)
+	ret = driver_register(&tahvo_driver);
+	if (ret)
 		return ret;
 
-	if ((ret = platform_device_register(&tahvo_device)) < 0) {
+	ret = platform_device_register(&tahvo_device);
+	if (ret) {
 		driver_unregister(&tahvo_driver);
 		return ret;
 	}