aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2009-03-26 14:17:04 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-03-26 14:17:04 -0400
commit0c93ea4064a209cdc36de8a9a3003d43d08f46f7 (patch)
treeff19952407c523a1349ef56c05993416dd28437e /arch/mips
parentbc2fd381d8f9dbeb181f82286cdca1567e3d0def (diff)
parente6e66b02e11563abdb7f69dcb7a2efbd8d577e77 (diff)
Merge git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core-2.6: (61 commits) Dynamic debug: fix pr_fmt() build error Dynamic debug: allow simple quoting of words dynamic debug: update docs dynamic debug: combine dprintk and dynamic printk sysfs: fix some bin_vm_ops errors kobject: don't block for each kobject_uevent sysfs: only allow one scheduled removal callback per kobj Driver core: Fix device_move() vs. dpm list ordering, v2 Driver core: some cleanup on drivers/base/sys.c Driver core: implement uevent suppress in kobject vcs: hook sysfs devices into object lifetime instead of "binding" driver core: fix passing platform_data driver core: move platform_data into platform_device sysfs: don't block indefinitely for unmapped files. driver core: move knode_bus into private structure driver core: move knode_driver into private structure driver core: move klist_children into private structure driver core: create a private portion of struct device driver core: remove polling for driver_probe_done(v5) sysfs: reference sysfs_dirent from sysfs inodes ... Fixed conflicts in drivers/sh/maple/maple.c manually
Diffstat (limited to 'arch/mips')
-rw-r--r--arch/mips/basler/excite/excite_iodev.c27
1 files changed, 13 insertions, 14 deletions
diff --git a/arch/mips/basler/excite/excite_iodev.c b/arch/mips/basler/excite/excite_iodev.c
index a1e3526b4a94..dfbfd7e2ac08 100644
--- a/arch/mips/basler/excite/excite_iodev.c
+++ b/arch/mips/basler/excite/excite_iodev.c
@@ -33,8 +33,8 @@
33 33
34 34
35static const struct resource *iodev_get_resource(struct platform_device *, const char *, unsigned int); 35static const struct resource *iodev_get_resource(struct platform_device *, const char *, unsigned int);
36static int __init iodev_probe(struct device *); 36static int __init iodev_probe(struct platform_device *);
37static int __exit iodev_remove(struct device *); 37static int __exit iodev_remove(struct platform_device *);
38static int iodev_open(struct inode *, struct file *); 38static int iodev_open(struct inode *, struct file *);
39static int iodev_release(struct inode *, struct file *); 39static int iodev_release(struct inode *, struct file *);
40static ssize_t iodev_read(struct file *, char __user *, size_t s, loff_t *); 40static ssize_t iodev_read(struct file *, char __user *, size_t s, loff_t *);
@@ -65,13 +65,13 @@ static struct miscdevice miscdev =
65 .fops = &fops 65 .fops = &fops
66}; 66};
67 67
68static struct device_driver iodev_driver = 68static struct platform_driver iodev_driver = {
69{ 69 .driver = {
70 .name = (char *) iodev_name, 70 .name = iodev_name,
71 .bus = &platform_bus_type, 71 .owner = THIS_MODULE,
72 .owner = THIS_MODULE, 72 },
73 .probe = iodev_probe, 73 .probe = iodev_probe,
74 .remove = __exit_p(iodev_remove) 74 .remove = __devexit_p(iodev_remove),
75}; 75};
76 76
77 77
@@ -89,11 +89,10 @@ iodev_get_resource(struct platform_device *pdv, const char *name,
89 89
90 90
91/* No hotplugging on the platform bus - use __init */ 91/* No hotplugging on the platform bus - use __init */
92static int __init iodev_probe(struct device *dev) 92static int __init iodev_probe(struct platform_device *dev)
93{ 93{
94 struct platform_device * const pdv = to_platform_device(dev);
95 const struct resource * const ri = 94 const struct resource * const ri =
96 iodev_get_resource(pdv, IODEV_RESOURCE_IRQ, IORESOURCE_IRQ); 95 iodev_get_resource(dev, IODEV_RESOURCE_IRQ, IORESOURCE_IRQ);
97 96
98 if (unlikely(!ri)) 97 if (unlikely(!ri))
99 return -ENXIO; 98 return -ENXIO;
@@ -104,7 +103,7 @@ static int __init iodev_probe(struct device *dev)
104 103
105 104
106 105
107static int __exit iodev_remove(struct device *dev) 106static int __exit iodev_remove(struct platform_device *dev)
108{ 107{
109 return misc_deregister(&miscdev); 108 return misc_deregister(&miscdev);
110} 109}
@@ -160,14 +159,14 @@ static irqreturn_t iodev_irqhdl(int irq, void *ctxt)
160 159
161static int __init iodev_init_module(void) 160static int __init iodev_init_module(void)
162{ 161{
163 return driver_register(&iodev_driver); 162 return platform_driver_register(&iodev_driver);
164} 163}
165 164
166 165
167 166
168static void __exit iodev_cleanup_module(void) 167static void __exit iodev_cleanup_module(void)
169{ 168{
170 driver_unregister(&iodev_driver); 169 platform_driver_unregister(&iodev_driver);
171} 170}
172 171
173module_init(iodev_init_module); 172module_init(iodev_init_module);