input: TSC: return with error incase of probe fail
authorPatil, Rachna <rachna@ti.com>
Mon, 12 Mar 2012 13:24:53 +0000 (18:54 +0530)
committerPatil, Rachna <rachna@ti.com>
Mon, 12 Mar 2012 13:54:56 +0000 (19:24 +0530)
This patch corrects error handling in touchscreen.

Signed-off-by: Patil, Rachna <rachna@ti.com>
drivers/input/touchscreen/ti_tscadc.c

index 9b34b82072799945e61b2a2cdc2bf6e6b1a33d52..950c07f1d0701cfad721de3385d8d17f8c8b652c 100644 (file)
@@ -447,6 +447,7 @@ static      int __devinit tscadc_probe(struct platform_device *pdev)
        clk_value = clock_rate / ADC_CLK;
        if (clk_value < 7) {
                dev_err(&pdev->dev, "clock input less than min clock requirement\n");
+               err = -EINVAL;
                goto err_fail;
        }
        /* TSCADC_CLKDIV needs to be configured to the value minus 1 */