fc_invoke_resp() tests resp_task before setting it. Hence initialize
resp_task in fc_exch_em_alloc().

Signed-off-by: Bart Van Assche <[email protected]>
Cc: stable <[email protected]>
---
 drivers/scsi/libfc/fc_exch.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/scsi/libfc/fc_exch.c b/drivers/scsi/libfc/fc_exch.c
index 1b3a094..fb4cc5e 100644
--- a/drivers/scsi/libfc/fc_exch.c
+++ b/drivers/scsi/libfc/fc_exch.c
@@ -868,6 +868,7 @@ hit:
        ep->rxid = FC_XID_UNKNOWN;
        ep->class = mp->class;
        ep->resp_active = 0;
+       ep->resp_task = NULL;
        init_waitqueue_head(&ep->resp_wq);
        INIT_DELAYED_WORK(&ep->timeout_work, fc_exch_timeout);
 out:
-- 
2.1.4

_______________________________________________
fcoe-devel mailing list
[email protected]
http://lists.open-fcoe.org/mailman/listinfo/fcoe-devel

Reply via email to