Input: cyttsp4_core - remove redundant dev_set_drvdata
authorSachin Kamat <sachin.kamat@linaro.org>
Wed, 18 Sep 2013 14:45:57 +0000 (07:45 -0700)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Wed, 18 Sep 2013 15:00:31 +0000 (08:00 -0700)
Driver core sets the data to NULL upon release or probe
failure. Hence explicit setting is not necessary.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/touchscreen/cyttsp4_core.c

index d038575f49db3a6d70e16ee640fb67cfbcab24be..42d830efa316ec9c44f53306123e0ffb2a2d04b5 100644 (file)
@@ -2113,7 +2113,6 @@ error_startup:
 error_request_irq:
        if (cd->cpdata->init)
                cd->cpdata->init(cd->cpdata, 0, dev);
-       dev_set_drvdata(dev, NULL);
 error_free_xfer:
        kfree(cd->xfer_buf);
 error_free_cd:
@@ -2151,7 +2150,6 @@ int cyttsp4_remove(struct cyttsp4 *cd)
        free_irq(cd->irq, cd);
        if (cd->cpdata->init)
                cd->cpdata->init(cd->cpdata, 0, dev);
-       dev_set_drvdata(dev, NULL);
        cyttsp4_free_si_ptrs(cd);
        kfree(cd);
        return 0;