diff options
author | Vaishali Thakkar <vthakkar1994@gmail.com> | 2015-09-12 21:08:34 +0300 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2015-09-19 21:42:39 +0300 |
commit | c5c18a06af753eab1162fcdfb1cf03581e70b3f4 (patch) | |
tree | 7243da6644d37bff5cf4e856cfd0f47934500fd3 /drivers/input/misc/ad714x-spi.c | |
parent | ade9c1a47c811a7ae1c874882ad9178af1ed1098 (diff) | |
download | linux-c5c18a06af753eab1162fcdfb1cf03581e70b3f4.tar.xz |
Input: ad714x - convert to using managed resources
Use managed resource functions devm_request_threaded_irq,
devm_inpute_allocate_device and devm_kzalloc to simplify error handling.
Also, remove use of input_unregister_device as input_register_device itself
handles it and works as resource managed function.
To be compatible with the change, various gotos are replaced with direct
returns, and unneeded labels are dropped. With these changes remove
ad714x_remove and corresponding calls of it as they are now redundant.
Signed-off-by: Vaishali Thakkar <vthakkar1994@gmail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Diffstat (limited to 'drivers/input/misc/ad714x-spi.c')
-rw-r--r-- | drivers/input/misc/ad714x-spi.c | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/drivers/input/misc/ad714x-spi.c b/drivers/input/misc/ad714x-spi.c index a79e50b58bf5..c8170f082962 100644 --- a/drivers/input/misc/ad714x-spi.c +++ b/drivers/input/misc/ad714x-spi.c @@ -101,15 +101,6 @@ static int ad714x_spi_probe(struct spi_device *spi) return 0; } -static int ad714x_spi_remove(struct spi_device *spi) -{ - struct ad714x_chip *chip = spi_get_drvdata(spi); - - ad714x_remove(chip); - - return 0; -} - static struct spi_driver ad714x_spi_driver = { .driver = { .name = "ad714x_captouch", @@ -117,7 +108,6 @@ static struct spi_driver ad714x_spi_driver = { .pm = &ad714x_spi_pm, }, .probe = ad714x_spi_probe, - .remove = ad714x_spi_remove, }; module_spi_driver(ad714x_spi_driver); |