aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2006-01-14 13:42:40 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-01-14 13:42:40 -0500
commit3e2b32b69308e974cd1167beaf266d3c716e4734 (patch)
tree0f1b24dcb7b066a6322d33235b95655d885695ac /arch/arm
parent3824ba7df91745da6ebac703c87c3b801c34fdd0 (diff)
parent9c08a938ce5a3e1c9d5f764dc6ae844cb1af76ff (diff)
Merge master.kernel.org:/pub/scm/linux/kernel/git/gregkh/driver-2.6
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/common/locomo.c4
-rw-r--r--arch/arm/common/sa1111.c4
-rw-r--r--arch/arm/kernel/ecard.c14
-rw-r--r--arch/arm/mach-integrator/lm.c36
4 files changed, 30 insertions, 28 deletions
diff --git a/arch/arm/common/locomo.c b/arch/arm/common/locomo.c
index 1b7eaab02b9e..159ad7ed7a40 100644
--- a/arch/arm/common/locomo.c
+++ b/arch/arm/common/locomo.c
@@ -1103,14 +1103,14 @@ static int locomo_bus_remove(struct device *dev)
1103struct bus_type locomo_bus_type = { 1103struct bus_type locomo_bus_type = {
1104 .name = "locomo-bus", 1104 .name = "locomo-bus",
1105 .match = locomo_match, 1105 .match = locomo_match,
1106 .probe = locomo_bus_probe,
1107 .remove = locomo_bus_remove,
1106 .suspend = locomo_bus_suspend, 1108 .suspend = locomo_bus_suspend,
1107 .resume = locomo_bus_resume, 1109 .resume = locomo_bus_resume,
1108}; 1110};
1109 1111
1110int locomo_driver_register(struct locomo_driver *driver) 1112int locomo_driver_register(struct locomo_driver *driver)
1111{ 1113{
1112 driver->drv.probe = locomo_bus_probe;
1113 driver->drv.remove = locomo_bus_remove;
1114 driver->drv.bus = &locomo_bus_type; 1114 driver->drv.bus = &locomo_bus_type;
1115 return driver_register(&driver->drv); 1115 return driver_register(&driver->drv);
1116} 1116}
diff --git a/arch/arm/common/sa1111.c b/arch/arm/common/sa1111.c
index d0d6e6d2d649..1475089f9b42 100644
--- a/arch/arm/common/sa1111.c
+++ b/arch/arm/common/sa1111.c
@@ -1247,14 +1247,14 @@ static int sa1111_bus_remove(struct device *dev)
1247struct bus_type sa1111_bus_type = { 1247struct bus_type sa1111_bus_type = {
1248 .name = "sa1111-rab", 1248 .name = "sa1111-rab",
1249 .match = sa1111_match, 1249 .match = sa1111_match,
1250 .probe = sa1111_bus_probe,
1251 .remove = sa1111_bus_remove,
1250 .suspend = sa1111_bus_suspend, 1252 .suspend = sa1111_bus_suspend,
1251 .resume = sa1111_bus_resume, 1253 .resume = sa1111_bus_resume,
1252}; 1254};
1253 1255
1254int sa1111_driver_register(struct sa1111_driver *driver) 1256int sa1111_driver_register(struct sa1111_driver *driver)
1255{ 1257{
1256 driver->drv.probe = sa1111_bus_probe;
1257 driver->drv.remove = sa1111_bus_remove;
1258 driver->drv.bus = &sa1111_bus_type; 1258 driver->drv.bus = &sa1111_bus_type;
1259 return driver_register(&driver->drv); 1259 return driver_register(&driver->drv);
1260} 1260}
diff --git a/arch/arm/kernel/ecard.c b/arch/arm/kernel/ecard.c
index 96fd91926c9b..74ea29c3205e 100644
--- a/arch/arm/kernel/ecard.c
+++ b/arch/arm/kernel/ecard.c
@@ -1147,9 +1147,11 @@ static void ecard_drv_shutdown(struct device *dev)
1147 struct ecard_driver *drv = ECARD_DRV(dev->driver); 1147 struct ecard_driver *drv = ECARD_DRV(dev->driver);
1148 struct ecard_request req; 1148 struct ecard_request req;
1149 1149
1150 if (drv->shutdown) 1150 if (dev->driver) {
1151 drv->shutdown(ec); 1151 if (drv->shutdown)
1152 ecard_release(ec); 1152 drv->shutdown(ec);
1153 ecard_release(ec);
1154 }
1153 1155
1154 /* 1156 /*
1155 * If this card has a loader, call the reset handler. 1157 * If this card has a loader, call the reset handler.
@@ -1164,9 +1166,6 @@ static void ecard_drv_shutdown(struct device *dev)
1164int ecard_register_driver(struct ecard_driver *drv) 1166int ecard_register_driver(struct ecard_driver *drv)
1165{ 1167{
1166 drv->drv.bus = &ecard_bus_type; 1168 drv->drv.bus = &ecard_bus_type;
1167 drv->drv.probe = ecard_drv_probe;
1168 drv->drv.remove = ecard_drv_remove;
1169 drv->drv.shutdown = ecard_drv_shutdown;
1170 1169
1171 return driver_register(&drv->drv); 1170 return driver_register(&drv->drv);
1172} 1171}
@@ -1195,6 +1194,9 @@ struct bus_type ecard_bus_type = {
1195 .name = "ecard", 1194 .name = "ecard",
1196 .dev_attrs = ecard_dev_attrs, 1195 .dev_attrs = ecard_dev_attrs,
1197 .match = ecard_match, 1196 .match = ecard_match,
1197 .probe = ecard_drv_probe,
1198 .remove = ecard_drv_remove,
1199 .shutdown = ecard_drv_shutdown,
1198}; 1200};
1199 1201
1200static int ecard_bus_init(void) 1202static int ecard_bus_init(void)
diff --git a/arch/arm/mach-integrator/lm.c b/arch/arm/mach-integrator/lm.c
index 5b41e3a724e1..622cdc4212dd 100644
--- a/arch/arm/mach-integrator/lm.c
+++ b/arch/arm/mach-integrator/lm.c
@@ -22,20 +22,6 @@ static int lm_match(struct device *dev, struct device_driver *drv)
22 return 1; 22 return 1;
23} 23}
24 24
25static struct bus_type lm_bustype = {
26 .name = "logicmodule",
27 .match = lm_match,
28// .suspend = lm_suspend,
29// .resume = lm_resume,
30};
31
32static int __init lm_init(void)
33{
34 return bus_register(&lm_bustype);
35}
36
37postcore_initcall(lm_init);
38
39static int lm_bus_probe(struct device *dev) 25static int lm_bus_probe(struct device *dev)
40{ 26{
41 struct lm_device *lmdev = to_lm_device(dev); 27 struct lm_device *lmdev = to_lm_device(dev);
@@ -49,16 +35,30 @@ static int lm_bus_remove(struct device *dev)
49 struct lm_device *lmdev = to_lm_device(dev); 35 struct lm_device *lmdev = to_lm_device(dev);
50 struct lm_driver *lmdrv = to_lm_driver(dev->driver); 36 struct lm_driver *lmdrv = to_lm_driver(dev->driver);
51 37
52 lmdrv->remove(lmdev); 38 if (lmdrv->remove)
39 lmdrv->remove(lmdev);
53 return 0; 40 return 0;
54} 41}
55 42
43static struct bus_type lm_bustype = {
44 .name = "logicmodule",
45 .match = lm_match,
46 .probe = lm_bus_probe,
47 .remove = lm_bus_remove,
48// .suspend = lm_bus_suspend,
49// .resume = lm_bus_resume,
50};
51
52static int __init lm_init(void)
53{
54 return bus_register(&lm_bustype);
55}
56
57postcore_initcall(lm_init);
58
56int lm_driver_register(struct lm_driver *drv) 59int lm_driver_register(struct lm_driver *drv)
57{ 60{
58 drv->drv.bus = &lm_bustype; 61 drv->drv.bus = &lm_bustype;
59 drv->drv.probe = lm_bus_probe;
60 drv->drv.remove = lm_bus_remove;
61
62 return driver_register(&drv->drv); 62 return driver_register(&drv->drv);
63} 63}
64 64