diff options
author | Sebastian Ott <sebott@linux.vnet.ibm.com> | 2011-04-04 09:43:31 +0200 |
---|---|---|
committer | Martin Schwidefsky <sky@mschwide.boeblingen.de.ibm.com> | 2011-04-04 09:43:32 +0200 |
commit | aa5c8df398266a141fb5ff0e77cbc7904a3e0648 (patch) | |
tree | 9fb32e602c8d3fc79b4a94086ed69cd3c0d3fc48 /drivers/s390 | |
parent | 034e9e966cd86e5d8062cf0b3daba4bde187986c (diff) | |
download | op-kernel-dev-aa5c8df398266a141fb5ff0e77cbc7904a3e0648.zip op-kernel-dev-aa5c8df398266a141fb5ff0e77cbc7904a3e0648.tar.gz |
[S390] qdio: fix init sequence
Reorder the initialization sequence of the qdio module to avoid
writing to an uninitialized debug feature entry. Also reorder
the exit function to restore a consistent cleanup path.
Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'drivers/s390')
-rw-r--r-- | drivers/s390/cio/qdio_main.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/s390/cio/qdio_main.c b/drivers/s390/cio/qdio_main.c index 479c665..c532ba9 100644 --- a/drivers/s390/cio/qdio_main.c +++ b/drivers/s390/cio/qdio_main.c @@ -1649,26 +1649,26 @@ static int __init init_QDIO(void) { int rc; - rc = qdio_setup_init(); + rc = qdio_debug_init(); if (rc) return rc; + rc = qdio_setup_init(); + if (rc) + goto out_debug; rc = tiqdio_allocate_memory(); if (rc) goto out_cache; - rc = qdio_debug_init(); - if (rc) - goto out_ti; rc = tiqdio_register_thinints(); if (rc) - goto out_debug; + goto out_ti; return 0; -out_debug: - qdio_debug_exit(); out_ti: tiqdio_free_memory(); out_cache: qdio_setup_exit(); +out_debug: + qdio_debug_exit(); return rc; } @@ -1676,8 +1676,8 @@ static void __exit exit_QDIO(void) { tiqdio_unregister_thinints(); tiqdio_free_memory(); - qdio_debug_exit(); qdio_setup_exit(); + qdio_debug_exit(); } module_init(init_QDIO); |