This reduces the delay in failover from one path to another.

When a path is lost, the control and data connections of that path
are cleaned up. As part of this a CM DREQ was being sent and we waited
for a DREP. During this time the viport thread was blocked which delayed
sending of a CONFIG_LINK request to the VEx for the other path. Due
to this, there was considerable delay in the failover path becoming
active. To fix this, send a DREQ but do not wait for a DREP from
the VEx. We need not worry about a DREQ being lost because the
VEx will anyway terminate a connection if it does not receive heartbeats.

Signed-off-by: Ramachandra K <ramachandra.kuchimanchi@qlogic.com>
---

 drivers/infiniband/ulp/vnic/vnic_control.c |    4 +---
 drivers/infiniband/ulp/vnic/vnic_data.c    |    3 ---
 2 files changed, 1 insertions(+), 6 deletions(-)

diff -r 34bdc2583364 drivers/infiniband/ulp/vnic/vnic_control.c
--- a/drivers/infiniband/ulp/vnic/vnic_control.c	Tue Jan 23 15:17:26 2007 -0800
+++ b/drivers/infiniband/ulp/vnic/vnic_control.c	Tue Jan 23 15:20:16 2007 -0800
@@ -1450,12 +1450,10 @@ void control_cleanup(struct control *con
 {
 	CONTROL_FUNCTION("%s: control_disconnect()\n",
 			 control_ifcfg_name(control));
-	init_completion(&control->ib_conn.done);
 
 	if (ib_send_cm_dreq(control->ib_conn.cm_id, NULL, 0))
 		printk(KERN_DEBUG "control CM DREQ sending failed\n");
-	else
-		wait_for_completion(&control->ib_conn.done);
+
 	control_timer_stop(control);
 	ib_destroy_cm_id(control->ib_conn.cm_id);
 	ib_destroy_qp(control->ib_conn.qp);
diff -r 34bdc2583364 drivers/infiniband/ulp/vnic/vnic_data.c
--- a/drivers/infiniband/ulp/vnic/vnic_data.c	Tue Jan 23 15:17:26 2007 -0800
+++ b/drivers/infiniband/ulp/vnic/vnic_data.c	Tue Jan 23 15:19:31 2007 -0800
@@ -666,11 +666,8 @@ void data_disconnect(struct data *data)
 
 void data_cleanup(struct data *data)
 {
-	init_completion(&data->ib_conn.done);
 	if (ib_send_cm_dreq(data->ib_conn.cm_id, NULL, 0))
 		printk(KERN_DEBUG "data CM DREQ sending failed\n");
-	else
-		wait_for_completion(&data->ib_conn.done);
 
 	ib_destroy_cm_id(data->ib_conn.cm_id);
 	ib_destroy_qp(data->ib_conn.qp);
