diff options
author | Michael Ellerman <michael@ellerman.id.au> | 2010-01-12 16:10:56 -0500 |
---|---|---|
committer | Benjamin Herrenschmidt <benh@kernel.crashing.org> | 2010-01-14 21:26:14 -0500 |
commit | b0ff153cd6228b2502e1c3ce5e226b82ae4e0679 (patch) | |
tree | f555a751bcb94a1c5a4d1761966a9fa36c7fedde /arch | |
parent | aa8b83cb0b48e3cac58a3b75ad9c556564c5fe9d (diff) |
powerpc/iseries: Initialise on-stack completion
get_viotape_info() declares a vio_waitevent on the stack, which
contains a completion, but never initialises the completion.
I have no idea how this ever worked, and on recent kernels it causes
an oops in handle_tape_event() when we access the non-initialised
completion.
Signed-off-by: Michael Ellerman <michael@ellerman.id.au>
Acked-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/powerpc/platforms/iseries/vio.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/powerpc/platforms/iseries/vio.c b/arch/powerpc/platforms/iseries/vio.c index 657b72f68493..2aa8b5631beb 100644 --- a/arch/powerpc/platforms/iseries/vio.c +++ b/arch/powerpc/platforms/iseries/vio.c | |||
@@ -474,6 +474,8 @@ static void __init get_viotape_info(struct device_node *vio_root) | |||
474 | struct vio_waitevent we; | 474 | struct vio_waitevent we; |
475 | int ret; | 475 | int ret; |
476 | 476 | ||
477 | init_completion(&we.com); | ||
478 | |||
477 | ret = viopath_open(viopath_hostLp, viomajorsubtype_tape, 2); | 479 | ret = viopath_open(viopath_hostLp, viomajorsubtype_tape, 2); |
478 | if (ret) { | 480 | if (ret) { |
479 | printk(KERN_WARNING "get_viotape_info: " | 481 | printk(KERN_WARNING "get_viotape_info: " |