Commit e89a60ba authored by Andy Shevchenko's avatar Andy Shevchenko Committed by Helge Deller
Browse files

fbdev: omapfb: Do not shadow error code from platform_get_irq()



There is no point in shadowing the error codes from platform_get_irq().
Refactor omapfb_do_probe() accordingly.

Signed-off-by: default avatarAndy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: default avatarHelge Deller <deller@gmx.de>
parent be3ca57c
Loading
Loading
Loading
Loading
+7 −8
Original line number Diff line number Diff line
@@ -1643,17 +1643,16 @@ static int omapfb_do_probe(struct platform_device *pdev,
		r = -ENOMEM;
		goto cleanup;
	}
	fbdev->int_irq = platform_get_irq(pdev, 0);
	if (fbdev->int_irq < 0) {
		r = -ENXIO;

	r = platform_get_irq(pdev, 0);
	if (r < 0)
		goto cleanup;
	}
	fbdev->int_irq = r;

	fbdev->ext_irq = platform_get_irq(pdev, 1);
	if (fbdev->ext_irq < 0) {
		r = -ENXIO;
	r = platform_get_irq(pdev, 1);
	if (r < 0)
		goto cleanup;
	}
	fbdev->ext_irq = r;

	init_state++;