diff options
author | Sebastian Ott <sebott@linux.vnet.ibm.com> | 2009-09-22 20:58:33 (GMT) |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2009-09-22 20:58:41 (GMT) |
commit | 2f17644d1cd0121daa0a997ff4eca5b3b44d1fae (patch) | |
tree | 898504831cd8424525304eb9e35851f744a03d24 /drivers/s390/cio/device.c | |
parent | 43c1266ce4dc06bfd236cec31e11e9ecd69c0bef (diff) | |
download | linux-fsl-qoriq-2f17644d1cd0121daa0a997ff4eca5b3b44d1fae.tar.xz |
[S390] cio: merge init calls
Define initialization sequence of css and ccw bus init calls by merging
them into a single init call. Also introduce channel_subsystem_init_sync
to wait for the initialization of devices to finish.
Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390/cio/device.c')
-rw-r--r-- | drivers/s390/cio/device.c | 20 |
1 files changed, 3 insertions, 17 deletions
diff --git a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c index 6527f3f..4093adc 100644 --- a/drivers/s390/cio/device.c +++ b/drivers/s390/cio/device.c @@ -170,8 +170,7 @@ atomic_t ccw_device_init_count; static void recovery_func(unsigned long data); -static int __init -init_ccw_bus_type (void) +int __init io_subchannel_init(void) { int ret; @@ -181,10 +180,10 @@ init_ccw_bus_type (void) ccw_device_work = create_singlethread_workqueue("cio"); if (!ccw_device_work) - return -ENOMEM; /* FIXME: better errno ? */ + return -ENOMEM; slow_path_wq = create_singlethread_workqueue("kslowcrw"); if (!slow_path_wq) { - ret = -ENOMEM; /* FIXME: better errno ? */ + ret = -ENOMEM; goto out_err; } if ((ret = bus_register (&ccw_bus_type))) @@ -194,9 +193,6 @@ init_ccw_bus_type (void) if (ret) goto out_err; - wait_event(ccw_device_init_wq, - atomic_read(&ccw_device_init_count) == 0); - flush_workqueue(ccw_device_work); return 0; out_err: if (ccw_device_work) @@ -206,16 +202,6 @@ out_err: return ret; } -static void __exit -cleanup_ccw_bus_type (void) -{ - css_driver_unregister(&io_subchannel_driver); - bus_unregister(&ccw_bus_type); - destroy_workqueue(ccw_device_work); -} - -subsys_initcall(init_ccw_bus_type); -module_exit(cleanup_ccw_bus_type); /************************ device handling **************************/ |