diff options
Diffstat (limited to 'drivers/input/touchscreen/tsc2005.c')
-rw-r--r-- | drivers/input/touchscreen/tsc2005.c | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/drivers/input/touchscreen/tsc2005.c b/drivers/input/touchscreen/tsc2005.c index cbf0ff322676..b6adeaee9cc5 100644 --- a/drivers/input/touchscreen/tsc2005.c +++ b/drivers/input/touchscreen/tsc2005.c | |||
@@ -450,13 +450,13 @@ static struct attribute *tsc2005_attrs[] = { | |||
450 | NULL | 450 | NULL |
451 | }; | 451 | }; |
452 | 452 | ||
453 | static mode_t tsc2005_attr_is_visible(struct kobject *kobj, | 453 | static umode_t tsc2005_attr_is_visible(struct kobject *kobj, |
454 | struct attribute *attr, int n) | 454 | struct attribute *attr, int n) |
455 | { | 455 | { |
456 | struct device *dev = container_of(kobj, struct device, kobj); | 456 | struct device *dev = container_of(kobj, struct device, kobj); |
457 | struct spi_device *spi = to_spi_device(dev); | 457 | struct spi_device *spi = to_spi_device(dev); |
458 | struct tsc2005 *ts = spi_get_drvdata(spi); | 458 | struct tsc2005 *ts = spi_get_drvdata(spi); |
459 | mode_t mode = attr->mode; | 459 | umode_t mode = attr->mode; |
460 | 460 | ||
461 | if (attr == &dev_attr_selftest.attr) { | 461 | if (attr == &dev_attr_selftest.attr) { |
462 | if (!ts->set_reset) | 462 | if (!ts->set_reset) |
@@ -747,17 +747,7 @@ static struct spi_driver tsc2005_driver = { | |||
747 | .remove = __devexit_p(tsc2005_remove), | 747 | .remove = __devexit_p(tsc2005_remove), |
748 | }; | 748 | }; |
749 | 749 | ||
750 | static int __init tsc2005_init(void) | 750 | module_spi_driver(tsc2005_driver); |
751 | { | ||
752 | return spi_register_driver(&tsc2005_driver); | ||
753 | } | ||
754 | module_init(tsc2005_init); | ||
755 | |||
756 | static void __exit tsc2005_exit(void) | ||
757 | { | ||
758 | spi_unregister_driver(&tsc2005_driver); | ||
759 | } | ||
760 | module_exit(tsc2005_exit); | ||
761 | 751 | ||
762 | MODULE_AUTHOR("Lauri Leukkunen <lauri.leukkunen@nokia.com>"); | 752 | MODULE_AUTHOR("Lauri Leukkunen <lauri.leukkunen@nokia.com>"); |
763 | MODULE_DESCRIPTION("TSC2005 Touchscreen Driver"); | 753 | MODULE_DESCRIPTION("TSC2005 Touchscreen Driver"); |