Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 156312
b: refs/heads/master
c: a0cc1ec
h: refs/heads/master
v: v3
  • Loading branch information
Vasu Dev authored and James Bottomley committed Jul 30, 2009
1 parent 10538a8 commit 5639c13
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 9 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 16ed55f9de6743ceece9bf528362cadff10f1c5c
refs/heads/master: a0cc1ecc098e31d03b3265712a3e280a7fabf438
23 changes: 15 additions & 8 deletions trunk/drivers/scsi/libfc/fc_exch.c
Original file line number Diff line number Diff line change
Expand Up @@ -415,9 +415,9 @@ static void fc_exch_timeout(struct work_struct *work)
e_stat = ep->esb_stat;
if (e_stat & ESB_ST_COMPLETE) {
ep->esb_stat = e_stat & ~ESB_ST_REC_QUAL;
spin_unlock_bh(&ep->ex_lock);
if (e_stat & ESB_ST_REC_QUAL)
fc_exch_rrq(ep);
spin_unlock_bh(&ep->ex_lock);
goto done;
} else {
resp = ep->resp;
Expand Down Expand Up @@ -1624,14 +1624,14 @@ static void fc_exch_rrq(struct fc_exch *ep)
struct fc_lport *lp;
struct fc_els_rrq *rrq;
struct fc_frame *fp;
struct fc_seq *rrq_sp;
u32 did;

lp = ep->lp;

fp = fc_frame_alloc(lp, sizeof(*rrq));
if (!fp)
return;
goto retry;

rrq = fc_frame_payload_get(fp, sizeof(*rrq));
memset(rrq, 0, sizeof(*rrq));
rrq->rrq_cmd = ELS_RRQ;
Expand All @@ -1647,13 +1647,20 @@ static void fc_exch_rrq(struct fc_exch *ep)
fc_host_port_id(lp->host), FC_TYPE_ELS,
FC_FC_FIRST_SEQ | FC_FC_END_SEQ | FC_FC_SEQ_INIT, 0);

rrq_sp = fc_exch_seq_send(lp, fp, fc_exch_rrq_resp, NULL, ep,
lp->e_d_tov);
if (!rrq_sp) {
ep->esb_stat |= ESB_ST_REC_QUAL;
fc_exch_timer_set_locked(ep, ep->r_a_tov);
if (fc_exch_seq_send(lp, fp, fc_exch_rrq_resp, NULL, ep, lp->e_d_tov))
return;

retry:
spin_lock_bh(&ep->ex_lock);
if (ep->state & (FC_EX_RST_CLEANUP | FC_EX_DONE)) {
spin_unlock_bh(&ep->ex_lock);
/* drop hold for rec qual */
fc_exch_release(ep);
return;
}
ep->esb_stat |= ESB_ST_REC_QUAL;
fc_exch_timer_set_locked(ep, ep->r_a_tov);
spin_unlock_bh(&ep->ex_lock);
}


Expand Down

0 comments on commit 5639c13

Please sign in to comment.