diff options
author | Sebastian Ott <sebott@linux.vnet.ibm.com> | 2011-04-04 03:43:31 -0400 |
---|---|---|
committer | Martin Schwidefsky <sky@mschwide.boeblingen.de.ibm.com> | 2011-04-04 03:43:32 -0400 |
commit | aa5c8df398266a141fb5ff0e77cbc7904a3e0648 (patch) | |
tree | 9fb32e602c8d3fc79b4a94086ed69cd3c0d3fc48 /drivers/s390 | |
parent | 034e9e966cd86e5d8062cf0b3daba4bde187986c (diff) |
[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 479c665e9e7c..c532ba929ccd 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) | |||
1649 | { | 1649 | { |
1650 | int rc; | 1650 | int rc; |
1651 | 1651 | ||
1652 | rc = qdio_setup_init(); | 1652 | rc = qdio_debug_init(); |
1653 | if (rc) | 1653 | if (rc) |
1654 | return rc; | 1654 | return rc; |
1655 | rc = qdio_setup_init(); | ||
1656 | if (rc) | ||
1657 | goto out_debug; | ||
1655 | rc = tiqdio_allocate_memory(); | 1658 | rc = tiqdio_allocate_memory(); |
1656 | if (rc) | 1659 | if (rc) |
1657 | goto out_cache; | 1660 | goto out_cache; |
1658 | rc = qdio_debug_init(); | ||
1659 | if (rc) | ||
1660 | goto out_ti; | ||
1661 | rc = tiqdio_register_thinints(); | 1661 | rc = tiqdio_register_thinints(); |
1662 | if (rc) | 1662 | if (rc) |
1663 | goto out_debug; | 1663 | goto out_ti; |
1664 | return 0; | 1664 | return 0; |
1665 | 1665 | ||
1666 | out_debug: | ||
1667 | qdio_debug_exit(); | ||
1668 | out_ti: | 1666 | out_ti: |
1669 | tiqdio_free_memory(); | 1667 | tiqdio_free_memory(); |
1670 | out_cache: | 1668 | out_cache: |
1671 | qdio_setup_exit(); | 1669 | qdio_setup_exit(); |
1670 | out_debug: | ||
1671 | qdio_debug_exit(); | ||
1672 | return rc; | 1672 | return rc; |
1673 | } | 1673 | } |
1674 | 1674 | ||
@@ -1676,8 +1676,8 @@ static void __exit exit_QDIO(void) | |||
1676 | { | 1676 | { |
1677 | tiqdio_unregister_thinints(); | 1677 | tiqdio_unregister_thinints(); |
1678 | tiqdio_free_memory(); | 1678 | tiqdio_free_memory(); |
1679 | qdio_debug_exit(); | ||
1680 | qdio_setup_exit(); | 1679 | qdio_setup_exit(); |
1680 | qdio_debug_exit(); | ||
1681 | } | 1681 | } |
1682 | 1682 | ||
1683 | module_init(init_QDIO); | 1683 | module_init(init_QDIO); |